PDA

View Full Version : Simple changes by CA that would improve the AI



econ21
08-15-2005, 13:39
This is probably an old question, but perhaps worth a new thread. What simple coding changes do people think CA could implement to improve the AI?

To start the ball rolling here are some that strike me immediately:

Strategic AI:

(1) Do not attack when outnumbered. I regularly get attacked by AI armies that are weaker than my own and there seems no strategic reason for a desperate assault.

(2) "Double team" armies. Sometimes the AI will have three full stacks and attack me with them sequentially, losing one each time. Instead, they should put two in "contact" and then attacked with the third, so that the first two could reinforce. That would be a challenge (even if only one army was on the field at a time, I would have lost my ammo by the time the second arrived).

(3) Stack fleets. The naval war is a joke - unlike MTW, the AI builds enough ships but loses now them piecemeal because they seldom stack.

(4) Keep armies out of reach of stronger armies (ie keep inferior armies out of the movement range of stronger armies). The AI in Heroes of Might and Magic III did this very well - it makes it frustrating to bring the AI to battle, but greatly increases the chalenge.

(5) Put good generals in command of large armies. Most large AI armies are led by strutting fools and mewling infants (captains), yet there is the occaisional high starred AI generals sometimes left alone in towns.

Tactical AI:

(1) Do not attack piecemeal. It is fun to fight Seleucids in RTR v6.0, as they combine phalanxes with fiercesome sword units. But what happens is that the non-phalanx stuff charges in, gets defeated and then the phalanxes arrive. If the phalanxes hit at the same time as the other stuff flanked me, I'd be in trouble.

(2) Keep phalanxes in a line and march forward into combat - stop them veering off to make piecemeal unit to unit match ups. In vanilla, a phalanx can crush most other infantry if kept in a solid wall (my German spears could overrun massed armies of hastati with virtually no loss). But the AI can't pull this off and so phalanxes become very weak units for the AI.

(3) Do not open combat by charging in missile or skirmisher units! (Really bizarre behaviour). When attacking the AI does not seem to use ranged superiority if it has it.

(4) Do not open combat by charging generals into battle (suicide Daimyos are sometimes back in RTW).

(5) Do not stand on the defence if getting shot to death. Better try to take some of the enemy with you, than just step into the position of a unit wiped out to enemy missile fire.

(6) Do not parade up and down in front of missile fire when defending wooden walls. (Again very wierd behaviour).

