RAI v0.601 - Page 10

RAI v0.601

Here is where ideas can be collected for the skirmish AI in development

Moderators: hoijui, Moderators

Reth
AI Developer
Posts: 70
Joined: 15 Aug 2006, 14:05

Re: RAI v0.600

Post by Reth »

copy/move the dll to {spring directory}\AI\Bot-libs\
goduranus
Posts: 30
Joined: 25 Jul 2008, 10:49

Re: RAI v0.600

Post by goduranus »

I've see some really nice stuff like starting with hover plant on water maps, but kbot plants on land maps. Your AI seem to beat others I'm using on land or on water. But it doesn't build any ships, and not a whole lot of airplanes.
Reth
AI Developer
Posts: 70
Joined: 15 Aug 2006, 14:05

Re: RAI v0.600

Post by Reth »

It depends a lot on the map & mod. It may not use boats until constructors are wandering close enough to the shore and may not build certain types of units until it has enough resources.
User avatar
1v0ry_k1ng
Posts: 4656
Joined: 10 Mar 2006, 10:24

Re: RAI v0.600

Post by 1v0ry_k1ng »

dling now, good work man :D
User avatar
Umrug
Posts: 141
Joined: 27 Nov 2006, 12:57

Re: RAI v0.600

Post by Umrug »

Well, what can I say... probably the best AI currently. I'd say its pretty slow in the beginning - opposite of aggressive one it once was. Played several games of BA - not a single crash.

To change (IMHO!!!) - make it build less t1 factories during first few minutes of the game.

Thanks for the good work! :) :) :)
User avatar
Umrug
Posts: 141
Joined: 27 Nov 2006, 12:57

Re: RAI v0.600

Post by Umrug »

OK I take my words about it being the best AI back. Gets absolutely pwned by KAIK 0.13 on all land maps. But, well, KAIK is good, so thats not a problem by itself.
Also:
Does detect Sands of War to be water map (i.e. start with air/ships), but does not detect Lava Reef or Ooooweeee - i guess that should be fixed.
Does not build static defense (or builds one LLT in first 10 minutes) - that, IMHO, should be changed, defense is very important.
Does it ever go to fusions/nukes/berthas? I never saw it getting there.

I only tested it with BA 6.31.
Again, thanks for developing it and please let me know if I can help with testing it - Ive got some time.
Reth
AI Developer
Posts: 70
Joined: 15 Aug 2006, 14:05

Re: RAI v0.600

Post by Reth »

Ooooweeee seems to work off of the VoidWater map property, though I'm not sure about your copy of Lava Reef either it did the same or simply wasn't using the waterdamage property and didn't have harmful lava? The issue gets complicated. There seems to be some inconsistency between how modders, mappers and the current version of spring treat the property. Spring does not seem to restrict building or using floating units in a void water, though I'm guessing that this is just a bug and that modders/mappers were likely working around it. I should probably just restrict all units/building that can't fly from areas with a void water since that seems to be the way that it was suppose to be used.

To answer your other questions, a lot of the code related to the economy and construction choses is likely to change in future versions. It should build fusions/nukes/berthas once it has enough resources although its hard to say how much it needs since it depends on the mod.
User avatar
yuritch
Spring 1944 Developer
Posts: 1018
Joined: 11 Oct 2005, 07:18

Re: RAI v0.600

Post by yuritch »

Void water does not (and should not) restrict anything, it just prevents water from being drawn. Usable for 'space' maps and mods that treat spacecraft like ships (FF comes to mind, AFAIR it used that hack). Of course you can still build 'normal' shps in there with other mods, the engine can not know this map isn't suited for non-space mods.
There is a special waterdamage value that completely prevents units from entering water, you should be looking for that instead. Spring changelog from some very old version has this said on it:
New .smd command MAP/WATER/WaterDamage. Indicates the amount of damage per second units take for being in "water". Make it >1000 to prevent ground units from entering water entirely, >10000 prevents hovers from moving over water.
Reth
AI Developer
Posts: 70
Joined: 15 Aug 2006, 14:05

