[v0.9.0] ZetaBot: The ZScript Bot

Projects that alter game functions but do not include new maps belong here.
Forum rules
The Projects forums are ONLY for YOUR 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.

Re: [REPLAN] ζetaBots: The ZScript Bot

Postby Rachael » Sat Mar 10, 2018 12:14 pm

If the bots are programmed properly, using player structures rather than being actual actors, themselves, yes.
User avatar
Rachael
Webmaster
 
Joined: 13 Jan 2004
Discord: Rachael#3767
Twitch ID: madamerachelle
Github ID: madame-rachelle
Operating System: Windows 10/8.1/8/201x 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: nVidia with Vulkan support

Re: [REPLAN] ζetaBots: The ZScript Bot

Postby scalliano » Thu Mar 15, 2018 12:27 pm

Does this mean that bots could potentially be used as enemies/allies in SP/co-op?
User avatar
scalliano
Socially Distant
 
Joined: 21 Jun 2005
Location: Ireland

Re: [REPLAN] ζetaBots: The ZScript Bot

Postby Gustavo6046 » Mon Mar 26, 2018 8:13 pm

I figured it was answer/update time. Okay, here we go:

Rachael wrote:You should probably know that GZDoom currently has plans to ditch its internal bot system completely and use ZScript for its bots, sometime in the future. This is one of the projects I was thinking about when that hit the planning phase, but I don't know if you are interested.


Well, I am interested in helping with the pathing and with relating the bot movement with how a human would act in a certain circumstance.

Dark-Assassin wrote:Any chance that a system like A* could be used instead? This would have to account for line actions and such too.


It currently uses a sort of A* in the pathing algorithm. Line actions are counted via path nodes (no navigation mesh pls).

scalliano wrote:Does this mean that bots could potentially be used as enemies/allies in SP/co-op?


