TDBots Mk2 - v1 (11/05/2022)

Projects that alter game functions but do not include new maps belong here.
Forum rules
The Projects forums are only for projects. If you are asking questions about a project, either find that project's thread, or start a thread in the General section instead.

Got a cool project idea but nothing else? Put it in the project ideas thread instead!

Projects for any Doom-based engine (especially 3DGE) are perfectly acceptable here too.

Please read the full rules for more details.
User avatar
Gustavo6046
Posts: 138
Joined: Sat May 13, 2017 3:11 pm
Preferred Pronouns: He/Him
Operating System Version (Optional): Arch Linux
Graphics Processor: Intel with Vulkan/Metal Support
Location: Porto Alegre, Brazil

Re: TDBots: The fast-performing bots v4 (3/5/2019)

Post by Gustavo6046 »

Are you able to read and analyse any diffs (difference) between related code in v3 and v4? That helps :)
User avatar
TDRR
Posts: 816
Joined: Sun Mar 11, 2018 4:15 pm
Location: Venezuela

Re: TDBots: The fast-performing bots v4 (3/5/2019)

Post by TDRR »

After having compared both versions, i couldn't find anything that could cause the issue. Probably it does happen in v3 too, but since the firing system only runs for 6 seconds at most, it may fix itself after that period of time.
User avatar
TDRR
Posts: 816
Joined: Sun Mar 11, 2018 4:15 pm
Location: Venezuela

Re: TDBots: The fast-performing bots v5 (4/5/2019)

Post by TDRR »

Updated, check the changelog for details!

Download link in the OP!
User avatar
Gustavo6046
Posts: 138
Joined: Sat May 13, 2017 3:11 pm
Preferred Pronouns: He/Him
Operating System Version (Optional): Arch Linux
Graphics Processor: Intel with Vulkan/Metal Support
Location: Porto Alegre, Brazil

Re: TDBots: The fast-performing bots v5 (4/5/2019)

Post by Gustavo6046 »

I'm pretty sure you can use Git offline to compare v3 and v4. Once you commit v3, then commit v4 on top of it, you can simply use git diff.

E.g., if I changed WEAPONS.dec to make bots die every time they try using the pistol, but also refactored a few other names, then committed that, I can simply use git diff to see my changes and find the reason the bots die instead of shooting with the pistol:

Code: Select all

$ git diff --word-diff HEAD HEAD^ WEAPONS.dec
or

Code: Select all

$ git difftool [--tool=<tool>] HEAD HEAD^ WEAPONS.dec
(if you have a diff viewing tool)

e.g. using diiftool with vimdiff2:

Tadaa!


Oh, and another tip.
Using external modules instead of subclassing weapons, one does not need to replace all weapons ingame and break compatibility with other mods. That's why in ZetaBot I simply made a module system. It's a bit simpler, though sometimes a little bit tiresome (but I am working on a simple weapon class to counter that, to make the bulk easier to "transcribe").
User avatar
TDRR
Posts: 816
Joined: Sun Mar 11, 2018 4:15 pm
Location: Venezuela

Re: TDBots: The fast-performing bots v5 (4/5/2019)

Post by TDRR »

Gustavo6046 wrote:Oh, and another tip.
Using external modules instead of subclassing weapons, one does not need to replace all weapons ingame and break compatibility with other mods. That's why in ZetaBot I simply made a module system. It's a bit simpler, though sometimes a little bit tiresome (but I am working on a simple weapon class to counter that, to make the bulk easier to "transcribe").
I most likely won't, because:
1. Modules are harder to implement in a sensible way in DECORATE/ACS

2. Adding mod compatibility is just a matter of copy-pasting one line twice on each weapon

3. I still would break compatibility with many mods if i did use the module system

IMO it's not worth the trouble after having designed my bots around using actual weapons, plus using modules would likely break spectating, which works fine as it is.

About the whole DIFF thing, yeah it didn't help at all, i still couldn't pin down the exact issue.
User avatar
TDRR
Posts: 816
Joined: Sun Mar 11, 2018 4:15 pm
Location: Venezuela

Re: TDBots: The fast-performing bots v6 (4/5/2019)

Post by TDRR »

New update! This one is pretty good, and largely improves bot survival chances and navigation!

