One major problem with the A.I.'s ability to attack is it does not attack with enough units, and if said attack fails it sends enemies to attack in a trickling fashion. This is especially true with the new patch.
So there's a few simple things that need to happen:
A) The A.I.'s "prepared for war" check should require more attacking units and it should depend on era.
E.g.
-Ancient:8 combat units (i.e. never)
-Classical: 6 units (the "catch with their pants down" level)
-Medeival: 12 units (level meant to take down walls)
-Industrial: 15 units (level meant to take down castles)
-Modern: 12 units (has artillery)
-Future: no req (nukes)
B) The A.I. needs to check if it has taken a city within (15 turns + (the hex distance between their capitals*ArbitraryMapSizeFactor/10 turns)). If it has not it needs to immediately sue for peace with a stalemate proposition. If it has, it needs to make this check every 20 turns.
C) If a stalemate proposition is refused by the other player, or if the other player declares war and the A.I. does not have enough units, or (optionally) if the other other player takes 2 more cities than the A.I. takes of the player, it needs to go into defense mode.
Defense mode is simple: Units go to the nearest friendly city (or if it does not take too much processing time, the city with the least defenseive units nearby), and do not move more than 1 tile away from it unless it can make an immediate attack. Alternatively, rather than 1 tile from a city, it does not leave cultural borders, although same with the other it is fine if it allows them an immediate attack. The upshot of the latter is allowing them more mobility in defending cities in need.
As well, while in defense mode, it should focus more on units, in attempt to have enough units to leave defensive mode.
D) Every 20-25 turns, an A.I. in defense mode will check whether it can leave defense mode or not. To leave defense mode, it simply needs the unit requirement in part A.
Edit: One more thing- Peace treaties
E)Peace treaties are way too high. Way Way Way Way Way too high. Peace offerings should never ever exceed 250 gold worth * eramod, where era mod is simply 1,2,3.... for ancient,classical,medeival...
So there's a few simple things that need to happen:
A) The A.I.'s "prepared for war" check should require more attacking units and it should depend on era.
E.g.
-Ancient:8 combat units (i.e. never)
-Classical: 6 units (the "catch with their pants down" level)
-Medeival: 12 units (level meant to take down walls)
-Industrial: 15 units (level meant to take down castles)
-Modern: 12 units (has artillery)
-Future: no req (nukes)
B) The A.I. needs to check if it has taken a city within (15 turns + (the hex distance between their capitals*ArbitraryMapSizeFactor/10 turns)). If it has not it needs to immediately sue for peace with a stalemate proposition. If it has, it needs to make this check every 20 turns.
C) If a stalemate proposition is refused by the other player, or if the other player declares war and the A.I. does not have enough units, or (optionally) if the other other player takes 2 more cities than the A.I. takes of the player, it needs to go into defense mode.
Defense mode is simple: Units go to the nearest friendly city (or if it does not take too much processing time, the city with the least defenseive units nearby), and do not move more than 1 tile away from it unless it can make an immediate attack. Alternatively, rather than 1 tile from a city, it does not leave cultural borders, although same with the other it is fine if it allows them an immediate attack. The upshot of the latter is allowing them more mobility in defending cities in need.
As well, while in defense mode, it should focus more on units, in attempt to have enough units to leave defensive mode.
D) Every 20-25 turns, an A.I. in defense mode will check whether it can leave defense mode or not. To leave defense mode, it simply needs the unit requirement in part A.
Edit: One more thing- Peace treaties
E)Peace treaties are way too high. Way Way Way Way Way too high. Peace offerings should never ever exceed 250 gold worth * eramod, where era mod is simply 1,2,3.... for ancient,classical,medeival...