feedback on AI combat behavior

Spoiler AI-GG unaccompanied, again... :
GG.jpg
My horseman came along that blue line, far behind the frontlines, just for a little trouble and fun. I pillaged the stone and the deer, then destroyed a catapult on the sheep tile and pillaged that too.
Then suddenly the unprotected AI-GG jumped out of the water, right in front of my horseman. Why? He could easily have stayed there for another turn...

I think, the AI could not "see" the horseman in that moment, because I couldn't see the GG either, while he was embarked. But then, why can't the AI "remember" the enemy is near? Maybe there is not enough memory to keep such information for the AI longer than absolutely necessary.

But, on the main battlefield the Harald AI is acting very well. His units rotate every turn and withdraw into FoW. And give me some good hits when I forget them...
 
some comments to all the posts above

My feedback on the AI war behavior (always play as war monger) is that the AI should better understand when its interest are better served by defending only, and not attacking the human or fellow AI territory. In almost every instance when a war is declared, even when the declaration is by the human player, the AI will send in troops to attack in the human's territory. This is true even when the AI's victory condition is peaceful, AND they have huge defensive bonuses (DofF, GW, HeCastle, Ostrogs/Arsenals, etc.) incentivizing the AI to defend only.

In fact, I believe a common war tactic is to DoWar, then sit back and allow the AI to suicide units into the human player's defensive curtain, before the human player attempts an invasion.

It makes sense that the AI would invade when the AI declares war, or is the aggressor.

But can the peacemonger AI with peaceful VC be better taught when NOT to attack/invade, and just sit back and defend?

that's a reasonable idea, but as always the details are hard to get right. near the top of the thread i described a the parameters you can tune to control the AI aggressiveness (COMBAT_AI* in CoreChanges.sql). right now these are global values which seems to work in most situations, but if you have better values and can specify the conditions under which to use them, it's possible to do implement that.

I just played a game where I took a city from the Ottomans using 4 archers and a warrior (game level is on Emperor, and this was in the early game). I couldn't see past the city, I only had sight where my units were. After taking the city, it revealed that the AI had 4 archers and a spearmen unit. Why didn't the AI commit to using those units to protect the city? It seemed like they were just sitting there for awhile, as I had encountered them earlier, but then lost track of where they went in the fog. The AI could have easily defended the city and pushed my small army away, as the AI had a much better terrain advantage as well.

Despite this, overall the combat AI seems great.

I don't have a good explanation for this, the AI looks at "zones" around each city and if the enemy forces aren't much stronger than their own they should counterattack.

I just played a game where Korea tried to launch an amphibious invasion while 3/4 of my navy was on the far side of the continent, but still had 2 ironclads and a cruiser watching him embark his army.

He moved 1/2 of his entire land army into the ocean, between us with absolutely no escorts. He then moved his entire navy (same size, but underpromoted compared to mine) to go and meet mine on the opposite coastline. I told him to move his units, he declared war, I used my 2 ironclads to 1-shot some of his unescorted units and he turned tail and turtled. I had a drag-out fight with his navy and came out with 3 units left and naval supremacy over him. He couldn’t float a plank of wood after that. I don’t know if landing his army and trying to tie me down on defence was the better option, but he probably should have realized moving 10+ embarked units onto my coastline with no escort was a stupid idea.

this is hard to fix unfortunately. there is little coordination between different "activities" the AI is doing ... they shouldn't embark into enemy-dominated water, but it's hard to stop the escort from running away once they are in.

Spoiler AI-GG unaccompanied, again... :
My horseman came along that blue line, far behind the frontlines, just for a little trouble and fun. I pillaged the stone and the deer, then destroyed a catapult on the sheep tile and pillaged that too.
Then suddenly the unprotected AI-GG jumped out of the water, right in front of my horseman. Why? He could easily have stayed there for another turn...

