• We have updated our Community Code of Conduct. Please read through the new rules for the forum that are an integral part of Paradox Interactive’s User Agreement.

Andrei Gijgorev

Civilian
3 Badges
May 23, 2007
686
65
  • Arsenal of Democracy
  • Darkest Hour
  • For The Glory
AI controlled countries don't move their domestic policy sliders, which is stupid, so I'm going to fix it. With events. And flags. Lots of flags.

I've figured out the technical aspects, but I'm not quite sure exactly what the AI should actually do. Ideally, it would emulate a human player, but unfortunately I don't really know how other people actually play the game. So hopefully I can gather some feedback here.

In my opinion, because of the linear bonuses/maluses, it's generally preferable to have the slider at either extreme rather than in the middle. This is especially true for the land/naval slider because you want either the army morale bonus or the navy morale bonus, and if the slider is in the middle then you get neither. The quality/quantity slider is a little peculiar since at the two lowest positions there's an additional malus to the fire value of default leaders, so the third-lowest position is another possible sweet spot.

Here's my rough draft for the AI logic behind the direction and priority of slider moves:
  • Plutocracy vs Aristocracy
    All countries should move towards plutocracy. However, before certain infra/trade/land techs are researched this is a very low-priority slider, so effectively it won't get moved.

  • Decentralization vs Centralization
    Countries should generally move towards centralizaion. The smaller the country, the lower the priority.

  • Narrow-minded vs Innovative
    Certain religions (e.g. counterreformed catholics) should move towards narrow-minded, all others should move towards the closest extreme. This is a low-priority slider, with increased priority if the slider is already close to an extreme. For colonial nations moving towards innovativeness this slider is very low-priority.

  • Free Trade vs Mercantilism
    Non-colonizing countries with trade centers should move towards mercantilism. A few select countries like the Netherlands should move towards free trade. Other countries probably shouldn't bother with this slider.

  • Defensive Doctrine vs Offensive Doctrine
    Not really sure about this slider. Countries should probably simply move towards the closest extreme. Low priority for countries with the slider in the middle, high priority for countries moving towards offensive, quality, and land? And a higher priority if currently at war.

  • Naval vs Land
    All countries should move towards land, with the exception of major historical maritime trading powers (Portugal, England, Netherlands, Venice). For countries with the slider already in the correct half, this should be a high-priority slider, and even more so if currently at war.

  • Quantity vs Quality
    Countries should move towards the closest extreme. However, countries with the slider at the third-lowest position should not move it any further. Moving this slider from the third-highest to the second-highest position has high priority because of the leader bonus.

  • Free Subjects vs Serfdom
    Plutocratic countries should move this slider towards free subjects; other countries should move it towards the closest extreme. Higher priority for smaller countries moving towards free subjects.

I'd like to discuss this. Having to make changes later would be annoying, so speak now or forever remain silent.
 
  • 1
Reactions:
There is no absolute perfect way to set the domestic sliders.

e.g. aristocracy vs. plutocracy
Sure as a land power I always go for full aristo. High diplomacy to reduce BB, cheaper cavalry rules. But for a nation that does not plan to expand much and instead focuses on naval power and trade (perhaps England or Netherlands) Plutocraty might be good.

There had been a vivid discussion about each and every of those sliders already back in the EU2 days

https://forum.paradoxplaza.com/foru...stic-policies-slider-discussions-links.24625/
 
Very interesting, Andrei! Challenge accepted, indeed...


Here are my opinions. I'm not a seasoned elite player who can conquer the world with Xhosa (or with anyone), but my two cents:


In my opinion, because of the linear bonuses/maluses, it's generally preferable to have the slider at either extreme rather than in the middle. This is especially true for the land/naval slider because you want either the army morale bonus or the navy morale bonus, and if the slider is in the middle then you get neither. The quality/quantity slider is a little peculiar since at the two lowest positions there's an additional malus to the fire value of default leaders, so the third-lowest position is another possible sweet spot.

That's true, at least most of the time. But sometimes you really don't feel like taking a slider's penalty. Or you wait until a certain big tech level gives you enough wealth to justify moving it.


Example 1: My second ERE game included me going Innovative at a certain point, which I did by going full serfdom first. This allowed me to advance to the needed tech levels that boosted my wealth, and so I started using events to go Narrowminded once my need for colonists and stability became more important than my teching.