Re: RAI v0.600

Post by Reth »

waterdamage is detected but it isn't used for the particular maps Umrug has mentioned, Ooooweeee is a map were the water represents a cloud-line. The issues of FF did come to mind and I know it will be adversely affected, a little. But while the problem in FF could easily be fixed by using canFly instead of canFloat, this isn't much else that can be done to prevent RAI from building floating units in cloud/space maps.
Last edited by Reth on 05 Aug 2008, 06:07, edited 1 time in total.
Reth
AI Developer
Posts: 70
Joined: 15 Aug 2006, 14:05

Re: RAI v0.600

Post by Reth »

There was actual a very simple workaround to detecting FF's style of factories, so it looks like it will be unaffected by the new code. As of yet I am not planning on releasing a patched version but if anything else needs to be fixed then this change will be included, otherwise it will be in the next version.
User avatar
Agon
Posts: 527
Joined: 16 May 2007, 18:33

Re: RAI v0.600

Post by Agon »

Tried to compile 0.6 with CodeBlocks and the description from the wiki but I get an error about:

Edit:
Fixed it. Got it to compile. But does not work in spring.

Maybe someone who knows how to compile a 32/64 bit library for linux could do it, please.
hickop
Posts: 5
Joined: 27 Sep 2008, 13:15

Re: RAI v0.600

Post by hickop »

Cant get RAI 0.600 to compile on Ubuntu Linux 64. Codeblocks return me those errors:

RAI.cpp|9|error: direct.h: No such file or directory|

/usr/include/sys/stat.h||In member function ├óÔé¼╦£void cRAI::ClearLogFiles()├óÔé¼Ôäó:|

/usr/include/sys/stat.h|319|error: too few arguments to function ├óÔé¼╦£int mkdir(const char*, __mode_t)├óÔé¼Ôäó|

RAI.cpp|1087|error: at this point in file|
Reth
AI Developer
Posts: 70
Joined: 15 Aug 2006, 14:05

Re: RAI v0.600

Post by Reth »

There was a mention of how to fix this on the wiki page:
http://spring.clan-sy.com/wiki/AI:RAI

basically it just states to replace <direct.h> with <sys/stat.h>, and add the parameter ( S_IRWXU | S_IRWXG | S_IROTH | S_IXOTH ) to the mkdir() calls.

As far as I could tell, this function doesn't have a 100% common ground usage that would compile for both windows & linux without error.
mcgoo
Posts: 33
Joined: 09 May 2008, 07:31

Re: RAI v0.600

Post by mcgoo »

hi,
is a Rai version compatible with 77b2 in sight ?
Reth
AI Developer
Posts: 70
Joined: 15 Aug 2006, 14:05

Re: RAI v0.601

Post by Reth »

User avatar
hoijui
Former Engine Dev
Posts: 4344
Joined: 22 Sep 2007, 09:51

Re: RAI v0.601

Post by hoijui »

spring SVN now contains RAI v0.601
mcgoo
Posts: 33
Joined: 09 May 2008, 07:31

Re: RAI v0.601

Post by mcgoo »

to many updates this time :D. pls new version for 77b4 .

many thx
mcgoo
User avatar
daryl
Posts: 200
Joined: 08 Oct 2006, 10:33

Re: RAI v0.601

Post by daryl »

no please, a new version for 0.77b5 :lol:
User avatar
hoijui
Former Engine Dev
Posts: 4344
Joined: 22 Sep 2007, 09:51

Re: RAI v0.601

Post by hoijui »

i compiled with a few SVN revisions above 0.77b5, and i did not test it them. just tell me if it does not work.

Linux and Windows version both in the same file (only 32bit)
Attachments
RAI-0.601_Win32_Lin32.zip
contains 32bit version of RAI v0.601 for 0.77b5+
(771.75 KiB) Downloaded 399 times
merijn
Posts: 59
Joined: 17 Feb 2007, 18:43

Re: RAI v0.601

Post by merijn »

Windows dll works fine
Post Reply

Return to “AI”