Probably, but it has to be simple maps. Doors will be trouble (I'm still trying to figure out how to get a non-player pawn actor to Use a door or a lift!)
User avatar
Gustavo6046
 
Joined: 13 May 2017
Location: In an urban area in Brazil.
Discord: Gustavo6046#9009

Re: [70%] ζetaBots: The ZScript Bot

Postby TheRailgunner » Tue Mar 27, 2018 11:26 am

I take it it's prohibitively difficult to devise some way to essentially trick GZD into thinking the bot is providing genuine player inputs to a controlled playerpawn? Is it even possible?

Zetabots interests me because of the potential for far superior monster AI - things like cover, limited pursuit, drawing fire, evasive actions, smarter pathfinding, etc., mostly because Doom's basic monster behavior (rush directly in the direction of the player, even if totally obstructed or blocked despite the clear presence of an open path to the player because they cannot draw or remember a path to their targets) is trash and not immersive after 25 years.
User avatar
TheRailgunner
Pour one out for Slax - one of ZDoom forum's finest.
 
Joined: 09 Jul 2013

Re: [70%] ζetaBots: The ZScript Bot

Postby Gustavo6046 » Tue Mar 27, 2018 4:08 pm

Maybe with some engine modification, which, given GZDoom's complexity, might be a bit difficult to do. I'd have to
  1. draw a line from Actor to UseRange units at its front,
  2. find all linedefs that intersect with this line,
  3. if this linedef is an Use line, has an action, and can be used by the actor (perform common Use line checks), then perform that action.

That might also be doable with ACS: an array of line actions. Since ZScript can access DECORATE functions, it can access ACS_Execute, and therefore execute a specifically-numbered script. The problem would be finding the linedefs that are in front of the actor, and getting their special - I fear that might not be doable without C++ work (intensive russian labor 24/7 for 5 years).
User avatar
Gustavo6046
 
Joined: 13 May 2017
Location: In an urban area in Brazil.
Discord: Gustavo6046#9009

Re: [70%] ζetaBots: The ZScript Bot

Postby Marisa Kirisame » Wed Mar 28, 2018 5:03 am

Alternatively I can just export P_ActivateLine to the ZScript side and it would allow bots to "press use" on them. Finding the line in front of an actor is as simple as running a trace (cool new thing in 3.3 btw) and checking for usable lines (while aborting if a "block use" line is found).
User avatar
Marisa Kirisame
ZScript Crimester
 
 
 
Joined: 08 Feb 2008
Location: Vigo, Galicia
Discord: 霧雨魔理沙#1666
Twitch ID: magusmarisa
Github ID: OrdinaryMagician
Operating System: Other Linux 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: nVidia with Vulkan support

Re: [70%] ζetaBots: The ZScript Bot

Postby Gustavo6046 » Wed Mar 28, 2018 4:43 pm

Exactly, Marisa. That would be something really easy if a line (with index, not tag!) could be activated separately. The map should be more exposed to the ZScript modders (the BSP tree would then be discarded?) so that I can also work futurely in a pseudo-roguelike project.

I also have a simple, rough, and very coarse roadmap:
Image
User avatar
Gustavo6046
 
Joined: 13 May 2017
Location: In an urban area in Brazil.
Discord: Gustavo6046#9009

Re: [70%] ζetaBots: The ZScript Bot

Postby Nash » Wed Mar 28, 2018 11:29 pm

The devs have already mentioned the intention to scriptify the internal bots... why not work together with them to perhaps phase out ZCajun in favour for your completely re-written bots? You'll get better tools to work with due to the project being engine-side too...
User avatar
Nash
 
 
 
Joined: 27 Oct 2003
Location: Kuala Lumpur, Malaysia
Github ID: nashmuhandes

Re: [70%] ζetaBots: The ZScript Bot

Postby Rachael » Thu Mar 29, 2018 12:57 am

My idea was to make the implementation work a lot like the ZCajun ones do but better. Using player inputs so they can be recorded in demos. Gustavo and Marisa both mentioned making the bots follow pathing nodes - I personally think they should talk to one another and see if their goals align well enough that they can work together.

That being said though, if their goals are far enough apart we'll just have to settle for "bot classes" so to speak - i.e. one set of bots following one bot class, and one bot set following another, etc. If done right, both could easily become official... Either way, anyone who uses bots would probably love to see the dated ZCajun implementation gone.
User avatar
Rachael
Webmaster
 
Joined: 13 Jan 2004
Discord: Rachael#3767
Twitch ID: madamerachelle
Github ID: madame-rachelle
Operating System: Windows 10/8.1/8/201x 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: nVidia with Vulkan support

Re: [70%] ζetaBots: The ZScript Bot

Postby TheRailgunner » Thu Mar 29, 2018 11:16 am

Rachael wrote:My idea was to make the implementation work a lot like the ZCajun ones do but better. Using player inputs so they can be recorded in demos. Gustavo and Marisa both mentioned making the bots follow pathing nodes - I personally think they should talk to one another and see if their goals align well enough that they can work together.

That being said though, if their goals are far enough apart we'll just have to settle for "bot classes" so to speak - i.e. one set of bots following one bot class, and one bot set following another, etc. If done right, both could easily become official... Either way, anyone who uses bots would probably love to see the dated ZCajun implementation gone.


Is it possible to effectively replace a monster with such a bot? Apart from the need to essentially turn them into player actors so they can use the ZetaBot system, it doesn't seem unrealistic, and I certainly hope it's a realistic possibility (you mentioned having the bots talking to each other and cooperating based off of their objectives - actually a decent step beyond my initial hopes). At least, I hope so - I'm not going to pretend I understand much of how this works or why, but Zeta seems very, very promising.
User avatar
TheRailgunner
Pour one out for Slax - one of ZDoom forum's finest.
 
Joined: 09 Jul 2013

Re: [70%] ζetaBots: The ZScript Bot

Postby Marisa Kirisame » Thu Mar 29, 2018 11:40 am

By the way, if we're to integrate this officially, I think a more proper way to have bots understand how and when to use weapons and items would be to add rating/desirability virtual functions to them like Unreal/UT does.
User avatar
Marisa Kirisame
ZScript Crimester
 
 
 
Joined: 08 Feb 2008
Location: Vigo, Galicia
Discord: 霧雨魔理沙#1666
Twitch ID: magusmarisa
Github ID: OrdinaryMagician
Operating System: Other Linux 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: nVidia with Vulkan support

Re: [70%] ζetaBots: The ZScript Bot

Postby Gustavo6046 » Thu Mar 29, 2018 12:06 pm

What a coincidence!

I had UT99's bots and weapon system in mind when I designed this, since I wrapped the Doom weapons in a Zeta Weapon module (which means they can be fired and rated from any actor shooter to any actor target), and that includes RateSelf and AltRateSelf.

I have no plans to add Heretic support right out - I want to first make the bot avoid walls and obstacles (which is being a task slightly harder than I expected). Hexen will be a little difficult, since it involves multiple classes, but that should already work (since I support multiple player classes). Another difficulty will be adapting the available modules to the current IWADs and maybe even loaded mods - since currently these are stored in a CVar, that should not be an issue, since CVars are specific to a game; the problem is to set them in CVARINFO for these IWADs).

Either way, welcome to Alpha!
User avatar
Gustavo6046
 
Joined: 13 May 2017
Location: In an urban area in Brazil.
Discord: Gustavo6046#9009

Re: [ALPHA 0.1.0a] ζetaBots: The ZScript Bot

Postby Melodica » Thu Mar 29, 2018 1:22 pm

I tried downloading through the provided link and it gives me "Error 403, denied". Could you provide a mirror link?
User avatar
Melodica
 
Joined: 14 Feb 2016
Location: Chile

Re: [ALPHA 0.1.0a] ζetaBots: The ZScript Bot

Postby Gustavo6046 » Thu Mar 29, 2018 3:39 pm

Melodica wrote:I tried downloading through the provided link and it gives me "Error 403, denied". Could you provide a mirror link?

I think I updated it now, do you think it works now?
User avatar
Gustavo6046
 
Joined: 13 May 2017
Location: In an urban area in Brazil.
Discord: Gustavo6046#9009

Re: [ALPHA 0.1.0a] ζetaBots: The ZScript Bot

Postby Melodica » Thu Mar 29, 2018 3:45 pm

Gustavo6046 wrote:
Melodica wrote:I tried downloading through the provided link and it gives me "Error 403, denied". Could you provide a mirror link?

I think I updated it now, do you think it works now?


Still gives the same error. Maybe try to upload it to a different site?
User avatar
Melodica
 
Joined: 14 Feb 2016
Location: Chile

PreviousNext

Return to Gameplay Mods

Who is online

Users browsing this forum: mamaluigisbagel and 17 guests