Report Questionable Behavior

I think the AI logic for war declarations is in need of a re-write. Recently I'm playing a large map with around 12 civs. Of those twelve the Incas, Egypt and Myself are the main powers in the world.

Scenario:

(Early Industrial Era)

Egypt is const. at war with Incas which are on the other side of the map.

Egypt is on a lone continent with 2/3rd's of it occupied and the Mayans just above it holding the other 1/3.

Egypt and Inca declare peace in the prob. the 16th war they've fought.

The Mayans which are half the power of Egypt but do have a small vassal(the French) declare war on Egypt???? They obviously can't bring in the Incas because of the recent peace declaration and end up losing 2 cities before the Apolistic Palace members vote successfully to end the war against the Mayans.

Seems that the AI should look at power ratios and not declare on neighbors that are more that double their power. Only a small desert separated them, and Egypt just overwhelmed them with Calvary before they were saved. Just seems so basic. Like Mexico declaring war on the United States or Georgia declaring on Russia and then being saved by the UN.
 
I've also noticed lots of strange things when it comes to the AI declaring war. For instance, in my last game, Japan kept declaring war on me, even though they were so weak (last place) that I laughed every time they did. On top of that, they were so far away that the only time I actually fought them was when one of their boats ended up exploring near my border, despite the fact that we were at war at least 5 times. They were literally at the other side of the map.
 
Here's another issue: If the AI's units are trapped (ie, between closed cultural borders), they should destroy them.

In my last game, Hannibal was living on another island and we were at war. He sent in a stack of units which would have taken a city I couldn't afford to lose, so I bribed him into a peace treaty which caused his units to be bumped to a square which was completely surrounded by cultural borders. Those units stayed there all the way till the modern era. So I had tanks etc and there was still a large stack of horses, macemen etc outside of my border. I know the AI doesn't have to pay as much unit upkeep as players do, but it's still a waste of money keeping those units. He might as well have just destroyed them and built new ones he can actually use.
 
I've also noticed lots of strange things when it comes to the AI declaring war. For instance, in my last game, Japan kept declaring war on me, even though they were so weak (last place) that I laughed every time they did. On top of that, they were so far away that the only time I actually fought them was when one of their boats ended up exploring near my border, despite the fact that we were at war at least 5 times. They were literally at the other side of the map.
I was just coming to the forum to ask a very simple question:

Over the last few patches (of BTSAI), I've noticed the AI seems to be back to the "gang rape the player and ignore neighbors most of the time" behaviour.

For a while there, it seemed that the AI had suddenly figured out how to win a conquest victory by killing off neighbors, but for a while it's been back to "I'll walk through six neighbors I should hate to attack a player I have no hope of eliminating."
 
Hello all!

I don’t know if this has been touched before - workers!

Something should be done to improve the automated worker system.

The most annoying behavior is the "build fortress on top of resources inside cultural border, but outside of city limit" worker behavior. I find it quite useless; why not simply take advantage of the resource. The biggest problem is that this action is prioritized above improving ordinary cities and their resources.

This behavior can be seen very clearly in the scenario "earth 1862" (by Lokolus) if you play as Russians. The workers when automated will build road + fortress to tons of resources (outside of city working tiles, but inside cultural borders), wasting valuable city improving turns.

The second annoyance is the cottage/workshop switch, they build cottage, when it’s finished a workshop on same tile, when it’s finished back to a cottage and so on for an eternity.

Also an option "worker leaves all cottages would be nice", especially since automated workers build all kind of crap on top of mature towns.

Of course one does not have to use automated workers, but I sort of like using the option after my empire grows too big.

Just my 5 cents, guess there are more important issues to work on, but these is what I find really annoying (with the possible exception of the bad diplomacy system where AI asks you to join the same war every second turn, and you are like no dude, his huge and I got 3 cities and the war is fought on another continent on the other side of the globe, what are you expecting me to do, teleport there?).

Heh, steaming =)

EDIT: My spelling was horrible, had to correct some =)


Johan
 
Something should be done to improve the automated worker system.

The most annoying behavior is the "build fortress on top of resources inside cultural border, but outside of city limit" worker behavior. I find it quite useless; why not simply take advantage of the resource. The biggest problem is that this action is prioritized above improving ordinary cities and their resources.