Example 2: My Genoa game. I'm in the late 1400s and I'm in the middle between Aristocratic and Plutocratic because I don't feel like taking any penalties, but I'm preparing myself to move to Aristo in order to increase my diplomacy and get rid of badboy points and make Europe stop hating me. Also I had to hold going full naval because I fought a few wars in the eastern mediterranean and didn't feel the more expensive solders were worth it, but I'm going full naval soon.

Plutocracy vs Aristocracy
All countries should move towards plutocracy. However, before certain infra/trade/land techs are researched this is a very low-priority slider, so effectively it won't get moved.

Are you going historical or game-logic?
Historically, Europe at this time went slowly more Plutocratic and Centralizing.
Of course, a lot of events move towards aristocratic, perhaps you desire to counter-act those.

In game-logic, Aristocracy is best for most countries - you get good diplo and cheaper cavalry in exchange for more expensive galleys, productivity and trade penalties. The penalties can be negated with enough research and land, respectively. Aristo is good for big expansionistic land empires like France, Poland, Mamluks, Ottomans, Muscowy/Russia, etc.

Plutocracy is better for small countries more interested in trading and at best conquering lands from their cultures/religions - Italian city-states, Ragusa, the Swiss, some german states, Oman, etc. I can also see the appeal for a middle-game power focusing on infantry and naval power rather than cavalry.

Some countries like England or Portugal could easily go either way.


  • Decentralization vs Centralization
    Countries should generally move towards centralizaion. The smaller the country, the lower the priority.

Agreed. Centralization is pretty much a good slider, althrough Decentralization works for players engaging in World Conquest.

Narrow-minded vs Innovative
Certain religions (e.g. counterreformed catholics) should move towards narrow-minded, all others should move towards the closest extreme. This is a low-priority slider, with increased priority if the slider is already close to an extreme. For colonial nations moving towards innovativeness this slider is very low-priority.

Agreed.

Personally I consider innovative a weak slider. Now if Westernisation was possible...

Free Trade vs Mercantilism
Non-colonizing countries with trade centers should move towards mercantilism. A few select countries like the Netherlands should move towards free trade. Other countries probably shouldn't bother with this slider.

One thing I noticed in my ERE and Genoa games: Mercantilism is best when you are poor, Free Trade is good when you are rich. Early on, you need stickier and cheaper merchants and you will often have idle ones. Later on, if you have enough money you will need the extra merchants to dominate trade in most of Europe. CoT number might be a useful flag, because having more CoTs (and Monopolies on those) mean more merchants, therefore less need for Free Trade.

Also, Mercantilism makes your colonies and conquests use your original CoT instead of a local one, right? Is this a good or bad thing?

Defensive Doctrine vs Offensive Doctrine
Not really sure about this slider. Countries should probably simply move towards the closest extreme. Low priority for countries with the slider in the middle, high priority for countries moving towards offensive, quality, and land? And a higher priority if currently at war.

Does anybody here play Defensive? Wars in EU2 are decided by battles, once you reduce the enemy army to zero you can carpet siege to your hearts' content and murder any would-be armies the enemy tries to recruit. The only problem is if the enemy is big enough that their lands can't all be sieged or covered in a few months, then they can make another army capable of hitting back in a few months.

Yup, Offensive + Quality + Land have big synergy.

This might be a mechanical problem because EU2 really doesn't support the type of defensive attrition warfare seen in later versions of EU3, where you can scorch the land. Magna Mundi mod is unique in that aspect because forts last longer, war exaustion is a bigger issue and attrition hits harder. I once read a MMU AAR on the RPGCodex where a guy playing Mongols obliterated immense Ming armies with a combination of scorched land warfare and hit and run cavalry attacks and then (re)conquered China. If that was a bigger issue, a siege-devoted force would be more important.

(also in MMU some places were simply better fortified than others due to natural reasons)


Naval vs Land
All countries should move towards land, with the exception of major historical maritime trading powers (Portugal, England, Netherlands, Venice). For countries with the slider already in the correct half, this should be a high-priority slider, and even more so if currently at war.

Agreed.
There's the question of Castille, which seems to have been on-and-off a naval or land power.


Quantity vs Quality
Countries should move towards the closest extreme. However, countries with the slider at the third-lowest position should not move it any further. Moving this slider from the third-highest to the second-highest position has high priority because of the leader bonus.