Download link in the OP!
User avatar
Gustavo6046
Posts: 138
Joined: Sat May 13, 2017 3:11 pm
Preferred Pronouns: He/Him
Operating System Version (Optional): Arch Linux
Graphics Processor: Intel with Vulkan/Metal Support
Location: Porto Alegre, Brazil

Re: TDBots: The fast-performing bots v5 (4/5/2019)

Post by Gustavo6046 »

Did you know there was a bot of mine before the ZetaBot? It was also in DECORATE. It used to be called the DecoBot. It was discarded because DECORATE wasn't good enough.
TDRR wrote:1. Modules are harder to implement in a sensible way in DECORATE/ACS
You chose to use DECORATE. Pathing can't be done in DECORATE without serious targeting hacks that may potentially have the bot lose track of its target.
If you want to make serious DECORATE-compatible code, without it being too tiresome, you may want you take a look at my ZDCode. It is simple, clean, and compiles to DECORATE :)
(though you'll need Python 3 to use it, as I can't bundle self-containde Windows executables anymore, because I'm on Linux, etc)
2. Adding mod compatibility is just a matter of copy-pasting one line twice on each weapon
Good point.
3. I still would break compatibility with many mods if i did use the module system
I disagree. How so? The module system was designed so that a weapon is only picked up if it is the very same class as a module. Even subclasses are discarded, so there is no risk of a false positive. And I believe compatibility is better, since you don't need to subclass and replace existing weapons.
plus using modules would likely break spectating, which works fine as it is.
Spectating is the least of issues.

Though, now that I think about it, ZetaSpirit is a bit wrongly coded - I should instead make a list of weapons the player holds, take all weapons from the player, and give them back once the player is 'freed'. It'll seem like the player is not holding a weapon, which is accurate, since ZetaBots don't handle weapons like players do: there is little to no weapon switching delay, and states are not simulated; only intervals.
About the whole DIFF thing, yeah it didn't help at all, i still couldn't pin down the exact issue.
Press F to pay respects.
User avatar
TDRR
Posts: 816
Joined: Sun Mar 11, 2018 4:15 pm
Location: Venezuela

Re: TDBots: The fast-performing bots v5 (4/5/2019)

Post by TDRR »

Gustavo6046 wrote:Did you know there was a bot of mine before the ZetaBot? It was also in DECORATE. It used to be called the DecoBot. It was discarded because DECORATE wasn't good enough.

You chose to use DECORATE. Pathing can't be done in DECORATE without serious targeting hacks that may potentially have the bot lose track of its target.
If you want to make serious DECORATE-compatible code, without it being too tiresome, you may want you take a look at my ZDCode. It is simple, clean, and compiles to DECORATE :)
(though you'll need Python 3 to use it, as I can't bundle self-containde Windows executables anymore, because I'm on Linux, etc)
2. Adding mod compatibility is just a matter of copy-pasting one line twice on each weapon
Good point.
3. I still would break compatibility with many mods if i did use the module system
I disagree. How so? The module system was designed so that a weapon is only picked up if it is the very same class as a module. Even subclasses are discarded, so there is no risk of a false positive. And I believe compatibility is better, since you don't need to subclass and replace existing weapons.
plus using modules would likely break spectating, which works fine as it is.
Spectating is the least of issues.
Well, i chose to use DECORATE because i can run it in a version of (G)ZDoom that actually runs really well, and got compatibility with Zandronum.

I doubt ZDCode II is going to help me much in this specific case, because the DECORATE code is almost 100% CustomInventory items that got their own weird conditions (Oddly similar to custom codepointers, something you could probably exploit in ZDCode II and even the resulting DECORATE code would be quite readable)
That said, i'm still waiting on the ZDCode documentation :x

Modules are still a pain to code in DECORATE, ZDCode or not. ZScript is adequate for them because you got all sorts of classes and ways to store stuff in, DECORATE only has user variables and inventory items, both of which are completely useless in the context of weapon modules.

I don't agree that Spectating isn't important. It's what helps me notice all the weird quirks the bots have, and oftentimes i have a bit of fun watching bots have silly deathmatch experiences. Also, it's a feature over all the other DECORATE/ACS bot mods!
User avatar
TDRR
Posts: 816
Joined: Sun Mar 11, 2018 4:15 pm
Location: Venezuela

Re: TDBots: The fast-performing bots v7 (8/5/2019)

Post by TDRR »

New update! Oh boy this one is a MASSIVE improvement over v6b, read the changelog for cool details n' stuff.
By the way, if anyone has a good idea for making the bots less ridiculously pro-player 1337 n0sc0p3r, i'm all ears.

Download link in the OP!
User avatar
TDRR
Posts: 816
Joined: Sun Mar 11, 2018 4:15 pm
Location: Venezuela

Re: TDBots: The fast-performing bots v8 (9/5/2019)

Post by TDRR »

Another update! This one adds Heretic and Hexen support along with small quality-of-life fixes, read the changelog for details.

Download link in the OP!
User avatar
Enjay
 
 
Posts: 26540
Joined: Tue Jul 15, 2003 4:58 pm
Location: Scotland

Re: TDBots: The fast-performing bots v8 (9/5/2019)

Post by Enjay »

I haven't had a chance to check with v8 yet but, in case you are interested, in a DM map with low gravity (set at 200 in MAPINFO), air control (0.25 in MAPINFO) and the opportunity to fall off high buildings:



it was my impression that these usually superior bots fared worse than the default Cajun bots. Not too surprisingly, the default bots don't do desperately well in an environment like this but the TDBots had even more -ve frags from falling into the Abyss than the stock Cajuns did. Also, they seemed less able to cope with the air control - their (usually) enhanced movement seemed to make them change directions quite frequently while not making as much forward progress as the Cajuns and, as a result, they seemed to travel slower when in the air and for shorter distances.

The map isn't currently in a form that is worth releasing (I made the map using a personal resource file and I will need to extract the relevant textures, DECORATE items, models etc to make it so).
User avatar
Gustavo6046
Posts: 138
Joined: Sat May 13, 2017 3:11 pm
Preferred Pronouns: He/Him
Operating System Version (Optional): Arch Linux
Graphics Processor: Intel with Vulkan/Metal Support
Location: Porto Alegre, Brazil

Re: TDBots: The fast-performing bots v8 (9/5/2019)

Post by Gustavo6046 »

Wait, isn't that DM-Morpheus? It looks really rad! (I promise I'll try not to derail the thread)
User avatar
Enjay
 
 
Posts: 26540
Joined: Tue Jul 15, 2003 4:58 pm
Location: Scotland