This behavior can be seen very clearly in the scenario "earth 1862" (by Lokolus) if you play as Russians. The workers when automated will build road + fortress to tons of resources (outside of city working tiles, but inside cultural borders), wasting valuable city improving turns.
Hm i explicitly set workers to 'network' automate so i get additional resources i might miss connection so i have something to trade with my neighbors / more happiness.

The second annoyance is the cottage/workshop switch, they build cottage, when it’s finished a workshop on same tile, when it’s finished back to a cottage and so on for an eternity.

Also an option "worker leaves all cottages would be nice", especially since automated workers build all kind of crap on top of mature towns.
which was the last version of BBAI you have played ?
I think it has been found here Root of all AI improvment cycling evil? and been corrected.


Of course one does not have to use automated workers, but I sort of like using the option after my empire grows too big.

Just my 5 cents, guess there are more important issues to work on, but these is what I find really annoying (with the possible exception of the bad diplomacy system where AI asks you to join the same war every second turn, and you are like no dude, his huge and I got 3 cities and the war is fought on another continent on the other side of the globe, what are you expecting me to do, teleport there?).
I think Pep's added unit orders offer more commands for workers.


I answered with best of my knowledge which is quite limited, in case i missed something i hope someone else can help you.
 
The most annoying behavior is the "build fortress on top of resources inside cultural border, but outside of city limit" worker behavior. I find it quite useless; why not simply take advantage of the resource. The biggest problem is that this action is prioritized above improving ordinary cities and their resources.

If it is actually being prioritized over making improvements in a city's BFC on tiles that might be worked, then that should probably be looked at. But when you say "why not simply take advantage of the resource"- they ARE taking advantage of the resource. A resource with a fort on it is added to your trade network as though it had a mine/well/plantation/whatever on it.
 
Note that it's only true if you have the tech that would have allowed you to build the normal improvement on it. Sticking a Fort on Bananas before Calendar doesn't get you anything except well protected bananas, which is a virtue all its own. :D
 
Note that it's only true if you have the tech that would have allowed you to build the normal improvement on it. Sticking a Fort on Bananas before Calendar doesn't get you anything except well protected bananas, which is a virtue all its own. :D

Yes, but sticking a fort on, say Oil, before you can build a well, gets you access to Oil IMMEDIATELY as you complet research on the tech that allows you to build a well.
 
Even for bananas, when you get calendar the bananas instantly become usable.

You can then go and replace the fort with a plantation, and get both the banana resource and the production bonus.
 
1) AI was suiciding catapults against my siege stack which was waiting outside a city for trebs to arrive, with no intent to follow up with an attack.

2) AI sent a pikeman and a longbowman to attack a 6-7 unit stack of macemen and crossbows
 
Hello,

Maybe this is listed already. I haven't read all the pages to see. And I have no idea how accessible it might be to adjust. But, here's what I was just seeing.

Playing Rise of Mankind, with the unofficial 2.8 changes modmod included. I'm playing with the start as minor civs turned on, so I'm at war with all of my neighbors to begin with. One of them, Pacal (random personalities turned on) is aggressive in attacking me. He's already sent over one stack of about 4 of his str 4 Holken, and now he's sending over another stack of 8-10. A few support units like an archer or two with each stack as well.

OK, that's not bad. Rush an attack with spears and archers to see if my defenses are up.

But, I'd defeated the first stack, barely, and had been building my own defenses. After a bit of a campaign, we end up outside of my settlement of St. Petersberg. I'm in my city, behind city walls (30% def in ROM).

First problem, the AI attacks. I wouldn't have if I was in control. I've got 4 spear, 4 archers, 1 warrior inside a city behind city walls. One of the spears is fully fortified, the others aren't, having just retreated to the city. I'm playing with archer bombardment on, and my archers hit 3 out of 4, so 3 of his Holken are at str 3.6 or so. He's attacking at low odds, and we both have the same number of units so its not really a case where you might take so suicide attacks to whittle down a fewer number of defenders.

But, even given that, here's what to me is the bigger problem. What you might call the Somme effect. The AI keeps on attacking with its full stack.

Especially when attacking a city, there's a point where I'll break off an attack. And the point where that is almost certainly true is when I have fewer unused attackers left than the enemy has defenders. This means I can not take the city this turn. No way. And, since units in a friendly city recover HPs fast, there often is no reason to keep attacking. I'd only do it if I'm getting kills on units. If I see that I've got an 80% success attack, then sure, you take out that unit. But, what you don't do is to keep sending low odds attacks against units in a city.