Agreed.
Maybe its just me, but Quantity armies are better earlier and if the country is smaller and poorer, while Quality armies are more expensive, so better for bigger powers capable of paying for expensive top-rate armies. Another use for quality is for colonial powers with coin to spare using their superior tech and fire phase superiority to fusillade inferior tech locals and so spare on manpower and land limit.


  • Free Subjects vs Serfdom
    Plutocratic countries should move this slider towards free subjects; other countries should move it towards the closest extreme. Higher priority for smaller countries moving towards free subjects.

Bigger countries go for Serfdom, smaller countries towards Free Subjects?
 
I would say the defensive/offensive slider is heavily biased towards offensive due to the morale effect. 0.4 difference from max def to max off which is almost as pronounced as the 0.5 morale difference between max naval and max land. Back in the days of EU2 MP everyone would move that slider to max offensive asap. Prolonged sieges are generally not really a problem either and can actually be beneficial for the loot (especially with minting on synchronized loot).

I'll read the rest later.
 
There is no absolute perfect way to set the domestic sliders.

e.g. aristocracy vs. plutocracy
Sure as a land power I always go for full aristo. High diplomacy to reduce BB, cheaper cavalry rules. But for a nation that does not plan to expand much and instead focuses on naval power and trade (perhaps England or Netherlands) Plutocraty might be good.

There had been a vivid discussion about each and every of those sliders already back in the EU2 days

https://forum.paradoxplaza.com/foru...stic-policies-slider-discussions-links.24625/
That's a pretty useful compilation of threads. Definitely going to read those.

I'm aware that there's no "perfect" way to set the domestic sliders. Moreover, as Slaughter has also pointed out, domestic sliders are part of long-term (i.e. highly abstracted) strategy, and of course the AI isn't really capable of such abstraction. So my goal isn't to make the AI make the best possible decisions in all cases. Rather, my goal is to make the AI make decisions that are consistently better than not moving any sliders at all.

Are you going historical or game-logic?
Ideally a bit of both. On one hand I'd like the AI to make decisions that will actually benefit it, but on the other hand I don't want Russia running around with max quality armies. Hence why I'm proposing for the AI to simply move to the closest extreme in many cases.

The problem with historicity is also that in FTG (as in many other games) concepts like "aristrocracy" are just meaningless words with some stat changes attached to them. So the farther those stat changes are from what the actual concepts resemble in real life, the less I feel constricted by history.

I see plutocracy and centralization as closely related, since centralization efforts were historically opposed mainly by the nobility. In game terms, aristocracy's diplomacy bonus doesn't seem like an important bonus for the AI. In the early game, random events will move AI sliders towards aristocracy by default, but later on progressive centralized countries should want to move to plutocracy.

Also, Mercantilism makes your colonies and conquests use your original CoT instead of a local one, right? Is this a good or bad thing?
Never heard of that rule. Are you sure?

Does anybody here play Defensive? Wars in EU2 are decided by battles, once you reduce the enemy army to zero you can carpet siege to your hearts' content and murder any would-be armies the enemy tries to recruit. The only problem is if the enemy is big enough that their lands can't all be sieged or covered in a few months, then they can make another army capable of hitting back in a few months.
I would say the defensive/offensive slider is heavily biased towards offensive due to the morale effect. 0.4 difference from max def to max off which is almost as pronounced as the 0.5 morale difference between max naval and max land. Back in the days of EU2 MP everyone would move that slider to max offensive asap. Prolonged sieges are generally not really a problem either and can actually be beneficial for the loot (especially with minting on synchronized loot).
Those are good points; maybe everyone should simply move towards offensive. I know I always do...

There's the question of Castille, which seems to have been on-and-off a naval or land power.
I'm leaning towards Spain being a land power for two reasons. One, the Habsburgs need to be a counterweight to France, and two, Spain historically tended to lose conflicts with actual naval powers such as England and the Netherlands.

Maybe its just me, but Quantity armies are better earlier and if the country is smaller and poorer, while Quality armies are more expensive, so better for bigger powers capable of paying for expensive top-rate armies. Another use for quality is for colonial powers with coin to spare using their superior tech and fire phase superiority to fusillade inferior tech locals and so spare on manpower and land limit.
I guess it makes sense for naval powers to move towards quality as well.