(7) Do not reposition to lower ground when the player tries to maneouvre you off a hill. (This refers to Puzz3Ds observation in the recent MTW AI vs RTW AI thread.

Pretty much all the above should be easy for CA to code and would make the game much more fun. Modders can do a lot - I'm enjoying RTR v6.0 as much as I did MTW - but not everything.

Kor Khan
08-15-2005, 13:49
This is probably an old question, but perhaps worth a new thread. What simple coding changes do people think CA could implement to improve the AI?

To start the ball rolling here are some that strike me immediately:

Strategic AI:

(1) Do not attack when outnumbered. I regularly get attacked by AI armies that are weaker than my own and there seems no strategic reason for a desperate assault.

(2) "Double team" armies. Sometimes the AI will have three full stacks and attack me with them sequentially, losing one each time. Instead, they should put two in "contact" and then attacked with the third, so that the first two could reinforce. That would be a challenge (even if only one army was on the field at a time, I would have lost my ammo by the time the second arrived).

(3) Stack fleets. The naval war is a joke - unlike MTW, the AI builds enough ships but loses now them piecemeal because they seldom stack.

(4) Keep armies out of reach of stronger armies (ie keep inferior armies out of the movement range of stronger armies). The AI in Heroes of Might and Magic III did this very well - it makes it frustrating to bring the AI to battle, but greatly increases the chalenge.

(5) Put good generals in command of large armies. Most large AI armies are led by strutting fools and mewling infants (captains), yet there is the occaisional high starred AI generals sometimes left alone in towns.

Tactical AI:

(1) Do not attack piecemeal. It is fun to fight Seleucids in RTR v6.0, as they combine phalanxes with fiercesome sword units. But what happens is that the non-phalanx stuff charges in, gets defeated and then the phalanxes arrive. If the phalanxes hit at the same time as the other stuff flanked me, I'd be in trouble.

(2) Keep phalanxes in a line and march forward into combat - stop them veering off to make piecemeal unit to unit match ups. In vanilla, a phalanx can crush most other infantry if kept in a solid wall (my German spears could overrun massed armies of hastati with virtually no loss). But the AI can't pull this off and so phalanxes become very weak units for the AI.

(3) Do not open combat by charging in missile or skirmisher units! (Really bizarre behaviour). When attacking the AI does not seem to use ranged superiority if it has it.

(4) Do not open combat by charging generals into battle (suicide Daimyos are sometimes back in RTW).

(5) Do not stand on the defence if getting shot to death. Better try to take some of the enemy with you, than just step into the position of a unit wiped out to enemy missile fire.

(6) Do not parade up and down in front of missile fire when defending wooden walls. (Again very wierd behaviour).

(7) Do not reposition to lower ground when the player tries to maneouvre you off a hill. (This refers to Puzz3Ds observation in the recent MTW AI vs RTW AI thread.

Pretty much all the above should be easy for CA to code and would make the game much more fun. Modders can do a lot - I'm enjoying RTR v6.0 as much as I did MTW - but not everything.

I agree with all of those, I've just got one to add:

When fighting an army with a battleline consisting entirely of phalanx unit, and your line is made out of non-phalanx units, don't engage the enemy head. Stretch your line out far, so as to hopefully envelope the phalanx, and keep a few units (make sure some of these are cavalry) in reserve to flank the enemy. Make sure that the units attacking the front of the phalanx are cheap and discardable ones. NEVER CHARGE A PHALANX HEAD ON WITH CAVALRY!

CBR
08-15-2005, 14:05
Yes and some of does seem to be very easy to implement...at least the outnumbered bit, double team and putting good generals in big stacks.

I have also had fun with RTR last week but the AI is very stupid sometimes and it just feels so easy to correct some of the worst stuff.


CBR

Mongoose
08-15-2005, 17:47
RTR is great. Sadly, the AI kinda ruins it a little.


phhyrus(sp?!), in my game as Rome, left his army and went to manage a small town. I fought 2 battles where he could have easily commanded an army but no....he would rather manage croton. :stwshame:

CBR
08-15-2005, 18:08
phhyrus(sp?!), in my game as Rome, left his army and went to manage a small town. I fought 2 battles that he could have easily commanded an army but no....he would rather manage croton. :stwshame:

In my campaign he stayed at Tarentum while his huge army stayed in Croton...sigh.


CBR

Red Harvest
08-15-2005, 18:47
Good list Simon. On the high ground thing...a big problem is not just the pivot. The AI won't slide laterally with its forces to block the player attempting to gain its flank via a parallel march.

mongoose brings up another point, while I was editing the strategic map to make it more challenging, I found that the AI inherently likes to split its forces for no apparent reason. If I put a nice stack of rebels in a city, the AI would take all but a handful out of the city and march them off to the hinterland to stand alone. The AI would be defeated in detail, even by other AI.

magnum
08-15-2005, 19:06
As far as the splitting units throughout a region goes, I believe it was likely the solution to how the AI would handle 'guessing' what the player would do. Unlike MTW where provinces one a single whole and entering it would cause the attacker to face all units within that province, in RTW players can feint attacks, do amphibious landings, and simply run around known AI units. Thus the AI tends to scatter its units so the player will have to engage them. You'll notice that once you've entered their territory and attacked something that the AI does tend to quickly gather all the units together to fight you. The AIs actions seem to be a simply solution to a complex problem. (Simple, but definately not strategic)

Overall though I agree with the majority of items on the list.

jimmyM
08-15-2005, 20:36
Hmmm... surely a better idea would be to put small delaying/scouting forces in the province+the majority in the city? speculation, speculation, ho hum...


(2) Keep phalanxes in a line and march forward into combat - stop them veering off to make piecemeal unit to unit match ups.

can't overemphasise this. the way the A.I thinks about these guys needs to change...I can pull a.i phalanxes out of formation into a big amorphous blob in the centre of the field with skirmishers they try to chase, then charge in and finish them quickly...but they really should keep in blocks or they're dead and useless - even if it got to the point of the A.I going "these guys are in battle line, they're not deviating 'till they contact the enemy line/general, etc." of course the problem being how do you judge what the line will need to do once its been formed from constituent phalanxes, thtere we go...the whole idea of carefully controlled setups gets derailed by the over-detailed unit-unit matchups the AI does...

AntiochusIII
08-15-2005, 20:43
Not exactly AI but I think diplomacy also counts.

A simple code change (I presume) could help a lot if:

1. AI honours the alliance they have with you. If changing their behavior to actually help you directly is too complicated for BI right now then at least make them more honourable in keeping their peace. It shouldn't be too hard.

Reason: players, even (or especially) casual players like it when AI act sensibly and keep their alliance with them. I know it's Total War but the game's diplomacy that actually works would please many people indeed, hardcore fans or not. People tend to keep their alliances with a trustworthy AI for a long time or even for the rest of the game if the CA coders fear for their lives and want them to have a chance ~;)

2. Protectorates honours their "alliance" with you first even if you are the aggressor against their allies. A simple code change, I believe.

Reason: It angers many people when they lost their protectorates just because they attack that protectorate's allies. It's absurd and often forces you into some irritating diplomatic position ("I forced [faction] to be my protectorate but why the **** is this subject of mine betray me for their ally? I'm their master!" - situation happens often)

gardibolt
08-15-2005, 21:13
The AI dishonoring alliances and back-stabbing is 100% true to life. It's not realistic to be able to entirely rely that your allies will be faithful. They're just not. They look out for their own advantages and rationalize any breaches of good faith they have to incur. If they sense you are weak, they will and should attack you. If you want the alliance to be strong, you have to do things to make it so. There's not a problem here.

I've not had enough experience with protectorates to address the second point.

manbaps
08-15-2005, 21:20
But when the ai offers an alliance/ceasfire then attacks the very next turn whats the point? Backstabbing is fair enough but one turn is hardly enough time to lure your ally into a false sense of security.

As for protectorites there should something coded like there not able to attack for a certain number of turns on top of automatically siding with you. The whole point of them is that the protectorite should be in a position where is will lose so the ai shouldnt break this alliance unless it thinks it can win, breaking the treaty one turn after its made is retarded.

AntiochusIII
08-15-2005, 21:32
The AI dishonoring alliances and back-stabbing is 100% true to life. It's not realistic to be able to entirely rely that your allies will be faithful. They're just not. They look out for their own advantages and rationalize any breaches of good faith they have to incur. If they sense you are weak, they will and should attack you. If you want the alliance to be strong, you have to do things to make it so. There's not a problem here.

I've not had enough experience with protectorates to address the second point.But the AI will ALWAYS break the alliance with you whether it's sensible or not. They often break it within..say..1 turn. This should be addressed. That they backstab is fair enough, but be sensible when do so, and I think it should be dependent on the faction characteristics as well, but, of course, it would take a bit more coding for that.

To ally with one faction means alliance...not temporary peace which means absolutely nothing different from neutral stance...

Mongoose
08-15-2005, 21:39
The AI dishonoring alliances and back-stabbing is 100% true to life. It's not realistic to be able to entirely rely that your allies will be faithful. They're just not. They look out for their own advantages and rationalize any breaches of good faith they have to incur. If they sense you are weak, they will and should attack you. If you want the alliance to be strong, you have to do things to make it so. There's not a problem here.

I've not had enough experience with protectorates to address the second point.


No. this is incorrect and the statement shows lack of experience.

I Do *not* have a problem with the AI attacking if you are *weak*. The issue here is that the AI attacks when you are very *Strong*. I have 20 provinces. you have 1. I have a huge army and you have two units of peasants. i have given you 1000's of denarii. why are you attacking me?
~:confused:


The problem is that you cannot rely on them *1%* of the time. The AI will attack no matter how many provinces you have and no matter how much money you give them. A big part of the problem is that the AI will often do this 100% to their *disadvantage*

Some times the AI will

1:Pay *you* for a cease fire
2:Attack

And all in the same turn!


I am sorry, but the AI attacking you no matter how strong and friendly you are, refusing a cease fire even though you haven't fought in years, and paying you for a cease fire that they are going to break on the same turn is 100% BS.

Shaun
08-15-2005, 21:59
i know, the AI is very random, and even the best mods are boring now because of the AI, like RTR 6, the AI is so rubbish that the RTR teams work is ruined(cos RTR is a great mod), its not the modders fault, its CAs for making crap AI. if the modders cood hange the AI, RTW wood be great, but as the AI is as clever as my cat, then RTW is just too easy. All the diplomatic stuuf os pointless, the AI isnt clever enough to know what to do!

Seamus Fermanagh
08-15-2005, 22:25
I Do *not* have a problem with the AI attacking if you are *weak*. The issue here is that the AI attacks when you are very *Strong*. I have 20 provinces. you have 1. I have a huge army and you have two units of peasants. i have given you 1000's of denarii. why are you attacking me?
~:confused:

A good point here. Moreover, it's not as though you catch one of their assassins sabotaging or trying to kill one of your dips -- that kind of subterfuge might make sense. Instead, those peasants lay siege to your lev 5 town. ~:eek:

As to the starter of this thread, I wonder how easy some of the proposed alterations would be to code? They seem fairly localized to me, but....

SF

Shaun
08-15-2005, 22:42
well, CA better do these "simple changes" in BI! these little changes cood make RTW good, by having an AI that is clever and can challenge the player, the TW series wood benifit!

BobTheTerrible
08-15-2005, 23:24
i know, the AI is very random, and even the best mods are boring now because of the AI, like RTR 6, the AI is so rubbish that the RTR teams work is ruined(cos RTR is a great mod), its not the modders fault, its CAs for making crap AI. if the modders cood hange the AI, RTW wood be great, but as the AI is as clever as my cat, then RTW is just too easy. All the diplomatic stuuf os pointless, the AI isnt clever enough to know what to do!

Well you have to understand, if they released the AI SDK (is that the abbreviation I'm looking for?) then people could accuse them of forcing the players to make their own AI, and being too lazy to make a good one themselves. Although I'm sure most people would want them to release it, it would be modder's paradise.

Lord Preston
08-16-2005, 04:17
most of the improvements do seem to be simple If statements:

If player_unit_count > ai_unit_count then
.............status = dont_attack
elseif player_unit_count =< ai_unit_count then
.............status = attack
endif

this is an example, BUT it could be more complicated and other exploits created.

continuing with this example, the quality or type of troops is not included in any way, so a huge army of peasents could scare off a small but elite army. so then someway of rating the units in the army needs to be included (can you tell this is going to get complicated?)

even if you use a existing stat such as morale (the best single indicator while not perfect) the increase in processing of fetching, adding and comparing every army battle could be too much.


so my point is, they seem "simple" but thats how you introduce new bugs/exploits and every extra bit of code with validationand checks will increase computing time, for all the improvements listed here i think there would be a notacable increase.

Im sure the AI programmers have come up with these aims but were not able to impliment them due to not everyone having super computers.

hopefully the professionals can come up with ways to get most or at least some of the improvements into BI without making it so you can go eat dinner while it computes a turn

Mongoose
08-16-2005, 05:14
mongoose brings up another point, while I was editing the strategic map to make it more challenging, I found that the AI inherently likes to split its forces for no apparent reason. If I put a nice stack of rebels in a city, the AI would take all but a handful out of the city and march them off to the hinterland to stand alone. The AI would be defeated in detail, even by other AI.


Interesting. I haven't really seen it as you describe it, but in my games the AI will almost always take the 10 star commander to some God forsaken pit while it's army marches off to doom.



10 star Greek general: Remember, this battle is for our country. If we are defeated, there will be no retreat. We are even in numbers but with my amazing tactical skill we may defea...

Greek messenger: Sir, you are urgently needed at croton!

General: Why?

Greek messenger: The town has passed a new law regarding the number of names you can have for a mule. They need you to sign it.

General: I will go there right away! *gallops off at full speed*

Greek soldier: i don't think he's coming back...

Greek soldier two: What do we do now?

Greek solder one: I have the perfect plan! the army is saved!

Firse we send half the army to attack our allies in sicilly, then we send the other half to attack our allies in macedonia!

Greek soldier two: Sounds good. what about or cities in italy? won't the Romans take them?

Greek soldier one: you're right. We should do something else...**Player reloads**

Greek soldier two: What were we talking about about?!

Greek soldier one: i don't know. let's just carry out the plan.

sapi
08-16-2005, 07:41
Strategic/Tactical ai:

Take into account strategic (ie production capacity, economic income, overall troop numbers) rather than tactical (ie outnumbering the local fleet) when declaring war.

Creeper525
08-16-2005, 08:28
most of the improvements do seem to be simple If statements:

If player_unit_count > ai_unit_count then
.............status = dont_attack
elseif player_unit_count =< ai_unit_count then
.............status = attack
endif

this is an example, BUT it could be more complicated and other exploits created.

continuing with this example, the quality or type of troops is not included in any way, so a huge army of peasents could scare off a small but elite army. so then someway of rating the units in the army needs to be included (can you tell this is going to get complicated?)



the AI should run an auto resolve of a battle before actually engageing in it, if the fake auto resolve doesnt come up in their favor, they should not attack

LestaT
08-16-2005, 08:49
Not exactly AI but I think diplomacy also counts.

A simple code change (I presume) could help a lot if:

1. AI honours the alliance they have with you. If changing their behavior to actually help you directly is too complicated for BI right now then at least make them more honourable in keeping their peace. It shouldn't be too hard.

Reason: players, even (or especially) casual players like it when AI act sensibly and keep their alliance with them. I know it's Total War but the game's diplomacy that actually works would please many people indeed, hardcore fans or not. People tend to keep their alliances with a trustworthy AI for a long time or even for the rest of the game if the CA coders fear for their lives and want them to have a chance ~;)

2. Protectorates honours their "alliance" with you first even if you are the aggressor against their allies. A simple code change, I believe.

Reason: It angers many people when they lost their protectorates just because they attack that protectorate's allies. It's absurd and often forces you into some irritating diplomatic position ("I forced [faction] to be my protectorate but why the **** is this subject of mine betray me for their ally? I'm their master!" - situation happens often)


Maybe a trigger that make your rival ally (which is stronger/bigger/bordering) to attack you when your faction leader dies only.

Just a thought.

caesar44
08-16-2005, 11:47
No. this is incorrect and the statement shows lack of experience.

I Do *not* have a problem with the AI attacking if you are *weak*. The issue here is that the AI attacks when you are very *Strong*. I have 20 provinces. you have 1. I have a huge army and you have two units of peasants. i have given you 1000's of denarii. why are you attacking me?
~:confused:


The problem is that you cannot rely on them *1%* of the time. The AI will attack no matter how many provinces you have and no matter how much money you give them. A big part of the problem is that the AI will often do this 100% to their *disadvantage*

Some times the AI will

1:Pay *you* for a cease fire
2:Attack

And all in the same turn!


I am sorry, but the AI attacking you no matter how strong and friendly you are, refusing a cease fire even though you haven't fought in years, and paying you for a cease fire that they are going to break on the same turn is 100% BS.

Agreed .

econ21
08-16-2005, 11:57
the AI should run an auto resolve of a battle before actually engageing in it, if the fake auto resolve doesnt come up in their favor, they should not attack

Yes, in reply to LordPreston's point, I don't think this change is technically difficult. Indeed, I am pretty sure there is already some kind of AI routine where it works out whether to attack based on a computation of relative strengths. In my experience, I will not get a large stack of my own attacked by a tiny AI one. But what I will get fairly regularly is an AI stack that is outnumbered and consists of lower quality troops nonetheless attacking me. I suspect that the AI is setting the bar a little low when deciding whether to attack.

gardibolt
08-16-2005, 17:04
No. this is incorrect and the statement shows lack of experience.

I Do *not* have a problem with the AI attacking if you are *weak*. The issue here is that the AI attacks when you are very *Strong*. I have 20 provinces. you have 1. I have a huge army and you have two units of peasants. i have given you 1000's of denarii. why are you attacking me?
~:confused:


The problem is that you cannot rely on them *1%* of the time. The AI will attack no matter how many provinces you have and no matter how much money you give them. A big part of the problem is that the AI will often do this 100% to their *disadvantage*

Some times the AI will

1:Pay *you* for a cease fire
2:Attack

And all in the same turn!


I am sorry, but the AI attacking you no matter how strong and friendly you are, refusing a cease fire even though you haven't fought in years, and paying you for a cease fire that they are going to break on the same turn is 100% BS.


Well, that certainly is different from my experience. ~:confused: I've cultivated an alliance as Julii with both Pontus and Scythia, and it has lasted for nearly 20 years (40 turns), even though I border both of them. I hold 83 territories and Pontus holds 4 and Scythia holds 5. Maybe you're doing something to offend your allies. I've also had an alliance with the Macedonians against the Greek Cities fall apart when I left my territories bordering Macedon too poorly garrisoned.

But having learned that lesson, I DON'T rely on my allies to be faithful. I garrison large armies on my borders with them, on the highways between our cities. And voila, no backstabbing.

The Stranger
08-16-2005, 17:09
I agree with all of those, I've just got one to add:

When fighting an army with a battleline consisting entirely of phalanx unit, and your line is made out of non-phalanx units, don't engage the enemy head. Stretch your line out far, so as to hopefully envelope the phalanx, and keep a few units (make sure some of these are cavalry) in reserve to flank the enemy. Make sure that the units attacking the front of the phalanx are cheap and discardable ones. NEVER CHARGE A PHALANX HEAD ON WITH CAVALRY!

why not it works friggin brilliant, the companions blow a hole in it and pushes the line back until its seperated in two, with only a tiny amount of casualties. now thats bizarre, how can horses that are unarmoured (i dont think armour really matters thaT much in real) push a phalanx line (phalanx pikemen) back till it seperates and suffer minimal losses. what is that?????

Jambo
08-16-2005, 17:14
Simon, the suggestions you've put forward as simple ways to improve the AI are spot on. However, I'd hazard a guess that if these haven't already been addressed in BI at this stage in development, then they won't be in by final release...

Mongoose
08-16-2005, 17:20
Well, that certainly is different from my experience. ~:confused: I've ivated an alliance as Julii with both Pontus and Scythia, and it has lasted for nearly 20 years (40 turns), even though I border both of them. I hold 83 territories and Pontus holds 4 and Scythia holds 5. Maybe you're doing something to offend your allies. I've also had an alliance with the Macedonians against the Greek Cities fall apart when I left my territories bordering Macedon too poorly garrisoned.

But having learned that lesson, I DON'T rely on my allies to be faithful. I garrison large armies on my borders with them, on the highways between our cities. And voila, no backstabbing.


Maybe the money i gave them offended them? ~:confused: Some factions will often refuse money as a gift for what ever reason. Is the AI so good that it has it's own "iron man" rules? ~;p


What difficulty setting do you play with? Medium diplomacy isn't quite so bad....

econ21
08-16-2005, 17:28
Simon, the suggestions you've put forward as simple ways to improve the AI are spot on. However, I'd hazard a guess that if these haven't already been addressed in BI at this stage in development, then they won't be in by final release...

Yes, I am sure that's right. I wasn't trying to influence BI, which must be pretty much done and dusted now, but just trying to look at the much discussed AI flaws in a constructive way. But you never know - given the success of RTW, it seems inevitable that there will be another TW game and CA may even patch BI somewhere down the line.

Lord Preston
08-16-2005, 17:47
I was just trying to make a general point that while they "seem" simple changes it could be more complicated and hard to impliment without serious performance problems.

using auto resolve to judge what they attack i serously doubt is a viable option, what if there were 3 of your armies and 3 of the AI's armies within attacking distance of each other.

It could attack each army with 1 stack of its own, of group 3 armies and attack 1..... theres 18+ possible auto resolves for it to calculate on just a small area of the map without a actual battle occuring.

im the same as everyone else, and i do expect some of these improvements listed to be included, if a enemy General charages a phalanx in BI i would be very shocked.

Red Harvest
08-16-2005, 17:48
Yes, I am sure that's right. I wasn't trying to influence BI, which must be pretty much done and dusted now, but just trying to look at the much discussed AI flaws in a constructive way. But you never know - given the success of RTW, it seems inevitable that there will be another TW game and CA may even patch BI somewhere down the line.

From most of what I've heard from CA and others about BI and the demo, I don't find it very likely that they are going to do much to really change the game. They chose a different route with RTW and its popular success seems to have sent the message that stimulating gameplay was not worth the effort. For gameplay, it would have been better if RTW had been roundly criticized and shunned. The unfortunate part of that is it can also badly damage a company...so it is lose-lose for players that want some challenge.

As I've said from when BI was first discussed, the schedule appeared far too short to address what was really wrong with the game. Perhaps CA will pull a rabbit out of the hat. I hope so.

Long term...CBR or someone said that CA already intends to use the RTW engine for the next game. Unless AI/gameplay criticisms are taken to heart and addressed, I don't see it being a game that hardcore TW players will be happy with.

Deus ret.
08-16-2005, 17:50
But having learned that lesson, I DON'T rely on my allies to be faithful. I garrison large armies on my borders with them, on the highways between our cities. And voila, no backstabbing.

What's the point of being allied then? The AI rarely attacks me as long as I keep decently-sized border guards, even when we're at war.

Generally it seems that 'medium' is the level at which it's best to play at. Battles run at an endurable speed and the AI behaves somewhat more realistic (I dare not say "challenging") on the campaign map....that's weird.

gardibolt
08-16-2005, 20:39
The main advantage was that eventually I persuaded the Parthians to give me military access so I could descend upon the Armenians from several directions and wipe them out. But it's true, the advantages are fairly marginal.

Mongoose
08-16-2005, 20:53
gardibolt

You still haven't answered my question. What setting are you playing on? Medium diplomacy isn't as bad as VH......

Shaun
08-16-2005, 22:35
any diplomacy is always answered 'no' by the AI!

Oaty
08-17-2005, 03:11
[Strategic AI:








Tactical AI:









(
Pretty much all the above should be easy for CA to code and would make the game much more fun. Modders can do a lot - I'm enjoying RTR v6.0 as much as I did MTW - but not everything.[/QUOTE]


(1)First of all the only difference between dificulty levels seems to be the A.I. has more money and more troops and with more experience. I'd say the A.I. is pretty decent for normal difficulty, but lacks any good improvements on very hard.

To solve the weaker army issue, small stacks are ok in the beginning phase but the A.I. starts making peicemeal of itself later on as it does not always make it a goal to get a full stack.

What the A.I. needs to do is assemble a big army in it's core cities and then head towards the enemy. Instead it sends half a stack and hopes for reenforcements in rout, wich occasionally does work in the A.I.'s favour(rarely).

(2) This probably has an easy solution with how the A.I. works. What the A.I. does is target a stack, if it gets there and does'nt attack because of odds, a second stack may come along like the odds and attack. Then after you beat those 2 off a 3rd stack or more comes alomg and dies too. Easy way around this is to see if there are nearby reenforcements that can reenforce before attacking and then attack.

(3) Ships MTW the A.I. was concerned with protecting it's coasts. RTW the A.I. tries to string out it's ships. Besides protecting thier coasts thier only purpose is to harass and blocakde the enemy. Also A.I. needs to blocakde for more than 1 turn with the only deterrent being a bigger meaner stack is nearby. Quite annoying when you see Pontus or Egypt blocking sea passages around Iberia, especially when it's a nice big stack.

(4) A coward lives to fight another day.

(5) Yes quite a shame the A.I. does'nt use a general for it's biggest battles. Perhaps the hiring of a general in BI was a fix for this.

(1) More combined efforts would definately be nice perhaps even putting it's center in guard mode so it's harder to break the A.I. into 2.

(2) quite simple there I always march phalanxes forward and hope they hit something.

(3) 2 good ones there. The tactic in itsef is not bad but needs to learn to pull back if melee units are close by. Archers are the worst on city assaults, the A.I. is in the city wreaking havoc and then suddenly decide to run around if they get hit even if I have missile superiority it is well worth it to them. They also need to sit back with missile superiority and force the human to come to them even if they are the attacker. Same goes for defending, where the better option is to attack the human instead of getting shot up.

(4) What's a suicidal general? ~;)

(5) I said it in 3

(6) quite obvious there stand back and wait for so many troops to come in then charge home.

(7) Well at least in RTW the A.I only gets to reposition itself(to a new location) once. was quite annoying in MTW to watch the A.I. run from hill to hill. Where the problem comes is that most hills have peaks that are across the red line wich I believe makes it hard for the A.I. to find the right position to defend from the highest ground possible.

pezhetairoi
08-17-2005, 05:06
Maybe one thing to make auto-resolve that much more realistic is to take into account the inherent strengths of some units. For example, rather than calculate hoplite attack at 7, they could give a bonus of 5-6 for its capability to form phalanx, etc. Also, some immense extra bonuses should go to ranged troops, and their chances of loss should be reduced--I have noticed that in autocalc all units lose troops more or less equally. But by right archers should lose virtually nothing unless you were getting a crushing defeat.

HarunTaiwan
08-17-2005, 09:03
Prediction: There will be virtually no change in the AI for B.I.

Sorry to be a pessimist, but it's what I expect from CA.

and look at all those pretty pictures of night battles and units that can swim!

ooooh! ahhhhh! I better pre-order B.I. right now before they run out!

It's so depressing.

Duke John
08-17-2005, 10:43
I did some testing to see what the AI was doing. Below are screenshots of my Sengoku Jidai mod and the AI faction is left alone on the island with no where else to go:
http://upl.silentwhisper.net/uplfolders/upload5/test_merging.jpg
After pressing more End Turns there wasn't any building up going on anymore. Units from the settlements were immediately merged with existing armies (I gave armies plenty of movement points, enabling them to cross half the island in 1 turn and thus being able to merge with an army before said army was already gone).
I don't know how bad this is. It appears as if before saving the AI had a different set of routines (when there were still enemies) than after loading (when it was all alone).

After this test I saved, quitted, then set training times to 10 turns and reloaded. Very little merging of armies was made. Which made it become clear that the AI does not merge armies that are together more than 20 units. So you will very rarely get full stacks and plenty of stacks that range from 10/20 to 19/20. The code might look something like this: if size_armyA + size_armyB > 20 then stop, while it should be something like if size_armyA + size_armyB > 20 then size_armyA=20 and size_armyB = leftovers.

Edit: And now some praise for CA. I made a new test. Made a few turns, saved and reloaded. Then I saw some very nice manuevring:
- 2 or even 3 armies merging before attacking an enemy
- 1 army moving next to the enemy and another attacking resulting in a 2vs1. Sad part was that 6 armies did this in the same turn resulting in 3 2vs1's with the AI losing all. How much better it would have been if it had first merged into 2 larger armies before performing the pincer movement... the AI performing a pincer movement on strategic level?! There is hope for CA! :wink:
- and stretched out frontline with several (small) armies opposing each other; if only the AI also reinforced some of the armies and build some forts to strengthen the frontline it would be something much more worthy of a screenshot then some guys farting in a river.

player1
08-17-2005, 13:16
Hmm...

This reminds me of one of my own games, when AI has city with low public order, but maxed out troops.
It tried every turn to put more troops in city, but since it was impossible, it just had much of high stack armies around of the city. Kinda resambles screen you showed.

Duke John
08-17-2005, 14:08
Thanks player1, then I must remember to keep the AI's settlements happy so that it doesn't use its armies to create one big party.

Puzz3D
08-17-2005, 16:03
Thanks player1, then I must remember to keep the AI's settlements happy so that it doesn't use its armies to create one big party.
That's a good idea because in addition the AI is terrible when sallying from a city. The AI would is better off protecting its provinces with armies positioned outside of its cities.

Shaun
08-17-2005, 17:11
or, the AI wood be better off going back to CA and getting re-programed to be smarter!

gardibolt
08-17-2005, 23:26
Mongoose, in answer to your question I'm playing H campaign/M Battle.

Mongoose
08-17-2005, 23:31
hmm....that might be it.
diplomacy works best on H But H is too easy(IMO).semi-reasonable diplomacy or a harder game? :undecided:

screwtype
08-18-2005, 17:41
continuing with this example, the quality or type of troops is not included in any way, so a huge army of peasents could scare off a small but elite army. so then someway of rating the units in the army needs to be included (can you tell this is going to get complicated?)

Including an algorithm which measures troop quality could hardly be described as "complicated". However, I'm sure your general point that AI programming is more complicated than it might appear to a layman, is quite correct.


even if you use a existing stat such as morale (the best single indicator while not perfect)...

I disagree strongly with this idea. Morale should NEVER be included in AI calculations about whether or not to engage in battle, because morale is a hidden factor. Likewise, leader quality should not be taken into account.

All that should be taken into account in such calculations regarding comparative troop quality, is unit equipment, and the battleground, ie the things that would be visible to an enemy army. Enemy morale and leadership ratings are part of the fog of war and should remain so.


...the increase in processing of fetching, adding and comparing every army battle could be too much.

Not at all. Such calculations would not strain a CPU in the slightest. You just have a rating for each unit type in the game, and then before initiating a battle, you add up all the unit ratings and compare to the enemy total. Simple.

screwtype
08-18-2005, 18:08
Edit.

screwtype
08-18-2005, 18:14
In my experience, I will not get a large stack of my own attacked by a tiny AI one. But what I will get fairly regularly is an AI stack that is outnumbered and consists of lower quality troops nonetheless attacking me. I suspect that the AI is setting the bar a little low when deciding whether to attack.

Yes, the way it should work is that there should be different "bars" for different difficulty levels. Then the kiddies can play on Easy and get to beat up armies smaller than them all the time. The mid-level players are attacked by armies with approximate parity, and on "Hard" the AI attacks only when it has a clear advantage.

screwtype
08-18-2005, 18:24
From most of what I've heard from CA and others about BI and the demo, I don't find it very likely that they are going to do much to really change the game. They chose a different route with RTW and its popular success seems to have sent the message that stimulating gameplay was not worth the effort. For gameplay, it would have been better if RTW had been roundly criticized and shunned. The unfortunate part of that is it can also badly damage a company...so it is lose-lose for players that want some challenge.

As I've said from when BI was first discussed, the schedule appeared far too short to address what was really wrong with the game. Perhaps CA will pull a rabbit out of the hat. I hope so.

Long term...CBR or someone said that CA already intends to use the RTW engine for the next game. Unless AI/gameplay criticisms are taken to heart and addressed, I don't see it being a game that hardcore TW players will be happy with.

Yes I agree, I think if CA were really serious about fixing the problems which have been so widely canvassed on the various forums, it would have shown at least some signs of doing so by now. But they don't care because the game has had such an excellent reception both in terms of reviews and in terms of sales.

The TW series has gone downmarket, it's aimed at the mass kiddie market now, demanding strategy gamers will be lucky if we get the odd bone tossed in our direction from this point.

player1
08-18-2005, 18:32
Yes, the way it should work is that there should be different "bars" for different difficulty levels. Then the kiddies can play on Easy and get to beat up armies smaller than them all the time. The mid-level players are attacked by armies with approximate parity, and on "Hard" the AI attacks only when it has a clear advantage.


It's not so easy as it sound.
This could pretty easily lead to passive AI that doesn't attack at all, since it fears of every single player stack.

The real problem is with match-up algorithm AI uses when attacks, since it very often loses autocalced battles. And it's the computer, the same one who runs AI, who calculates results of autocaled battles.

screwtype
08-18-2005, 18:46
Yes I know it's not as easy as it sounds P1, I'm just suggesting a general principle by which the various difficulty levels could be further and more effectively differentiated.

I just want a game that provides me with a genuine challenge. I've noticed with all of the TW series, the AI will often only attack you with approximate parity, even when it has overwhelming force at its disposal. On hard levels, the AI should not be fighting with one hand tied behind its back. It should be giving it to you with both barrels.

Veresov
08-24-2005, 00:44
I would suggest that the AI be required to use generals to move units. I see too many no general armies with the general sit in city.

pezhetairoi
08-24-2005, 01:57
I think that is a good idea. But that would give factions an overkill of money due to there being too few armies, a too-quick faction destruction rate since their generals tend to die in battle, and makes it a tad boring. Lots of other things'll have to change also to give this one a chance.

Red Harvest
08-24-2005, 05:16
I think that is a good idea. But that would give factions an overkill of money due to there being too few armies, a too-quick faction destruction rate since their generals tend to die in battle, and makes it a tad boring. Lots of other things'll have to change also to give this one a chance.

Heir count is based on territory count. While you can be short or have an excess, their are various aspects of deaths, births, adoptions that are driven by the difference between the "perfect" 1.0 ratio.

It is very difficult to kill off the AI factions in battle, unless they put all their heirs in one stack...they do this at times unfortunately. The game's built in adoption system keeps adding new family members when it is short.

The AI needs some routines to end suiciding generals, true, but having a general in charge of most battles would be a positive (especially assuming they fix this.)

Ludens
08-24-2005, 14:32
Great work, Simon Appleton. I have only a few comments:


Yes, in reply to LordPreston's point, I don't think this change is technically difficult. Indeed, I am pretty sure there is already some kind of AI routine where it works out whether to attack based on a computation of relative strengths. In my experience, I will not get a large stack of my own attacked by a tiny AI one. But what I will get fairly regularly is an AI stack that is outnumbered and consists of lower quality troops nonetheless attacking me. I suspect that the AI is setting the bar a little low when deciding whether to attack.
Perhaps this is because higher difficulty auto-resolves favours the A.I., so the A.I. thinks it has a big advantage while in fact this only applies to auto-resolve and not to manual battles?


(7) Well at least in RTW the A.I only gets to reposition itself(to a new location) once. was quite annoying in MTW to watch the A.I. run from hill to hill.
I disagree: it added to the challenge. The downside of sensibly redeploying A.I. is that it will redeploy sensibly, even if the other location is some distance away.

sunsmountain
08-24-2005, 21:22
AFAIK, The programming methods used in RTW were very similar to those in MTW. In tactical combat, units use multiple If.. Then.. rules to decide what to do, which together are consistent. The campaign map AI was entirely new code.

Most of Simon's comments are 'rules' defining what NOT to do, but you can not make anything out of negatives. The AI needs to know what to DO with the unit every second, not what NOT to do.

The Ai consists of hundreds and hundreds of lines of non-trivial code, you all are making it sound like it's so simple to fix. Simply adding another If.. Then.. statement leads to chaos, compiling trouble and later crashes. In a project as large as RTW, every line of code needs to be checked and double-checked.

Now what gives you the idea that you can think up a simple rule that will even stand the critical eye of even 1 programmer, let alone the team? I'm beginning to understand why they don't study threads like these: AI programming is well hard, and far harder than any of us can imagine. In fact I doubt even one of us has experience with this at all.

I don't know what we CAN do, perhaps simple testing is the best we can do.

As a side effect, most games focus on graphics nowadays, not just because it looks pretty or sells well, but also because it's easeier to program. Graphics code behaves. AI code doesn't (as we can see). It's not really possible for them to share this with us, since it'll be copied immediately if it's good.

econ21
08-24-2005, 22:30
Most of Simon's comments are 'rules' defining what NOT to do, but you can not make anything out of negatives. The AI needs to know what to DO with the unit every second, not what NOT to do.

I'm fairly happy with what the AI does. I've played a lot of strategy games and know not to expect a "deep blue" kind of super-AI. Indeed, TW's AI is already up there among the best AIs I've encountered in any strategy games. Only Civ2/3, Homm3 and Imperialism2 come to mind as perhaps having better AI. Even then, in these games, there were cheesy exploits you could use to pretty much guarantee you'd win and the process of winning was rather less fun, IMO, that the sound and fury of Total War battles. If the RTW AI has enough resources and material to work with, it already gives a fun game. At the strategic level, it builds up and forms large armies that it uses. At the battle level, it can put up a decent fight.

The RTR 6.0 campaign I've just finished is an example of this. Even by the time I took the 50th province, it was still great fun. At a strategic level, I was struggling to subdue about six major factions (none of which I knocked out). At the tactical level, I was still fighting exhausting battles with full stacks of elite Ptolemic or Seleucid armies. It's all the more impressive because TW offers many more choices - that could potentially stall the AI - than most other games.

My suggestions are simple tweaks that I think would improve the AI more. We'll have to agree to disagree over whether they would be feasible or enhance the game.

Tim
08-25-2005, 03:34
The AI dishonoring alliances and back-stabbing is 100% true to life. It's not realistic to be able to entirely rely that your allies will be faithful. They're just not. They look out for their own advantages and rationalize any breaches of good faith they have to incur. If they sense you are weak, they will and should attack you. If you want the alliance to be strong, you have to do things to make it so. There's not a problem here.



Please, don't pander to the poor AI. This is my biggest problem with some players. Ever notice when someone complains about how the AI just stands by and does nothing while its men are being showered by arrows, (especiallyh before first patch) whether in a battle, or particuarlly during a seige? People pop up and say, "well, it's realistic to loose some men to this." Please....

There is NO reason why you cannot maintain alliances. You do not have to conquer the whole map, just 50 provinces. You can't keep alliances for (usually) a few turns if you are close by. I can at least 'role-play' and keep my end of the bargain and watch our empires grow. The alliance system DOES NOT HAVE TO BE FULL PROOF gardibolt, but it should work much better that it does now. Let's be honest, it simply is broke in its current form.

PseRamesses
08-25-2005, 11:59
How hard would it have been to make a fold-out scroll list with settlements to where you want to direct enslaved populations when you´re given the option to "occupy", "enslave", or "eterminate"? This way micromanaging your empires growth would have been a possibility. As for now you have to move your govenors out of every city before the battle that will generate slaves which is tediaus as h_ll.

gardibolt
08-25-2005, 16:57
You can't keep alliances for (usually) a few turns if you are close by.

Pish-tosh. I was directly next to Pontus in my last Julii campaign (indeed, had them surrounded on 3 sides) and kept my alliance with them going without any problems for over 40 years. Same thing for Parthia, though I only bordered them on one side.

Jambo
08-26-2005, 15:00
A lot of what the AI does is relatively speaking OK. Factions which don't entertain phalanxes and horse archers are generally among the more challenging AI opponents. Playing as a faction that also doesn't have phalanxes is also more challenging FOR the human. That's why I quite enjoy playing as the Barbarians or as the Julii.

Particular areas of frustration are mainly limited to :

1. Siege AI. Trouble is there's a lot of siege battles so this inadequacy is only reinforced.

2. Diplomacy. The basic answers (e.g. "No") that are received from the AI are simply not informative enough to make diplomacy worthwhile, especially at the harder difficulty levels. It's often futile to even attempt any of the more interesting diplomatic options that are available. If for instance, the AI were to say "no, but we may reconsider if you were to offer 2,000 denari..." then it's at least putting something constructive back to the player from which they can make an informed decision.

3. Phalanx AI. We all know about this. In the hands of the AI, phalanxes split off from the main battle line and chase units round the map. In the hands of the player and particularly in the city environment the AI launches everything including cavalry, skirmishers, archers and even the general headlong into the front of them leading to mass slaughter. Speaking of which there's also the crazy random charging of AI skirmisher and archer units into melee combat without first using their missile weapons...

4. Suicidal generals. Enough said.

So, if these things can be improved upon in BI, then we might find ourselves with a fairly decent product.

Nelson
08-26-2005, 15:36
If the AI had plenty of good generals it would perform better. Too many AI armies are leaderless. Our own armies seldom are and this leads to a huge advantage on any difficulty. So giving the AI plenty of commanders would make the AI look a bit better.

It’s already been established that given time, the AI can develop decent armies. The AI would get more time if our own offensives were slowed down. This could easily be accomplished by compelling the player to demolish captured buildings and rebuilding his own faction’s structures before new troops could be raised to replenish losses. As it is, you can win a battle, occupy a city and be reconstituted on the very next turn. If you had to replace the infrastructure this would take much longer.

Neither of these modifications would require any change to the AI but would increase the challenge in a realistic manner.

The Mad Scandinavian
08-26-2005, 16:29
Some players seem to believe that it was realistic for nations to sign a peace treaty and then go to war at the start of the next campaign season or in only a few years. Well, they are right. RTW accurately portrays this, but not the alliance system and thus creates a messy and silly situation.

Nations that were naturally antagonistic often did this. Rome and Carthage fought two wars and would have fought more if they had continually stalemated each other. They had every intention to fight both for economic reasons and because of the antagonism. France and England did the same up until the turn of the last century. I could go on naming cases just off the top of my head. The fact is that we live in a very peaceful age. A hundred years ago not everyone would be shocked and angry when one country that hated the other went to war with another. It was not until after WWI that the cost of war was deemed to high to pay.

Alliances were a different matter. Nations that were allied seldom went to war with each other and often backed up each other. That's the whole point of alliances. Forming an alliance was considered a serious act with heavy consequences if the alliance was not honored. As such alliances provided security, particularly for small countries with strong neighbors. There has not been a great deal of cases in history that I can remember where a nation did not honor an alliance. In fact, Rome built its empire, in part, on alliances. She also often used a broken alliance or the attack on an ally as an excuse for war.

RTW completely fails to show this. While being realistic with antagonistic nations this is not counterbalanced by working alliances. The AI does not seem to take into account who one is allied with when it declares war and it does not matter since I have never once seen an ally come to my aid. Often the AI does not aid its computer allies. Worse then allies not honoring an alliance is that allies attack their allies with no consequences. The only alliance that works is between the Roman factions and that does not always bring any worthwhile aid.

I can see no reason why CA made the game this way. It does not seem like it would be difficult to make it work. Granted it can affect balance, but that's a good thing. It would produce a different situation in each game, as long as some randomness was inserted and CA seems to be good at that. In this area I would be happy if CA simple fixed the tendency for allies to attack their allies. At least break an alliance first and have a good reason for it, like in MTW. MTW was not perfect, but it made some sense. I will not buy BI unless this is fixed.
Mad Scandinavian

Red Harvest
08-26-2005, 16:57
Not quite right: historically, once Carthage and Rome were at war, they stayed at war until one was beaten...and forced to sign a treaty. There was then a long peace before another war. And finally, on the 3rd war the Romans decided to destroy Carthage.

Alliances did shift according to how things were going. Look at Sicily...or Numidia...and of course cities in Southern Italy.

The Mad Scandinavian
08-26-2005, 17:46
You're right. Alliances did shift since nations tend to look out for their best interest. But I was thinking more about the beginnings of conflicts. Alliances were often kept at that time, unless it was likely that one's ally would fall. They are made, most often, because one or both countries believe that they will have a better chance of winning a war allied with the other.

Even in cases where defeat seems likely there are cases of allies staying true. Much of Rome's Italian allies did not defect while Hannibal was destroying the countryside nearly unhindered. I don't know if they expected Rome to win in the end, but the situation was pretty bleak for some time. Perhaps a form of Italian nationalism was starting to take place. Still, we are both making generalizations. I concede that alliances could shift and be broken, but believe that they often were not at the beginning of the conflict.

Perhaps you read part of what I wrote on Carthage and Rome wrong. I did not say they stalemated each other nor did I mean to imply it. I understood that Rome won all the Punic Wars. Forgot about the 3rd one. My mistake.

I stand corrected about wars often being started at the start of a new season or after only a few years. I made a generalization that is not accurate. The situation is more variable, but I do believe that some countries were almost preordained to start fighting again, either because they hated each other or for more logical reason: economics, politics, etc.
Mad Scandinavian

screwtype
08-27-2005, 00:22
AIf for instance, the AI were to say "no, but we may reconsider if you were to offer 2,000 denari..." then it's at least putting something constructive back to the player from which they can make an informed decision.


Nice idea Jambo. In fact, I agree with all the comments in your post.

Red Harvest
08-27-2005, 02:44
The Mad Scandinavian,

Your post was not unreasonable, which is why I focused on some clarification. (Welcome to the ORG by the way. ~;) ) The Carthage/Rome bit is one of the reasons I have not complained as much as others about diplomacy. Mainly, I don't have an easy solution. Why? Diplomacy has a lot to do with the "personality" of the culture itself in a historical context.

Let's take Rome for example. During both Pyrrhus' invasion and Hannibal's invasion, Rome refused to negotiate. (They only accepted an agreement with the Samnites because their field commanders had acquiesced after being trapped, and therefore felt obligated...and that only was allowed to stand a few years.) By normal measures they had been soundly defeated and should have been seeking to cut their losses with a favorable treaty, rather than risking absolute defeat. However, they were more beligerent than ever. It was a defining characteristic of Rome, and a very important part of their strength. Other cultures should respond differently, again depending on how they typically regarded friends and enemies.

To be sure, there are aspects of diplomacy that are whacked. I learned to wait, never offering treaties myself, and instead waiting for enemies to do the logical thing. I did play on VH so that most likely made the diplomacy model more challinging.

The Mad Scandinavian
09-01-2005, 22:27
Thanks for the welcome Red Harvest. ~:cheers: