RatBot, an AI for high oil

Did you create a mod, map, music, or a tool? Present them here and earn feedback!
Note: addon requests do not belong here.
Note, everything uploaded to this forum, MUST have a license!
Post Reply
User avatar
bendib
Regular
Regular
Posts: 1011
Joined: 29 Aug 2010, 05:22
Location: Imeuta
Contact:

RatBot, an AI for high oil

Post by bendib »

So I've been writing a bot for 3.1.x called RatBot. It's designed to be very, very, lethally good at high oil.

So far, in full bases with all structures and modules, it performs near perfect research and does a perfect job of manufacturing. It only supports the cannon research line, but I intend to fix that quickly.

It is a non-cheating AI.

It does not attack at this time, but it does defend itself.

As of writing, the big thing I'm working on is base construction.

Here's the URL to the brand new repo. https://github.com/Subsentient/ratbot/
Also known as Subsentient.
Per
Warzone 2100 Team Member
Warzone 2100 Team Member
Posts: 3780
Joined: 03 Aug 2006, 19:39

Re: RatBot, an AI for high oil

Post by Per »

Looks nice!
User avatar
Tzeentch
Trained
Trained
Posts: 309
Joined: 14 Oct 2012, 14:24

Re: RatBot, an AI for high oil

Post by Tzeentch »

cool, possible to get vids of it in game as some showcase?
User avatar
bendib
Regular
Regular
Posts: 1011
Joined: 29 Aug 2010, 05:22
Location: Imeuta
Contact:

Re: RatBot, an AI for high oil

Post by bendib »

Yeah, I'll record some soon. Working out kinks in the new attack system, and working to get base building in no bases to be more efficient.
Also known as Subsentient.
User avatar
Prot
Trained
Trained
Posts: 242
Joined: 29 Nov 2010, 12:41

Re: RatBot, an AI for high oil

Post by Prot »

Oh my.. I never thought I'll necroposting, sorry for that.. But I have put on this bot, I ported it under 3.2.3 and say, he plays pretty well on NTW-like maps.
It is a pity that the developer abandoned the project. But I'll take my chances and send you a pull request in github with the little changes I made.
https://youtu.be/hLo4AUsJovs
https://youtu.be/8hzFrXMn-Mg

https://github.com/Subsentient/ratbot/pull/2
User avatar
bendib
Regular
Regular
Posts: 1011
Joined: 29 Aug 2010, 05:22
Location: Imeuta
Contact:

Re: RatBot, an AI for high oil

Post by bendib »

Well, good news for the likes of @Prot, I have resumed work on RatBot. I have just released v0.8, which is available as an addon attached.

Quite a lot has been overhauled.
* The cannon strategy was optimised to reflect the current balance. Namely, HPV is used and upgraded until needle gun, and Python is replaced for HPV with Cobra.
* RatBot now has better logic for retreat/attack, and uses a rally point.
* Now uses repair facilities.
* Now supports recycling, though I'm seeing some bugs that might be due to the WZ JS API.
* Now uses "target separation", meaning it uses AT units against tanks, AP units against borgs. It does this with some manual targeting once already in range of an enemy.
* Now requires 3.2+, untested on 3.2, probably better to use 3.3.x.
* Noticably faster at building bases, at the expense of bases often looking a bit lopsided.

RatBot 0.8 has uniformly beaten the following AIs in 1v1:
* Nexus
* Semperfi
* Semperfi JS
* NullBot
* BoneCrusher

The setting for RatBot was Hard, and the opponents set on Insane.

I think this reflects RatBot's design goal of being the high oil bot of choice. These other AIs would of course kill RatBot effortlessly in low oil.

Overall, it's a lot stronger than it was, but there's still work to do.
Expect more updates.

Repo, as always: https://github.com/Subsentient/ratbot
And you can find the addon for 0.8 attached.
Attachments
ratbot-0.8.wz
RatBot addon for 3.2+ (3.3+ recommended)
(8.37 KiB) Downloaded 129 times
Also known as Subsentient.
User avatar
Prot
Trained
Trained
Posts: 242
Joined: 29 Nov 2010, 12:41

Re: RatBot, an AI for high oil

Post by Prot »

It's very good that more and more bots are appearing for our favorite game!
But unfortunately I tried version 0.8 on dramatic, it gets completely stuck and doesn't play.
https://youtu.be/QDoZM5Mo9O0
In any case, do not stop in development, I really want to see good bots for any game modes.
I'm even thinking of resuming the WZ AI Tournament again
User avatar
bendib
Regular
Regular
Posts: 1011
Joined: 29 Aug 2010, 05:22
Location: Imeuta
Contact:

Re: RatBot, an AI for high oil

Post by bendib »

Prot wrote: 21 Apr 2020, 08:09 It's very good that more and more bots are appearing for our favorite game!
But unfortunately I tried version 0.8 on dramatic, it gets completely stuck and doesn't play.
https://youtu.be/QDoZM5Mo9O0
In any case, do not stop in development, I really want to see good bots for any game modes.
I'm even thinking of resuming the WZ AI Tournament again
Found it -- seems to mostly be an issue on low truck maps. I'm going to have to rewrite some of the base building code, but it should be done sometime today.
I'll release 0.9 when I'm done. There's some weirdness with the ordering of build commands getting sent out, which is making RatBot not build a factory.
Also known as Subsentient.
User avatar
bendib
Regular
Regular
Posts: 1011
Joined: 29 Aug 2010, 05:22
Location: Imeuta
Contact:

Re: RatBot, an AI for high oil

Post by bendib »

Okay, so after a *few* days, I finally got something that functions more or less correctly on low truck maps. There's still some weirdness, like explicitly ignoring requests to not build with under 2 trucks, but it's fairly normal and no longer gets stuck. 3 ratbots always beat 4 nullbots on NTWMax2-T1.

I'd like to take this moment to point out that there is some serious bizarro crap going on in the WZ JS API. I had to use my own groups because it turned out that the builtin groups are unusable.

Here's the .wz mod file. Enjoy!

https://github.com/Subsentient/ratbot
Attachments
RatBot-0.9.wz
RatBot 0.9 for WZ 3.3.0+
(9.21 KiB) Downloaded 146 times
Also known as Subsentient.
User avatar
Prot
Trained
Trained
Posts: 242
Joined: 29 Nov 2010, 12:41

Re: RatBot, an AI for high oil

Post by Prot »

He is still stuck, but at this time, he try build many gens when no power left.
https://youtu.be/JFR4fhMG3HE
Post Reply