Bigger countries go for Serfdom, smaller countries towards Free Subjects?
No, just if a small country is moving towards free subjects, then this slider should have a higher priority than for a small country moving towards serfdom, or for a larger country moving towards either extreme.
 
It would be awesome if domestic policies could be linked to each other. That way we could also balance things out by tying stronger policies with weaker ones.

For instance, plutocracy would relate to centralization.
Offensive with aristocracy (so a player wanting to go plutocratic would have to sacrifice some of his military prowess).
mercantilism with centralization
serfdom with aristocracy
land with aristocracy (tellurocratic empires were generally aristocratic (Russia, Prussia, pre-Rev France) as opposed to the plutocratic thalassocracies (England, NL))
 
Here's an alpha version for FTG 1.3 Vanilla. To enable AI slider moves, put "ai_sliders.txt" in \db\events\ and add this line to events.txt:
Code:
event = "db\events\ai_sliders.txt"

Notes:
  • You don't need to start a new game, but if you want to continue from a savegame you will need to add the line above to your savegame.
  • AI countries will only move sliders if at peace and stability >= 1, or if at war and stability >= 2. AI countries will stop moving sliders in 1920.
  • You must select "normal" AI event choices (set_ai_event_choices = 0). There's a weird bug that causes events not to trigger if "historical" AI event choices are enabled (set_ai_event_choices = 1). Nothing I can do about that, unfortunately.
  • If you experience performance issues, try setting "offset = 10" in line 127 to "offset = 30" or even higher, and please post your specs here.
  • If you have played 250 years or more with AI slider moves enabled, please upload a savegame here.
  • This minimod will be included in Watkabaoifbaaaaaa 1.1.
And please report any bugs you encounter.
 

Attachments

  • ai_sliders.txt
    45,7 KB · Views: 287
interessing
 
What is the sense of the events like the "move trigger" event to have a line "date = { year = 9999 }" when it only fires if triggered by another event?
Couldn’t the date line be deleted without any consequences for triggered only events?

Edit: Why start those events at 1415 earliest and end in 1920 when WATKABAOI A+ has a scenario that starts 1337 in the HYW but no scenario that lasts until 1920?
 
Last edited:
What is the sense of the events like the "move trigger" event to have a line "date = { year = 9999 }" when it only fires if triggered by another event?
Couldn’t the date line be deleted without any consequences for triggered only events?
It's a workaround for a bug that causes persistent events without triggers to be repeatedly fired once they have been triggered by another event.

Edit: Why start those events at 1415 earliest and end in 1920 when WATKABAOI A+ has a scenario that starts 1337 in the HYW but no scenario that lasts until 1920?
Because this is an alpha version to be used with FTG 1.3 Vanilla. The version that will be incorporated in Watkabaoifbaaaaaa will start earlier.
 
It's a workaround for a bug that causes persistent events without triggers to be repeatedly fired once they have been triggered by another event.

Ah, I did not know such a bug existed.

Because this is an alpha version to be used with FTG 1.3 Vanilla. The version that will be incorporated in Watkabaoifbaaaaaa will start earlier.

Do I understand the events right that AI countries could potentially change ALL sliders every 10 years as opposed to the player who can change 1 slider every 10 years?
 
No, the choices in event 90000031 are mutually exclusive. You can check the AI flags in the savegame to see which slider has been moved last; it should look something like this:
Code:
move_aristocracy = no
move_centralization = no
move_innovative = no
move_land = yes
move_mercantilism = no
move_offensive = no
move_quality = no
move_serfdom = no
If there were several flags enabled then that would be a bug.

BTW the AI doesn't have a minimum period of 120 months between slider moves and instead is constricted to moving one slider per 5 year period, but not in successive 5 year periods. So technically the interval between slider moves could be as short as 5 years, but it would still be 10 years on average. You can check the AI flags in the savegame to see when sliders have been moved:
Code:
1415_slider = yes
1420_slider = no
1425_slider = no
1435_slider = yes
1440_slider = no
1445_slider = yes
1450_slider = no
1455_slider = yes
1460_slider = no
1465_slider = yes
1470_slider = no
1475_slider = no
1485_slider = yes
1490_slider = no
1495_slider = no
1500_slider = yes
1505_slider = no
1510_slider = yes
1515_slider = no
1520_slider = yes
1525_slider = no
1530_slider = yes
If there are several disabled flags in a row this usually means the country had too low stability in that 5 year period or was constantly at war.