I think, the AI could not "see" the horseman in that moment, because I couldn't see the GG either, while he was embarked. But then, why can't the AI "remember" the enemy is near? Maybe there is not enough memory to keep such information for the AI longer than absolutely necessary.

But, on the main battlefield the Harald AI is acting very well. His units rotate every turn and withdraw into FoW. And give me some good hits when I forget them...

this might be better now, there was a bug where the AI overestimated movement points, so maybe he was trying to create a citadel at that plot but didn't finish.
 
some comments to all the posts above
this might be better now, there was a bug where the AI overestimated movement points, so maybe he was trying to create a citadel at that plot but didn't finish.
He could though, as Denmark. He could also have run back into a city.
 
Saw this in my latest game. So you can see that even though I have a line of musketman death here Portugal keeps placing frigates in that same spot. Its a kill zone that I've just been exploting for a while now.

upload_2019-10-2_21-44-22.png
 
Saw this in my latest game. So you can see that even though I have a line of musketman death here Portugal keeps placing frigates in that same spot. Its a kill zone that I've just been exploting for a while now.

i know, that's a problem, i'm working on it. tracking kills is easy but for how long? also, we must remove those sight-reducing promotions on ships, they make the AI do stupid things.
 
You're adjacent to his border, so he should be able to see it, so that's probably a bug...
Oh, you're right, I didn't notice I was outside his country again... maybe AI see enemy units when approaching their borders, but forget them a little too soon when they are leaving.
 
i know, that's a problem, i'm working on it. tracking kills is easy but for how long? also, we must remove those sight-reducing promotions on ships, they make the AI do stupid things.
:) thank you, and please do it to their GGs as well.
 
I think the best way to address all those issues is modifying how garrison works.

My requirements would be:
1. A city without a garrison should be able to defend from a few barbarians.
2. Adding a garrison should always be benefitial.
3. An unit can never be weaker inside a city than outside, no matter how weak the city is.
4. A city cannot be taken while there's a standing garrison.
5. Scaling must occur naturally through better units, better buildings and more population.
6. Bigger cities last longer.

For this, I would propose the following mechanic.
- Population adds +1 CD (city defense) and +10 HP per pop. Pop base defense can never be lower than 5. Hills add +5 to CD.
- Garrison units add full CS to base CD, before modifiers. Ranged units use RCS, melee ones use CS, naval at half value (?).
- Each city has a basic +20% modifier to CD. Wall-like buildings add +20% to CD each one. Generals (and planes?) add +10% to CD.
- When there is a garrison, damage is split in this way: City HP takes up to half damage, the rest goes to the unit. This means that in a city with 0HP, the garrison takes full damage.
- Buildings that currently add city HP will increase HP gained per pop instead.
EDIT
- A city can only be captured when both city and garrison HP goes to 0.
 
I think the best way to address all those issues is modifying how garrison works.

My requirements would be:
1. A city without a garrison should be able to defend from a few barbarians.
2. Adding a garrison should always be beneficial.
3. An unit can never be weaker inside a city than outside, no matter how weak the city is.
4. A city cannot be taken while there's a standing garrison.
5. Scaling must occur naturally through better units, better buildings and more population.
6. Bigger cities last longer.

For this, I would propose the following mechanic.
- Population adds +1 CD (city defense) and +10 HP per pop. Pop base defense can never be lower than 5. Hills add +5 to CD.
- Garrison units add full CS to base CD, before modifiers. Ranged units use RCS, melee ones use CS, naval at half value (?).
- Each city has a basic +20% modifier to CD. Wall-like buildings add +20% to CD each one. Generals (and planes?) add +10% to CD.
- When there is a garrison, damage is split in this way: City HP takes up to half damage, the rest goes to the unit. This means that in a city with 0HP, the garrison takes full damage.
- Buildings that currently add city HP will increase HP gained per pop instead.
EDIT
- A city can only be captured when both city and garrison HP goes to 0.