That's what the AI did. Just like the generals at the Somme, he kept sending wave after wave at my defenders behind my city walls. In the end, he won one attack, so he had one wounded Holken sitting alone next to my city. In my city, about 3/4s of my units were at 50% str, but I still had two almost undamaged spearmen to go kill off that surviving Holken.

Like I said, I don't know enough about the AI structure to know if this is addressable. But, if you can convince the AI not to throw away stacks in hopeless attacks, that would keep the balance of power more even.

What I was scared that the AI would do would be to take that stack and bypass my city and go marauding through my countryside pillaging the women and raping the cattle. My economy was already struggling as I had a large army to fight these wars. The stack was too large for me to attack, especially if it moved off this grassland square and into the forests and hills that were my interior. That would have been a real challenge for me to deal with.

In naval strategy, there's a concept called 'fleet in being'. Just having a powerful fleet is an advantage, and the one thing you don't want to do is to lose it. Seems like the same concept could apply to land stacks. There's an advantage to having one on the board. And its better to keep it alive than to throw it away in hopeless attacks on a fortified city.

Well, at least we know one thing. The British were commanded by the AI in World War I. :)
 
The Meatgrinder:
* Move an army to a city that has no defensive bonuses.
* Beat down the defences. Use siege to reduce units to wimps.
* Kill all but one unit.
* Wait. The AI will proceed to reinforce the city.
* Repeat until you have killed most of the AIs floating defenders.
* Take the city, and advance on harder to take out cities, with a massively depleted AI.

The War of Distraction:
The AI is extremely reluctant to go to war when it is currently at war. You can almost set a clock for when the AI will go to war next after they finish an existing war.

So set up wars of distraction. Even if they don't mean anything, they will keep the AI from bothering you.

I need to look to see what we have to make sure this isn't a serious problem.

Fleet in Pieces:
I was fighting Tokinawa. He sent his fleet at me (presumably loaded) in multiple waves, instead of one huge wave. He had troops at home, and a far larger fleet -- but instead it came at me one piece at a time.

Had the entire fleet been used, I wouldn't have been able to stop the invasion. He had lots more ships than I did, and I ended up having to draft (well, whip) enough to stop even the fleet he did use.

Attacking someone who is prepping for Total War:
The AI seems to act differently if attacked or if you attack them. When someone is PREP_TOTAL, and you go to war before it occurs, they switch to "I was attacked" mode. Is there a way for it to switch to TOTAL in that case? Or does it really not matter?

Let's Attack the guy with Riflery
Effective naval invasions work much better against someone you have a technological edge over, instead of someone who has a technological edge over you.

Your transports and ships are less likely to be taken out (as the water-born tech edge is huge), and the relative strength of your landing force is much more concentrated if you have a technological edge than if you do not.

While most intercontinental invasions ended up failing, the ones that got more than a toe hold always where down a technological gradient. And there where lots that where attempted up the gradient.

I suspect this might be a stronger effect than the mere "incorrect assessment of power" feature in Civ4.

Legacy Fleets:
The AI ends up with a ridiculous fleet, unless it engages in a naval war with another AI, because of the free upgrades the AI gets (all the way to cruisers). The steepness of fleet unit production costs is higher than non-fleet unit production costs. This is not really a BetterAI problem, but I was thinking about it. Combustion leads to a massive cash sink (as the AI upgrades their fleet) and a much greater naval power edge for the AI instead of a human.

Corporate Saving:
Saving up great people for founding corporations is a ridiculously effective strategy.

