Skirmish AI: E323AI 3.22.4 - Page 32

Skirmish AI: E323AI 3.22.4

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

Moderators: hoijui, Moderators

slogic
AI Developer
Posts: 626
Joined: 17 Mar 2008, 19:03

Re: Skirmish AI: E323AI 3.19.1

Post by slogic »

> Haven't tried multiplayer to test whether it desyncs as often.
From AI development point of view i have no tools to break and also fix desyncs except reducing CPU consumption.

> Although the bombers do outnumber my army + defense at least 3 to 1.
So, why you wonder AI built so many AA units? :)

> Any way to stop T1 bombers running into a fighter screen?
If under "fighter" you mean air fighters then I guess NO because most AIR units moves too fast. AI is already taking too much CPU time and optimization is planned. I intend to make GOTO BASE ability after BOMBER's target is destroyed. In a base it will be repaired and sent back to a new target. But this behaviour needs task queues to be implemented.
jseah
Posts: 42
Joined: 10 Jun 2008, 03:28

Re: Skirmish AI: E323AI 3.19.1

Post by jseah »

>Bombers:
I only get the 3:1 ratio about 2-3 mins before I do a bomber run. Most of the time, I have nearly zero bombers and a smidgen of fighters for interception. (AI doesn't use air often)
I get 1/4 AA in attack groups when I have ~5 fighters and 3 gunships.

Perhaps it could reserve AA in the base instead of sending them with attack groups? Unless gunships are in play, then they can be used as escort.
Another behaviour type apart from scout and engage could be implemented for AA. Make AA groups that wander around hunting air units and avoid defences like scouts. Perhaps they should like to stick close to extensions and attack groups but run away from ground resistance.
User avatar
Zydox
Lobby Developer
Posts: 453
Joined: 23 May 2006, 13:54

Re: Skirmish AI: E323AI 3.19.1

Post by Zydox »

slogic wrote:> Haven't tried multiplayer to test whether it desyncs as often.
From AI development point of view i have no tools to break and also fix desyncs except reducing CPU consumption.
Hopefully the desyncs will disapear with the next spring release...
http://springrts.com/mantis/view.php?id=1903

But the crashes which almost always ends my E323 battles is another issue which I hope will be resolved...
User avatar
hoijui
Former Engine Dev
Posts: 4344
Joined: 22 Sep 2007, 09:51

Re: Skirmish AI: E323AI 3.19.1

Post by hoijui »

this desync should be fixed by the following commit by Kloot:
http://github.com/spring/spring/commit/ ... c703cbb99a
User avatar
Sgt Doom
Posts: 144
Joined: 19 Jun 2006, 10:52

Re: Skirmish AI: E323AI 3.19.1

Post by Sgt Doom »

Weeeee new version works great as far as I can tell :lol:
Probably some ways it could play better, but at the moment it surpasses my pathetic skill level.
jseah
Posts: 42
Joined: 10 Jun 2008, 03:28

Re: Skirmish AI: E323AI 3.19.1

Post by jseah »

I would like to add that the way I play early game strongly depends on whether E323AI is in play.

The raiding behaviour is good enough (on open maps) to change how a game works even in multiplayer. Me and my brother play significantly differently when E323AI is on the board. (carefully defended expansions and fast teching instead of T1 land attacks)

I suppose this can be taken as a point of appreciation for an innovative design technique.
slogic
AI Developer
Posts: 626
Joined: 17 Mar 2008, 19:03

Re: Skirmish AI: E323AI 3.19.1

Post by slogic »

When i implement what i'm planning then carefully defended expansions won't help you.

I have my own criticism about latest version:
* ground units target air units (only valid for groups containing at least one ANITAIR unit), and shit happens because when air unit is flying too away Spring somehow declines ATTACK command (how can i track this???) and group stays in micro mode forever, and can directly issue ATTACK command on another targets which are far away, so group is moving not in a cluster
* teching up fails (in gameplay terms) in most of time because of invalid state detection algorithm, so TECH2 factory can be started too earlier which leads AI to metal stall; also AI can't reduce TECH2 unit production and even reclaim FACTORY for metal

Currently i fixed constant assigning of target which can't be reached by group. This saves a LOT of CPU when unreachable target appears (i saw CPU consumption fluctuations were raising up to 24-30% per AI instance!).
slogic
AI Developer
Posts: 626
Joined: 17 Mar 2008, 19:03

Re: Skirmish AI: E323AI 3.19.1

Post by slogic »

Just tested development version of AI vs 3xRAI on Victoria Crater map. With fast teching up it lost (stalled). Without it - wins. :?
Achilla
Posts: 79
Joined: 24 Aug 2009, 15:17

Re: Skirmish AI: E323AI 3.19.1

Post by Achilla »

slogic wrote:Just tested development version of AI vs 3xRAI on Victoria Crater map. With fast teching up it lost (stalled). Without it - wins. :?
Because RAI is passive-defensive. It basically plays like a turtling noob, giving every possible opportunity to rape it in early and middle game. Bad benchmark, try 1v2 KAIK next time.
slogic
AI Developer
Posts: 626
Joined: 17 Mar 2008, 19:03

Re: Skirmish AI: E323AI 3.19.1

Post by slogic »

Surprise, update:

v3.21.1 [2010-05-19]
* fixed potential crash in UnitIdle callback
* somewhat fixed chasing after aircraft with non-anti-aircraft groups
* fixed continuous assigning unreachable target to military group which leads to serious performance hit
* tech-up strategy occurred not perfect so it is selected randomly on game start (temporary step)
* fixed enemy scan procedure where ENGAGE groups preferred unarmed units
* fixed moveRandom() procedure which always returned results in lower-right corner relative to basic position in 2D plane
* anti-air aircraft will be set to guard factory when it is built

Good news that this revision will allow you to play on Victoria Crater with vehicles. You know that vehicles can't enter middle part of the map. On Coast 2 Coast AI still eats all your CPU power, so don't try there.
Attachments
e323ai-3.21.1-win32-debug.zip
(2.47 MiB) Downloaded 324 times
Last edited by slogic on 15 Jul 2010, 10:53, edited 2 times in total.
User avatar
romulous
Posts: 39
Joined: 31 Jan 2010, 12:36

Re: Skirmish AI: E323AI 3.21.1

Post by romulous »

v3.21.1 seems to work ok. Just played 2 AIs, but seriously wasted them.
User avatar
FaerieWithBoots
Posts: 149
Joined: 17 Jun 2009, 13:21

Re: Skirmish AI: E323AI 3.19.1

Post by FaerieWithBoots »

just played a couple of games with this version too. Everything seems to work fine so far. It uses air, fighters guard the lab as intended. Raiders do what they do best.

But still a lot of things in its behaviour that can be improved though.

Scouts often miss opurtunity targets. Ie, a peewee passes a con bot to attack a mex on the other side of the base, while it could take both.

Double T2 factories. In one game it started a second T2 lab immidiatly after the first was finished. Needless to say, it lost afterwards becasue it hadnt any resources to build an army.

Metal spot selection. On ccr it tends to make the first and third mex (you know the line of three starting mexes on ccr) first, the middle one get build last. Is this notmal behaviour? Or shouldnt it take the closest metal spot for its expantion?

Retreat. It still wastes heaps of metal on attacks it cant win, (in enemy territory that is). It is painfull to watch a group of 6 bots run into a group of 30 bots. Why dont attack groups avoid confronations like the scouts do?

Target selection for gunships. Gunships attack groups with AA. They are way too expansive to be wasted on that (XTA). Maybe look into the target selection algorhytm for aircrafts? When calculating the strength of a group with containing AA multiply their strength with, say, 10? (for airscrafts only ofcourse) You did use a different threadmap for each unit type, right? (not sure )

"Emergency units" In allmost every game, while its lab, or base in general, is under attack, it seems to prioritise constructors above combat units. (probably because it just lost a handfull of cons in the attack) Is it posible to push those (and zippers/scouts) back in the buildqueue when a lab is under attack?

Remove the Fark and Necro from the XTA config. It cant ahndle them, they are a waste of metal if you use them for expantion. (in my config they are disabled now)

Request. Save configs and categorisation per map/matchup. On many occations you know beforehand wich strategy is best on a certain map.

But still, very nice AI, i love watching it play and fighting it myself. Hope the comments are of any use to you.
Keep up the good work :D
slogic
AI Developer
Posts: 626
Joined: 17 Mar 2008, 19:03

Re: Skirmish AI: E323AI 3.21.1

Post by slogic »

romulous wrote:v3.21.1 seems to work ok. Just played 2 AIs, but seriously wasted them.
Upload your demo. I need more data to analyze.

FaerieWithBoots, if you played XTA then i have to tell you: XTA config file is a shit and was never updated. All air units are marked as ANTIAIR. Best config file is for BA.

> Scouts often miss opportunity targets...
This is general problem. AI takes a threat at target position, not the position from where it will shoot. Not an easy fix. That is why it "skips" targets.

> Double T2 factories...
Do you mean two of exact type or two different of TECH2? AI can't build two or more factories simultaneously, and can't build duplicates. Duplicate factories are not supported because AI knows how to assist a factory. Though some mods do not allow this.

> Retreat...
Hm, originally Error323 programmed such algorithm: for brand new group when its size is above threshold written in config file, it is sent to target. Group power has no sense here. Obviously, this is done to avoid dull gameplay when both sides enlarge their armies without battles because if one side decided finally to attack, then during its travel the opposite side will gather much more units, and attack initiator will die mostly. This could be fixed with introducing HARASS groups (groups with very large distance will shoot you without any loss for them). SCOUT groups are not true harass groups (from my point of view :) ) cause the y die too fast.

