Suggestions to improve battle AI

This makes a lot of sense! Wish they could alter the AI to focus on weighting small scale battles along with the global scale so the AI could compete better. If I'm going turtle and just defending my borders, it usually doesn't matter what the AI shoots at me (as long as they are not a lot further up the tech tree). I can defend, hit, swap, heal my way to not even allowing them to cross my border. And I'm not an advocate of going backwards and allowing multiple units per tile, but this is because of 1 UPT that it is so much easier to defend your borders. IMHO, it is a lot more fun with the Chess-like experience with 1UPT, but along with 1UPT, they need to ensure the AI knows how to properly use the terrain and 1UPT to stay competitve.
The huge problem that always comes up with these things, and what people don't always take into consideration, is how do you code it. There are a lot of good suggestions in this thread, but how do we actually put it into a meaningful code? We also need to remember that even if we get a code that makes the AI do meaningful actions 90 % of the time, the human player will exploit those final 10 %.

Anyway, as to the thing with local combat progress, something one could introduce is a check for a combat strength evolution on a turn-by-turn basis when AI is in combat. For instance, if they are engaged in a combat situation with me, and my combat strength is constant over time (i.e. I don't lose any units), this should trigger some sort of check. It should be possible to code such a check fairly easily, and if for instance AI hasn't been able to reduce my army strength and unit numbers significantly over, say, a 5 turn period, it should reconsider whether combat is the correct way to proceed, instead of just mindlessly continuing to pile units at me.
 
The huge problem that always comes up with these things, and what people don't always take into consideration, is how do you code it. There are a lot of good suggestions in this thread, but how do we actually put it into a meaningful code? We also need to remember that even if we get a code that makes the AI do meaningful actions 90 % of the time, the human player will exploit those final 10 %.

Anyway, as to the thing with local combat progress, something one could introduce is a check for a combat strength evolution on a turn-by-turn basis when AI is in combat. For instance, if they are engaged in a combat situation with me, and my combat strength is constant over time (i.e. I don't lose any units), this should trigger some sort of check. It should be possible to code such a check fairly easily, and if for instance AI hasn't been able to reduce my army strength and unit numbers significantly over, say, a 5 turn period, it should reconsider whether combat is the correct way to proceed, instead of just mindlessly continuing to pile units at me.

The coding issue is absolutely right, and I suspect the underlying problem in the current scripting is over complication. Each Civs flavor causes a risk factor to vary Civs degree of cautiousness and courageousness. These factors are influenced by level and Genghis and Harold for instant can spend more time dancing than engaging at Prince level. The concept of the flavors is wonderful. The execution just seems too complex with the number of variables in the game.

So to build on this thread, my embellishment for ten is to suggest simplifying the processing task of the AI by introducing "Combat Sub-turns".

A bit like one piece move chess, add interaction with a sub-turn in response to each combat action.....

thus:

1. Civ A’s game turn.
Unit X attacks Civ B’s unit Y. That is a combat action.
The turn for Civ A then pauses whist Civ B reacts with a combat response action for unit Y. i.e Civ B takes an available action for unit Y (and only unit Y) i.e (attack, shield, move, promote, pillage etc as available). However, if unit Y was killed by Civ A, Civ B does not get a combat response action.

2. Game continues, the pause on Civ A’s turn is released. Every time Civ A makes a combat action causes the game to pause for a combat response action by the Civ attacked by Civ A.

Assumptions:
A defending Civ’s unit gets one sub turn combat response action each time it is attacked (until killed).

Civ A only gets to move each of its units according to unit ability (no response combat actions if attacked back during the turn).

The scenario plays out until Civ A’s game turn is complete.

The combat response action process happens for every Civ attacked in combat, including any other Civ already at war with Civ B if attacked by Civ B during its sub turn combat response action initiated by Civ A.

This is the core concept every turn for every player to improve AI combat decisions (outcomes).

There are plenty of issues with this to resolve and it only considers unit on unit combat. However, I kinda like the feel this might bring to game play. Unfortunately, core code changes are way beyond my modding skills to try it out.
 
The huge problem that always comes up with these things, and what people don't always take into consideration, is how do you code it. There are a lot of good suggestions in this thread, but how do we actually put it into a meaningful code? We also need to remember that even if we get a code that makes the AI do meaningful actions 90 % of the time, the human player will exploit those final 10 %.

Anyway, as to the thing with local combat progress, something one could introduce is a check for a combat strength evolution on a turn-by-turn basis when AI is in combat. For instance, if they are engaged in a combat situation with me, and my combat strength is constant over time (i.e. I don't lose any units), this should trigger some sort of check. It should be possible to code such a check fairly easily, and if for instance AI hasn't been able to reduce my army strength and unit numbers significantly over, say, a 5 turn period, it should reconsider whether combat is the correct way to proceed, instead of just mindlessly continuing to pile units at me.

While the tactical AI in general most certainly is pretty convoluted and difficult to code, I don't see any problems with imroving the AI use of air units. They're kind of detached from the map and thus don't have to do the hard job of determining chokepoints and optmal placement or learn to use terrain. I think the improvements that Sake has suggested are pretty easy and straightforward to implement.
Another question though is if the should really try to heal their injured air units. It'd take them 4 turns in a presumably vulnerable position to heal back from red, all that time doing nothing and consuming oil. They most likely can rebuild the dead planes faster.
 
It seems the AI does not use its bombers properly. It will attack a unit protected by an AA gun time and time again until all their units are shot down. While it leaves other important safer targets alone. I hope the devs fix that.

I've seen this happen twice, the second time the AI lost 9 GW bombers in a row, using that silly tactic. :(
 
To me I think the problem is that the AI can't handle complex strategies. So Firaxis probably gave it a go and said, "Ok that's it", "That's as far as we can go". "Budget is spent".

The only way to make it better is to make it more simple. Units should represent groups that are much larger than a "platoon or Company" of men of one type.

They should be Armies, or Divisions or Regiments, or Fleets... They can cling onto each other or attach to form a protective ring or square or line and they move together like that. Combat each turn would represent a much larger scale event that actually lasted the length of a turn.

You could severely cut down on the numbers of units involved and thus processing time... and thus things for the AI to mull over.

Also cities should not have attacks. They should be defended by their occupant. No army there to defend, sorry city just fell.
 
It will be biggest disappointment in cases firaxi neglected to improve AI in this coming civ expansion. besides improving AI combat performance. I like firaxi to expand or make more action in the conduct of diplomacy, espionage and religion.

Diplomacy:
its kinda prostrating to see my two liberated civs turn to each other and wage a never ending war or my liberated civ just to be ganged up by other more advance civs and I cannot do anything, diplomatically to prevent them. the worse thing is they are my friends and even ask me to join them LOL.

Espionage:
I hate to see, my just allied cs will become allied by AI in the next turn because AI rarely fail to conduct coup. and I hate more when the AI who just conducted coup turn out to be my very best friend. how I wish, I could do anything like assassinating their agent or some extra conversation in diplomacy screen to sort it out peacefully our conflicting interest with the cs.

Religion:
founding religion is one thing and spreading it is another, its mechanic of accumulating points to buy missionaries and prophets is both useless and impractical. I race to become one of the founding religion only to get its happiness benefit and nothing else. by the time I enter renaissance era or sometimes in the industrial era, my founded religion did not even covered my whole cities. and in rare cases, see it spreading in neighboring civ/s. its difficult or nothing at all to a chance to relive medieval era religious warfare, waging holy war with your heathen neighbor with an option to convert them or colonize them. to be able to kill or imprison missionary agent and to have religious unit like crusader christendom or gazi or askari for muslim.

this is all I ever wanted to see in the expansions, in order for me to double my 1400 hours ciV gameplay.
 
While the tactical AI in general most certainly is pretty convoluted and difficult to code, I don't see any problems with imroving the AI use of air units. They're kind of detached from the map and thus don't have to do the hard job of determining chokepoints and optmal placement or learn to use terrain. I think the improvements that Sake has suggested are pretty easy and straightforward to implement.
Yes, agreed. Air Combat seems to have been completely neglected in the coding, but hopefully they'll look into it, like they did with Naval combat (suposedly).
Another question though is if the should really try to heal their injured air units. It'd take them 4 turns in a presumably vulnerable position to heal back from red, all that time doing nothing and consuming oil. They most likely can rebuild the dead planes faster.
Well, they might be able to rebuild new planes faster, but that will still require allocation of production plus they will lose out on XP. Even if this is not an issue for AI, they should rather build an extra plane than suicide old planes - if for no other reason, then for immersion. I have a sick fealing that the policy that lets you do massive damage by suiciding a plane was introduced just to make it look like a sensible behavior when the AI does that. :rolleyes:
 
Top Bottom