Missing Industrial Revolution:
Whenever I hit railroads/factories, my empires production output proceeds to spike upwards sharply. The AI seems fails to pull this off -- at least, not nearly as fast (I'm currently working through a game, maybe the AI will start spiking before I finish it). This is about the only reason why I can compete in the modern era against the AIs huge cheaply upgraded army (that, and the fact that armor is off the upgrade path, so I can field more tanks than the AI).
 
The Meatgrinder:
* Move an army to a city that has no defensive bonuses.
* Beat down the defences. Use siege to reduce units to wimps.
* Kill all but one unit.
* Wait. The AI will proceed to reinforce the city.
* Repeat until you have killed most of the AIs floating defenders.
* Take the city, and advance on harder to take out cities, with a massively depleted AI.

Good one, definitely an exploit of the poor AI. The AI never gives up on a city right now, which has its pluses and minuses ... I guess the AI should decide not to move any more troops into a city if the defensive power of whatever it has left in the city + defensive power of all of its floating defenders are significantly less than the offensive power of enemy troops around the city. Figuring out whether enough defenses can get there this turn is another matter though, but it should be possible to figure that out with a check at the beginning of the turn for cities to not defend.

The War of Distraction:
The AI is extremely reluctant to go to war when it is currently at war. You can almost set a clock for when the AI will go to war next after they finish an existing war.

So set up wars of distraction. Even if they don't mean anything, they will keep the AI from bothering you.

I need to look to see what we have to make sure this isn't a serious problem.

For sure. The AI needs a sense of when a war is cold versus hot, which it just doesn't have right now. We're getting closer, the AI now better understands relative power in war and when it has its enemy totally outgunned, so I intend to make it willing to open a second front in this case (perhaps only of its own choosing ...).

The victory strategy logic I'm working on will also help here.

Fleet in Pieces:
I was fighting Tokinawa. He sent his fleet at me (presumably loaded) in multiple waves, instead of one huge wave. He had troops at home, and a far larger fleet -- but instead it came at me one piece at a time.

Had the entire fleet been used, I wouldn't have been able to stop the invasion. He had lots more ships than I did, and I ended up having to draft (well, whip) enough to stop even the fleet he did use.

Yeah, naval AI is an ongoing process ... at this point it's been mostly rewritten, but there's still more to do. Did they have transports and escorts together? Some small transport groups (alone even) trying to catch up to a bigger force? Could you sink them because of a tech edge or just better tactics?

If you have a save from before the invasion, I'd like to take a look.

Attacking someone who is prepping for Total War:
The AI seems to act differently if attacked or if you attack them. When someone is PREP_TOTAL, and you go to war before it occurs, they switch to "I was attacked" mode. Is there a way for it to switch to TOTAL in that case? Or does it really not matter?

The differences stem from what area strategy the AI uses. When first attacked it automatically uses a defensive strategy for the first few turns, which seems rational. Once its warplan switches from ATTACKED_RECENT to ATTACKED, then it will consider going on the offensive more. Even when on the defensive the AI does send out attack stacks if it has them ready, is perhaps the root of what you're seeing the fact that the AI isn't really ready for the war and doesn't have enough attack troops in position yet?

Let's Attack the guy with Riflery
Effective naval invasions work much better against someone you have a technological edge over, instead of someone who has a technological edge over you.

Your transports and ships are less likely to be taken out (as the water-born tech edge is huge), and the relative strength of your landing force is much more concentrated if you have a technological edge than if you do not.

While most intercontinental invasions ended up failing, the ones that got more than a toe hold always where down a technological gradient. And there where lots that where attempted up the gradient.

I suspect this might be a stronger effect than the mere "incorrect assessment of power" feature in Civ4.

Yes, this is certainly true. There are a couple of factors, including high enemy naval power and the time delay of reinforcements which should make the AI more hesitant to launch naval wars that it currently is under many circumstances.

Legacy Fleets:
The AI ends up with a ridiculous fleet, unless it engages in a naval war with another AI, because of the free upgrades the AI gets (all the way to cruisers). The steepness of fleet unit production costs is higher than non-fleet unit production costs. This is not really a BetterAI problem, but I was thinking about it. Combustion leads to a massive cash sink (as the AI upgrades their fleet) and a much greater naval power edge for the AI instead of a human.

The AI also doesn't have a good idea of what makes a big enough fleet. In the right circumstances it will build enough transports to move its entire attack force at once, then all other naval quantities basically are based off of the number of transports.

A lot of transports are necessary if you're trying a naval invasion of anything but a weak civ. But when is enough enough?

Corporate Saving:
Saving up great people for founding corporations is a ridiculously effective strategy.

The AI's handling of corporations isn't very smart. Corporations right now are kind of a late game boost to the human player.

Missing Industrial Revolution:
Whenever I hit railroads/factories, my empires production output proceeds to spike upwards sharply. The AI seems fails to pull this off -- at least, not nearly as fast (I'm currently working through a game, maybe the AI will start spiking before I finish it). This is about the only reason why I can compete in the modern era against the AIs huge cheaply upgraded army (that, and the fact that armor is off the upgrade path, so I can field more tanks than the AI).

This one is huge ... when factories become available, they need to become the priority. The AI does okay now if it's at peace and will have many cities building factories, but when at war it is easily distracted by more immediate needs.

When at war, it's a tough choice ... you need to produce enough new troops to sustain the war, plus enough factories so you remain competitive with the other players. Diplomacy needs to play a role here too, if the AI needs to upgrade its infrastructure it should hold off on wars and try to get out of wars which are stalemated.
 
Yeah, naval AI is an ongoing process ... at this point it's been mostly rewritten, but there's still more to do. Did they have transports and escorts together? Some small transport groups (alone even) trying to catch up to a bigger force? Could you sink them because of a tech edge or just better tactics?
I had a tech edge -- Frigates and Ship-o-Line and (unused) Ironclad vs Galleons and Caravals.

But he had about 50 ships (no, I'm not kidding), and I had 10 after mass-whipping a fleet to deal with his ships, some of which didn't arrive for the first wave of enemy ships.
If you have a save from before the invasion, I'd like to take a look.
I can check.
Yes, this is certainly true. There are a couple of factors, including high enemy naval power and the time delay of reinforcements which should make the AI more hesitant to launch naval wars that it currently is under many circumstances.
The AI has a naval power vs land power breakdown? Cheater. :)
This one is huge ... when factories become available, they need to become the priority. The AI does okay now if it's at peace and will have many cities building factories, but when at war it is easily distracted by more immediate needs.

When at war, it's a tough choice ... you need to produce enough new troops to sustain the war, plus enough factories so you remain competitive with the other players. Diplomacy needs to play a role here too, if the AI needs to upgrade its infrastructure it should hold off on wars and try to get out of wars which are stalemated.
Factories are actually secondary. In an experiment, I went for assembly line before railroads -- railroads are needed to 'efficiently' go down the assembly line route it turns out.

The ROI on a factory is (shields to make a factory) vs (bonus shields from factory) -- plus the expected power boost as a second pass.

Boosting your production via worker railroading gives you a boatload more production, which makes the ROI on the factory better and reduces the factory lag-time, and makes them 'worth' it. And the workers can concentrate on a few cities, getting them to the point where it is worth building a factory, then move on to the next one (and the city that you upgraded proceeds to build the factory).

---

Hmm. Of interest is that by this era, the AI tends to have more windmills than mines? And it tends to have cut down its forests. Meanwhile, I tend to have a bunch of legacy forests, and some mines (or be willing to switch to mines).

Can the AI understand the double-step from windmill to mine+railroad?

Windmill on a grass hill: 2 F 1 H 2 $.
Windmill on a plains hill: 1 F 2 H 2 $.
RR-Mine on a grass hill: 1 F 4 H. (lumberyards on hills are identical?)
RR-Mine on a plains hill: 0 F 5 H. (lumberyards on hills are identical?)

I could see the AI being ... reluctant to replace the windmill with a mine before the railroad, and consider the railroad to be useless on the windmill?

Of interest (well to me) is the "food neutral" combos. Some more territory at this level: (ignoring the +1 $ from water, as that is pretty universal)
Farm Grass: 4 F.
Farm Planes: 3 F 1 H.
L-RR Plains: 1 F 4 H.
L-RR Grass: 2 F 3 H.

Waterwheel Grass: 2 F 2 H 1 $
Waterwheel Planes: 1 F 3 H 1 $
Workshop Grass: 1 F 3 H.
Workshop Plains: 0 F 4 H.

3 L-RR Grass: 6 F 9 H. (3 H/Pop)
1 FG 2 L-RR P (or GMine): 6 F 8 H. (2.67 H/Pop)
1 FP 1 L-RR P (or GMine): 4 F 5 H. (2.5 H/Pop)
1 FG 1 L-M PH: 4 F 5 H (2.5 H/Pop)
1 FG 2 WG: 6 F 6 H (or 2 H/Pop)
1 FG 1 WP: 4 F 4 H (or 2 H/Pop)
1 FP 1 WG: 4 F 4 H (or 2 H/Pop)
2 FP 1 WP: 6 F 6 H (or 2 H/Pop)
WWG: 2 F 2 H (or 2 H/Pop)

Which illustrates the wooded planes giving the most insane production output (barring state property). Close is a mixture of flat and hilly grassland. And relying on workshops sucks.

This is getting heavily tangental. I was just wanting to poke around and figure out what could be making the AI weak at hammer output...

...

Oh, and mining inc does make the industrial revolution happen so much faster.

...

Does the AI know to found as many corp. headquarters as possible in the city with the greatest cash multiplier?
 
Back
Top Bottom