> "Emergency units"...
Are you really think scouts are best for defense? Anyway there is no emergency mode. Personally have no plans on it. There is another more interesting stuff. Also for ENGAGE groups enemy targets near defense matrix (assume it is a base) are boosted in priority, so this should prevent base attack. When enemy is already in our base and crushing everything usually this means nobody has left and AI will die soon.

> Save configs and categorisation per map/matchup
Nooo... I hate configs. AI should be smart enough to exclude useless units automatically. If you see a config file then usually this is because of programmer laziness :)

> Save configs and categorisation per map/matchup
Sure. I'm only asking to not report issues already put in our tracker.
Last edited by slogic on 21 May 2010, 09:15, edited 1 time in total.
User avatar
JohannesH
Posts: 1793
Joined: 07 Apr 2009, 12:43

Re: Skirmish AI: E323AI 3.21.1

Post by JohannesH »

slogic wrote:> Save configs and categorisation per map/matchup
Nooo... I hate configs. AI should be smart enough to exclude useless units automatically. If you see a config file then usually this is because of programmer laziness :)
I dont think its realistic at all to get as good results without map-specific configs as with them. If a programmer cares enough to optimize play for differnt maps and matchups, just shows dedication imo

Even better if a good player makes the configs, who knows well what builds work where
User avatar
FaerieWithBoots
Posts: 149
Joined: 17 Jun 2009, 13:21

