View Issue Details

IDProjectCategoryLast Update
0019590AI War 2[All Projects] SuggestionAug 29, 2018 11:32 pm
ReporterBadgerBadgerAssigned Tokeith.lamothe 
Severityminor 
Status assignedResolutionopen 
Product Version0.720 
Fixed in Version 
Summary0019590: Make the AI smarter when attacking
DescriptionThis is kindof a reminder/placeholder for generally making the AI more intelligent. Give it some randomization when attacking, better target selection (kill the controller first sometimes?). There was a decent amount of this in email discussions, but

I think right now the AI doesn't come across as, well, very intelligent. For example, when it attacks a planet with a lot of turrets surrounding the wormhole the attack comes through (this seems to be the optimal form of defense) the following happens: Most of the turrets get killed but the AI takes casualties. The AI fleet splits apart to attack all the Power Nodes and the controller. If the Controller doesn't die quickly then the turrets start to respawn. The AI thinks "Oh crap, the planetary defenses are too strong now" and exits via the same wormhole it came in (ie right past the turrets they destroyed the first time). This is not an Artificial Intelligence I'm particularly worried about.

Now, if a human saw this style of defense they'd say "If I'm strong enough to just crush the turrets then stick around and do so. Otherwise leave a few ships caught by the tractors, blow up the controller and then keep going into the enemy territory and wreck as much havoc as possible. And if the humans send a fleet at me, don't fight it, just run further into human territory and do all the damage possible."
TagsNo tags attached.

Activities

x4000Bughunter

Aug 29, 2018 8:00 pm

administrator   ~0048557

Last edited: Aug 29, 2018 8:01 pm

View 2 revisions

This also goes back to some of our discussions in email recently. Keith noted:

On auto-targeting: the AI is already on a long-running separate thread that's nonsim (host-only) and issues GameCommand's, as in AIWC (albeit a separate thread per faction). So in SpecialFaction_AI.DoLongRangePlanning_Subclass() it can give individual commands to each unit if desired. Right now it just routes threat (including retreating and waiting) and decides when guards should sally/hunker/abandon. The operative cases would be:

#region normal fight case for guards

#region normal fight case
(which is for threat, which perhaps should have different priorities than guards)

and:
#region case where we would retreat, but are restrained from doing so by that stupid timer the humans insist we have so they have a chance to play shooting-gallery
(which is oddly self-explanatory)

Addendum: if that third case gave commands to have all the units do a space-invaders-like march back and forth until the retreat-timer expired, that would be an excellent passive-aggressive expression for the AI.

x4000Bughunter

Aug 29, 2018 8:01 pm

administrator   ~0048558

One question to anyone reading along is what specific behaviors are missing from AIWC that we'd like Keith to look into after the performance issues are resolved.

BadgerBadger

Aug 29, 2018 8:13 pm

manager   ~0048561

I for one don't really remember specific AI behaviours per se, but I do notice that the absence of interesting strategies from the AI. It's been a long time since I've played AIWC though.

x4000Bughunter

Aug 29, 2018 8:28 pm

administrator   ~0048562

Oh, and then some of my notes from the last email, too:

Right now I don't have anything super useful to add to the cases you've laid out above, although I will note that there is a new PriorityAsTarget.ImportanceMetric and PriorityToProtect.ImportanceMetric. Ideally the AI, on its own planets, would gain a preference to attack enemy units that are near PriorityToProtect.ImportanceMetrics that are higher than 400 or so, increasing as that goes up. And a preference for attacking anything that's attacking those units, I suppose.

In general some of the spatial awareness stuff coming back would be nice.

Performance and targeting logic seem to be the two main things, though, at the moment, that I'd send your way. I'm not really feeling like transports are super important at the moment.

Something for de-clumping units in transit would be nice, particularly for large units, but it's not a crisis. And ships getting stuck against forcefields is another one of those. Ideally treating some of the huge units like they were forcefields would be kind of useful, but potentially also game-breaking. So that's a thing that I've been stuck on, but it's a complex isolated case to look at.

x4000Bughunter

Aug 29, 2018 8:29 pm

administrator   ~0048563

Badger, I do agree and I know what you mean. Perhaps a perusal of the AIWC codebase by Keith is in order when this comes up, and then he can propose what he thinks would fit in here.

BadgerBadger

Aug 29, 2018 11:32 pm

manager   ~0048578

Also defense needs some work. Here's a save game, go to Tichy to check out the fight. There area bunch of AI units clumped around the Command Station; some of those units are out of range of my fleet, but they aren't moving to get in range. I feel like the fleetships on the far side of the fleetball should move to attack me.

Boring AI response.savemet (45 bytes)
Boring AI response.save (1,263,070 bytes)

Issue History

Date Modified Username Field Change
Apr 13, 2018 12:44 pm BadgerBadger New Issue
Apr 13, 2018 12:44 pm BadgerBadger Status new => assigned
Apr 13, 2018 12:44 pm BadgerBadger Assigned To => keith.lamothe
Aug 29, 2018 8:00 pm x4000Bughunter Note Added: 0048557
Aug 29, 2018 8:01 pm x4000Bughunter Note Added: 0048558
Aug 29, 2018 8:01 pm x4000Bughunter Note Edited: 0048557 View Revisions
Aug 29, 2018 8:13 pm BadgerBadger Note Added: 0048561
Aug 29, 2018 8:28 pm x4000Bughunter Note Added: 0048562
Aug 29, 2018 8:29 pm x4000Bughunter Note Added: 0048563
Aug 29, 2018 11:32 pm BadgerBadger File Added: Boring AI response.savemet
Aug 29, 2018 11:32 pm BadgerBadger File Added: Boring AI response.save
Aug 29, 2018 11:32 pm BadgerBadger Note Added: 0048578