The recent change I think has done the job (the cities' CS is always at least as strong as its garrison). In my last game, I took a city from the AI while they still had a few units around. They took it back, but not on the first try, I felt that I had the proper time to secure and I just didn't, but the new garrison strength boost ensure the city wasn't too flimsy. My only concern about it is that early on with spearman un-walled cities got an 11 CS, which can be daunting to take. But the flipside is the new city raider promotion, which is a lot stronger than the previous one.
 
The recent change I think has done the job (the cities' CS is always at least as strong as its garrison). In my last game, I took a city from the AI while they still had a few units around. They took it back, but not on the first try, I felt that I had the proper time to secure and I just didn't, but the new garrison strength boost ensure the city wasn't too flimsy. My only concern about it is that early on with spearman un-walled cities got an 11 CS, which can be daunting to take. But the flipside is the new city raider promotion, which is a lot stronger than the previous one.
When was it changed?
 
I wanted to both congratulate and defame iteroi for making CS units actually combat worthy now:) They are so tenacious, you can't ignore a CS in your back yard as it will cause some serious trouble now if your not careful!
 
So China and Germany just did a double DOW on me late game. In late warfare, the alpha strike can be a very big deal. And yet...China barely touches me. In fact they run their navy (that was in the upper left) back to their waters, even though I stupidly left both my Great Admirals in my lead ship (phew!).

It seems strange to declare like this only to be so timid on the attack. I am prepared pretty well, but I expected to take a least a few casualties.

upload_2019-10-5_11-35-42.png
 
Also, China is building way too many paratroopers. A few are great, but they don't have the combat power of Infantry.
 
Also, China is building way too many paratroopers. A few are great, but they don't have the combat power of Infantry.
To be fair, if China actually had a wide border with most of your land instead of a few coastal cities, those would be more useful, if there weren't like 10 of them, which is indeed too much. More importantly, she's completely ruining her own attack, simply by not positioning units for a war before declaring. I assume they made an agreement to attack you, in which case she really should have prepared before hand.

If I was doing it I'd want a line of infantry with a second line of machine guns and a third line of artillery all over the border, to stop the tanks from getting past my lines. As it is not only is she completely unable to push, and leaving your tanks free to roam her territory and strike her backline, she's also exposed Melbourne, which admittedly is on a border but still would deserve more effort to hold.

I won't even bother complaining about her offensive moves or the lack thereof, because she's wide open for a counter attack, and if you hadn't told us I'd have thought you were the one who declared.
 
Last edited:
Idk if this was mentioned already, if so sorry, but on the latest patch the AI I’m at war with completely ignores my undefended great general in their territory.
 
Idk if this was mentioned already, if so sorry, but on the latest patch the AI I’m at war with completely ignores my undefended great general in their territory.
Meanwhile in 7-29 the AI lancer sniped my great general from the fog with precise maneuvering between my 2 fusiliers.
 
man the devs of this mod have worked some serious magic. i had the best war i've ever had just yesterday

i mean i was getting REKT. they were coming at me with proper naval formations, literally entire fleets.

and playing vanilla so long i made the mistake of leaving one of my islands with just one unit in its city. it was a decent sized island about 5-6 squares with some nice resources but i assumed it'd be safe enough because hey AI is terrible at traversing water right.

WRONG. they actually landed an entire army on that island, out of the blue, catching me by complete surprise. both my fleets were busy engaging with theirs.

they had ranged units at the back, melee units at the front, they formed a circle around my city surrounding it. they used the ranged units first then attacked with the front wall after.

i was seriously both horrified and impressed at the same time. i had to watch helplessly as my colony fell.

i plan to take it back today, half my fleet is sunk but i won that battle i *THINK* they're out of naval units now as honestly the amount of ships they sent were huge so with naval bombardment i should take it back easily.

anyway tl;dr version: i'm impressed and happy with AI combat. i'm so glad i found VP but more than that i'm so glad i bumped up the difficulty levels.

(im playing an older version of VP atm, because the new betas are breaking one or more of my mods and i can't figure out)
 
Top Bottom