Re: Skirmish AI: E323AI 3.19.1

Post by FaerieWithBoots »

With the config i do not only mean wich units to build when. But also how big an attack group should be, how many scouts/raiders you want. On some maps you want to dynamically change the config parameters. Maybe even change them during the game based on enemy behavior. I know this is incredibly hard but worth mentioning :)
slogic
AI Developer
Posts: 626
Joined: 17 Mar 2008, 19:03

Re: Skirmish AI: E323AI 3.19.1

Post by slogic »

Ok, i'll do it sometime. It is not hard.

Forgot to comment the following issue...
>Metal spot selection...
I don't know if it as bug or not yet. I faced this once. There is nothing wrong in the source code at glance. Spot can not be selected if:
1) there is danger around this spot
2) spot was really selected but build place was occupied by mobile unit(s)
3) spot if marked as planned to build, but on fail record is not erased (the most possible)

PS. This issue has been fixed in 3.21.2.
Last edited by slogic on 13 Aug 2010, 23:51, edited 1 time in total.
User avatar
Error323
AI Developer
Posts: 237
Joined: 28 Nov 2006, 16:46

Re: Skirmish AI: E323AI 3.21.1

Post by Error323 »

Here are my thoughts on some of the matters discussed here.
> Scouts often miss opportunity targets...
This is general problem. AI takes a threat at target position, not the position from where it will shoot. Not an easy fix. That is why it "skips" targets.
Indeed, I changed it to scan targets in its LOS on regular intervals so that it wouldn't skip so much. This helped, but the problem is when they are just out of sight, they are missed, however, this is also the case with human players. And scanning the entire enemy list is way to expensive as it would have to be done for each individual unit thats scouting.
> "Emergency units"...
Are you really think scouts are best for defense? Anyway there is no emergency mode. Personally have no plans on it. There is another more interesting stuff. Also for ENGAGE groups enemy targets near defense matrix (assume it is a base) are boosted in priority, so this should prevent base attack. When enemy is already in our base and crushing everything usually this means nobody has left and AI will die soon.
These questions are extremely difficult to answer, FaerieWithBoots is a skilled player, in a lot of cases they are very effective for defense. But I found defense one of the most difficult parts, or rather the decision to attack or defend. The problem being that there are always exceptions where the decision doesn't apply.
> Save configs and categorisation per map/matchup
Nooo... I hate configs. AI should be smart enough to exclude useless units automatically. If you see a config file then usually this is because of programmer laziness :)
Well that's one way of putting it lol. The categorization file was created, because there is no solid way determine if units are e.g. "SCOUT" or "ASSAULT", this information is just not available in the UnitDef.h, nor can it be robustly deduced. These concepts/categories are more highlevel and are vital for good play. However, assigning configs for each map etc is a nightmare, and not the way to go imo.
slogic
AI Developer
Posts: 626
Joined: 17 Mar 2008, 19:03

Re: Skirmish AI: E323AI 3.21.1

Post by slogic »

Error323 wrote:However, assigning configs for each map etc is a nightmare, and not the way to go imo.
If players will send them to us then why not. Implementation is rather easy.
User avatar
Error323
AI Developer
Posts: 237
Joined: 28 Nov 2006, 16:46

Re: Skirmish AI: E323AI 3.19.1

Post by Error323 »

Well it kind of depends on the type of config I guess. But if e.g. categorization will also be available per map it could result in a shower of issues in the issuetracker because of wrong configs. Guess all I'm saying is that no matter what the contents of the configs is, it should never crash the game.
User avatar
Zydox
Lobby Developer
Posts: 453
Joined: 23 May 2006, 13:54

Re: Skirmish AI: E323AI 3.19.1

Post by Zydox »

Hi slogic...

Here's an replay to see how porcing really stops the AI mid game... basically all I have to do is to survive the start of the battle...

The green AI managed to surround his factory with metal extractors... intressting...

20100522_150602_Altored_Divide_0.81.2.zip (7.4mb)
Post Reply

Return to “AI”