Re: TDBots: The fast-performing bots v8 (9/5/2019)

Post by Enjay »

It's an approximation of it, yes. It's not a 1 for 1 copy (and wasn't intended to be), just a freehand "This feels about right" version.

viewtopic.php?f=12&t=14126&p=1102529#p1102529
User avatar
TDRR
Posts: 816
Joined: Sun Mar 11, 2018 4:15 pm
Location: Venezuela

Re: TDBots: The fast-performing bots v8 (9/5/2019)

Post by TDRR »

Enjay wrote:I haven't had a chance to check with v8 yet but, in case you are interested, in a DM map with low gravity (set at 200 in MAPINFO), air control (0.25 in MAPINFO) and the opportunity to fall off high buildings:



it was my impression that these usually superior bots fared worse than the default Cajun bots. Not too surprisingly, the default bots don't do desperately well in an environment like this but the TDBots had even more -ve frags from falling into the Abyss than the stock Cajuns did. Also, they seemed less able to cope with the air control - their (usually) enhanced movement seemed to make them change directions quite frequently while not making as much forward progress as the Cajuns and, as a result, they seemed to travel slower when in the air and for shorter distances.

The map isn't currently in a form that is worth releasing (I made the map using a personal resource file and I will need to extract the relevant textures, DECORATE items, models etc to make it so).
I imagined this would be the case, as honestly i never took into account any air control and gravity. In fact, bots have the same friction in air as in ground, so that's why they just change direction in mid air so often. These bots can't have any grasp of how air control works, for them 0% air control is the same as 100%. I could make them behave as if there always was 25% air control, or 0% air control, but they won't react to any changes. Maybe in the very near future, i'm going to add jumping over high ledges. (Most of the time just blind jumping, but occasionally it might help them get to the other side of a pit)

This may have to wait for the ZDCode rewrite, as right now the code is starting to get quite hard to mantain bug-free.

Very cool Morpheus recreation by the way, looks pretty close to the original!
Keldian
Posts: 50
Joined: Tue Apr 03, 2018 3:57 am
Location: Russian Federation, Koroľov

Re: TDBots: The fast-performing bots v8 (9/5/2019)

Post by Keldian »

Can they reload weapons?

Return to “Gameplay Mods”