AI Garrison Behavior

Joined
Jun 22, 2016
Messages
320
I’ve noticed in recent versions that occasionally the AI will move their garrison out of a city under siege even when the city is not about to be captured (video example on 3.7.11, deity, the garrison leaves again later in this siege as well).

As you can tell from the streamer’s reaction, this is a fatal move by the AI; even if it wasn’t deity, where they’re not supposed to make suboptimal moves, this is a blunder that serves to massively worsen their position with no benefit and isn’t something you would catch a human player doing. A couple years ago AI was given the option to ungarrison if it felt like the city was lost, but maybe it’s time to revisit that… there’s no reason to give up a free turn to let your capital get assaulted. Scenarios like these really cheapen the game, they feel very exploitive and there doesn’t seem to be a way to even prevent it from happening. Have you noticed this in your games?
 
Yes, the AI prefer to attack from the city (instead of for example fortify) and then retreats the injured unit out of the city before a replacement unit is secured to take its place.
 
I’ve noticed in recent versions that occasionally the AI will move their garrison out of a city under siege even when the city is not about to be captured (video example on 3.7.11, deity, the garrison leaves again later in this siege as well).

As you can tell from the streamer’s reaction, this is a fatal move by the AI; even if it wasn’t deity, where they’re not supposed to make suboptimal moves, this is a blunder that serves to massively worsen their position with no benefit and isn’t something you would catch a human player doing. A couple years ago AI was given the option to ungarrison if it felt like the city was lost, but maybe it’s time to revisit that… there’s no reason to give up a free turn to let your capital get assaulted. Scenarios like these really cheapen the game, they feel very exploitive and there doesn’t seem to be a way to even prevent it from happening. Have you noticed this in your games?
I absolutely have in this last version, I haven't tracked it consistently enough to mark it for a bug, but I have seen it periodically over many games now. Both cities and citadels.
 
I wonder if the issue here is the skirmisher, as I don't think they can shoot from inside cities?
 
It is possible I am thinking of the base game or an earlier version. But I guess that could still be the AI's issue.
 
This has been happening for years, & probably my biggest annoyance with the mod. Great for the player, but not good as a game. In my opinion, the AI should always put a ranged unit in the city, as this can fire causing great damage over time, & change it when it is nearly dead. Once you get to Comp Bowman, the ranged units can hold their own against melee ones.
 
current game on 3.7.12, immortal: wash had one of his spearmen adjacent to his capital on prev turn, but kept it outside the city to attack my recon. He can't see the units to the southeast, and is also at war with japanese to his north (he was winning, but probably not anymore) -- but even the units he can see would suggest to me he should have garrison to mitigate what's coming. Maybe the iroquois UA is throwing off his analysis, but he about to be hit by 5 archers w/ no garrison this turn

Milwaukee went down in 2 turns w/ no garrison, though he tried to send one i just cut them off, that one kinda makes sense given the war he's in already
Spoiler :
1691697701436.png
 
Last edited:
current game on 3.7.12, immortal: wash had one of his spearmen adjacent to his capital on prev turn, but kept it outside the city to attack my recon. He can't see the units to the southeast, and is also at war with japanese to his north (he was winning, but probably not anymore) -- but even the units he can see would suggest to me he should have garrison to mitigate what's coming. Maybe the iroquois UA is throwing off his analysis, but he about to be hit by 5 archers w/ no garrison this turn

Milwaukee went down in 2 turns w/ no garrison, though he tried to send one i just cut them off, that one kinda makes sense given the war he's in already
yeah even ignoring the 4 other units it doesn't know about, those 2 archers are going to kill any spear that attacks that pathfinder and moves into that space. I could maybe see the far left spear hitting the pathfinder (but not fatally), and then the other spear goes int he city for cover so it can attack the archer later.

I do not see a world in which not garrison the city was the best play in this case.
 
* problem is, AI is still fundamentally stupid and "greedy"
* there is a fixed order of things they try. and killing enemies comes before garrisoning
* meaning if they find a net-positive attack they will do it and never even consider moving into the city
* whether or not the spearman might die the next turn is difficult to define, sometimes it's ok to put a unit in danger ... especially if there are no alternative moves but the AI simply picks the first barely acceptable option
* checking the garrison move before attacks is even worse

that said, units which are already inside a city have different logic and if anyone has a savegame of a garrison deserting a city then put it on github
 
It might not be optimal, but simply forcing the AI to never retreat the garrison if a city is damaged is preferable to having cities conquered so cheaply. Then there will be room for AI improvements (such as moving out the garrison if it nets a kill on the besiegers) but for simplicity sake better start safe.
 
Funny story: I took Washington in about 3 turns in the game above. Despite taking the time to complain about how the AI did not properly garrison on here, I also did not garrison it, and later lost it in 3 turns to the Aztecs, who threw off my own defense calculations with similar UA as Washington faced
So we have a human-like performance of tactical AI afterall :D
 
Top Bottom