Stellaris Dev Diary #172 - Reworking the AI

Bonjour everyone, it’s the French Paradox speaking! For those who don’t know me, I’ve joined the Stellaris team this December after a year and a half as a programmer on Europa Universalis IV.

Today, we are gonna talk about AI.

pasted image 0.png

A good introduction for those new to the field

Fifty Shades of AI
There are several AI modules in Stellaris. For historical reasons we call them “ministers” as each one is supposed to handle a specific role in an AI empire.

There are 3 broad kinds:
  • The AI foreign minister handles diplomacy, federations, galactic community, peace deals and the like
  • The AI interior minister is in charge of the economy. He keeps budgets and order constructions, both civil and military.
  • The AI military minister is in command of all troops and military fleets, and also responsible for laying out strategic plans when at war.
For each of those ministries there are different “ministers” there are several options that can be selected for every empire in the game. All of those have generic one which behaves more or less like we’d expect a player to and is used for most AI empires. Then we have a bunch of specialized ones for special tags such as space monsters, fallen empires, crisis, marauders and the like.

As almost everything in our games, AI is configurable in script for our modders, although I’m not exactly sure what would happen if you assigned a space monster military AI to the caravaneers ;)

In guise of a welcoming gift when I joined the team, I was tasked with reworking the military one...

The Military AI
To give you a little bit of background, there were several generations of military AIs in Stellaris. The generic one (used by most “classic” empires) was redone by the great @sidestep last year, while the more specialized ones (crisis, space monsters) have kept close to what they were on release. In the midst of the sad and dark swedish winter, I managed to bring some improvements that I’ll showcase today.

First of all, I worked on visualization to help us debug how the AI “thinks”. Funny thing is, it already made it look “better” to audiences even if it didn’t actually change any behaviour. It’s actually something that’s been observed in video games: a good AI tells you what it does, which makes it look smarter. One of my favourite examples of that would be the enemies in FEAR.

So by typing 'debug_ai' in the console and observing an AI empire, you can see what it has in mind:

pasted image 0 (1).png

“I don't even see the code. All I see is blonde, brunette, redhead. Hey uh, you want a drink?”

As a simple analogy, imagine that the AI has a war minister that looks at the big picture and rates every potential target, a general staff who assign fleets to some of those objectives, and then admirals who try to lead those fleets on a tactical level to achieve those objectives.

The skulls on top of each system shows military objectives that the AI is considering (the war minister). Red ones are the ones they selected and committed some fleets to, while green ones are other options they haven’t retained for now. Finally for each individual fleet, in those task forces, you see what they are doing at present.

In our screenshot example, the AI decided that taking Tiralam was the most important objective with a score of 4500, and that they estimated that at least 11.2k fleet power was needed to accomplish this. They committed the Kilik Armada, the Jinki-Ki-Ti Armada and the the Grekki Armada to this. Since it makes little tactical sense to attack in a dispersed formation, the AI issued orders to regroup in Broon’s Singularity before proceeding on the attack (something we improved in this patch).

For convenience, the summary is also visible in the outliner:

pasted image 0 (2).png

As seen from the other side of that war

That change alone allowed us to see where the AI was a bit weak and also made evident a few bugs in the production AI that we promptly fixed. A funny one was that in some cases a fleet would end up assigned to two different fleet groups, nicely simulating two admirals fighting over command of a fleet and issuing contradictory orders every day.

Crisis AI
The next step was to rewrite the various crisis to use the generic AI, so that any effort spent on making better would benefit all. In patch 2.6 the specific AI of the Khan, the Prethoryn, the Unbidden and the Contingency will use the same AI as the “standard” empires, with a few twists to still retain their personality.

Without spoiling every secret, here’s a few ideas:
  • The Khan doesn’t really believe in defense and will try to beat the closest systems into submission
  • The Prethoryn will swarm in every direction they can
  • The Contingency will systematically try to stop the biggest threat to the galaxy, until nothing remains
  • The Unbidden will be harder to predict, but there’s reason behind their alien way of acting.
One of the biggest challenges we faced was assigning fleets to objectives. Matching X fleets with Y out of Z objectives is not an easy task. Do we try to accomplish as many objectives as we can at the risk of spreading too thin or accomplishing nothing of value? Should we instead focus on the most valuable target and possibly end up in a big fight that we could have avoided? How often should we reconsider our options?

The current version solves this by putting a fleet power value on every target, then grabbing fleets by order of priority until it either has enough to accomplish the objective, or go over the next one. This approach showed its limits when we plugged the crisis AI into it, as it relies a lot on the size of available fleets (it doesn’t know how to split them, it can only merge them).

Teaching the AI how to split fleets proved quite interesting:

pasted image 0 (3).png

What shall we do with this knowledge?

It took several tries to find a good balance, as the AI tended to split too much (most objectives don’t call for that much fleet power, unless you’re fighting your enemy main fleet). In the end, after trying some complex strategies such as keeping statistics on accomplished objectives and deriving a good target number from that, a simpler approach turned out more efficient: put all the nation’s offensive fleet power into one stack, and then consider splitting in 2,3 or more depending on how confident the AI feels about its military power versus its foes.

Knowing some of you like to mod our AI, here’s some new defines you may want to play with once all that hits the shelves.

Code:
# Objective values
HORDE_INVASION_PLANNING_DEPTH = 5    # How far out does the Horde AI looks for invasion targets (in system hops)
SWARM_INVASION_PLANNING_DEPTH = 5    # How far out does the Swarm AI looks for invasion targets (in system hops)
SWARM_POP_TARGET_MULT = 1.0            # Extra target scoring for swarm (multiplied by number of edible pop on the planet)
CONTINGENCY_MEGASTRUCTURE_EXTRA_VALUE = 4    # How attractive are megastructures to the Contingency (added to the base value of 1)
UNBIDDEN_PORTAL_EXTRA_VALUE = 20            # How much does the Unbidden want to defend their portal (compared to base value of 1)
UNBIDDEN_BYPASSES_EXTRA_VALUE = 4            # How attractive are bypasses to the Unbidden (added to the base value of 1)
UNBIDDEN_RIVALS_EXTRA_VALUE = 10            # Extra target scoring for rival invaders (Aberrant and Vehement)
UNBIDDEN_TARGET_EXTRA_VALUE = 10            # Extra target scoring for randomly chosen nemesis
UNBIDDEN_PSIONIC_CONQUER_DESIRE = 20        # Extra weight added to psionic empires when rolling a nemesis (base 1 + number of owned bypasses)
UNBIDDEN_CHOSEN_ONE_CONQUER_DESIRE = 50        # Extra weight added to empire lead by the chosen one when rolling a nemesis (base 1 + number of owned bypasses)

# Fleet sizing
OFFENSE_VS_DEFENSE_STRATEGY_ALLOTMENT = 0.75 # How much of its fleet power should a country with 1.0 aggressiveness should try to commit to offensive missions
AVERAGE_FLEET_SIZE_FACTOR    = 0.05            # Ballpark estimate of the minimum size a fleet should be in relation to total fleet power
OWN_FLEET_POWER_FACTOR = 1.0                # How much does AI count its own fleet power when evaluating forces
ALLY_FLEET_POWER_FACTOR = 0.5                # How much does AI count ally fleet power when evaluating forces
ENEMY_FLEET_POWER_FACTOR = 1.0                # How much does AI count enemy fleet power when evaluating forces
FLEET_SUPERIORITY_FACTOR = 1.5                # How stronger should the AI be before it starts considering splitting fleets (fleet count = relative strength / this factor)
CRISIS_FLEET_SUPERIORITY_FACTOR = 1.0        # Same as previous but will be compared to the strongest foe in the universe

Most of those changes will be delivered in the patch coming alongside the Federations release (2.6.0), but not all. As you may imagine, changes to the military AI are quite impactful and we don’t want to release the changes without enough testing, so some of them will be delivered in the first support patch (2.6.1).

And with that, I shall leave you with @sidestep one last time.
 
Last edited by a moderator:
  • 2Like
Reactions:

Big Dead One

First Lieutenant
44 Badges
Oct 13, 2017
232
174
  • Surviving Mars
  • Stellaris: Nemesis
  • Stellaris: Lithoids
  • Surviving Mars: Digital Deluxe Edition
  • Crusader Kings II
  • Stellaris - Path to Destruction bundle
  • Stellaris: Distant Stars
  • Hearts of Iron IV: Death or Dishonor
  • Age of Wonders III
  • Europa Universalis IV: Cradle of Civilization
  • Hearts of Iron IV: Expansion Pass
  • Stellaris: Humanoids Species Pack
  • Stellaris: Apocalypse
  • Europa Universalis IV: Rule Britannia
  • Europa Universalis IV: Mandate of Heaven
  • Europa Universalis IV: Dharma
  • Europa Universalis IV: Golden Century
  • Hearts of Iron IV: Expansion Pass
  • Stellaris: Ancient Relics
  • Hearts of Iron IV: La Resistance
  • Stellaris: Federations
  • Battle for Bosporus
  • Europa Universalis 4: Emperor
  • Europa Universalis IV: Mare Nostrum
  • Europa Universalis IV
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: El Dorado
  • Europa Universalis IV: Common Sense
  • Europa Universalis IV: Cossacks
  • Stellaris: Leviathans Story Pack
  • Stellaris
  • Stellaris: Galaxy Edition
  • Hearts of Iron IV: Cadet
  • Hearts of Iron IV: Colonel
  • Hearts of Iron IV: Field Marshal
  • Europa Universalis IV: Rights of Man
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Synthetic Dawn
  • Stellaris: Megacorp
  • Europa Universalis IV: Pre-order
  • Europa Universalis IV: Res Publica
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Third Rome
  • Europa Universalis IV: Art of War
Excellent dev diary! This would hopefully give the AIs more fighting chance in the endgame.

Without spoiling every secret, here’s a few ideas:
  • The Khan doesn’t really believe in defense and will try to beat the closest systems into submission
  • The Prethoryn will swarm in every direction they can
  • The Contingency will systematically try to stop the biggest threat to the galaxy, until nothing remains
  • The Unbidden will be harder to predict, but there’s reason behind their alien way of acting.
I have a question: are there any improvements to the End of the Cycle and the Grey Tempest? They are also crises, and deserve some love too.
 

nichgid

Private
37 Badges
Jun 27, 2018
24
0
  • Europa Universalis III
  • Stellaris: Synthetic Dawn
  • Stellaris: Distant Stars
  • Stellaris - Path to Destruction bundle
  • Europa Universalis IV: Mandate of Heaven
  • Europa Universalis IV: Third Rome
  • Europa Universalis IV: Cradle of Civilization
  • Stellaris: Humanoids Species Pack
  • Stellaris: Apocalypse
  • Europa Universalis IV: Rule Britannia
  • Stellaris: Digital Anniversary Edition
  • Europa Universalis IV: Dharma
  • Stellaris: Megacorp
  • Europa Universalis IV: Golden Century
  • Stellaris: Ancient Relics
  • Stellaris: Lithoids
  • Stellaris: Federations
  • Europa Universalis 4: Emperor
  • Stellaris: Necroids
  • Europa Universalis IV: Rights of Man
  • Stellaris
  • Europa Universalis IV: Mare Nostrum
  • Europa Universalis IV: Cossacks
  • Europa Universalis IV: Common Sense
  • Europa Universalis IV: El Dorado
  • Europa Universalis III: Collection
  • Stellaris: Leviathans Story Pack
  • Victoria 2
  • Europa Universalis IV: Res Publica
  • Europa Universalis IV
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Art of War
  • Victoria 2: Heart of Darkness
  • Victoria 2: A House Divided
  • Heir to the Throne
  • Divine Wind
The Foreign Minister was not in the scope of this DD. It got some additions to be able to handle Galactic Community and the other new diplomatic features of course, but no major changes.

Yes, I foolishly copy-pasted from google drive without rehosting the pictures on Plaza. We're fixing it :oops:
No problem, I got an excuse to dust off the ol' IE :D
 

anro15

Recruit
12 Badges
Feb 21, 2019
9
12
  • Stellaris
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Leviathans Story Pack
  • Stellaris - Path to Destruction bundle
  • Stellaris: Synthetic Dawn
  • Stellaris: Apocalypse
  • Stellaris: Distant Stars
  • Stellaris: Megacorp
  • Stellaris: Ancient Relics
  • Stellaris: Lithoids
  • Stellaris: Federations
  • Stellaris: Necroids
A big thank you for the focus on this and taking the time to give a detailed explanation of it. While it appears easy for many to nit pick, I recognize the level of effort needed for this. Also appreciate the note about future developments once this goes live. This and the performance work all sound like a great direction to be headed in.
 

CassCD

Lunatic Pantsless Lady
74 Badges
Jan 19, 2011
1.247
2.449
  • Europa Universalis 4: Emperor
  • Stellaris: Necroids
  • Stellaris: Nemesis
  • Stellaris: Federations
  • Cities: Skylines
  • Europa Universalis IV
  • Victoria 2: A House Divided
  • Crusader Kings II
  • Age of Wonders III
  • Stellaris
  • Hearts of Iron IV: Death or Dishonor
  • Europa Universalis IV: Mandate of Heaven
  • Crusader Kings II: Monks and Mystics
  • Hearts of Iron IV: Together for Victory
  • Stellaris: Leviathans Story Pack
  • Stellaris: Digital Anniversary Edition
  • Europa Universalis IV: Rights of Man
  • Hearts of Iron IV: Colonel
  • Hearts of Iron IV: Cadet
  • Hearts of Iron IV Sign-up
  • Stellaris: Galaxy Edition
  • Crusader Kings III
  • Europa Universalis IV: Cradle of Civilization
  • Hearts of Iron IV: Expansion Pass
  • Stellaris: Humanoids Species Pack
  • Stellaris: Apocalypse
  • Europa Universalis IV: Rule Britannia
  • Cities: Skylines - Parklife
  • Stellaris: Distant Stars
  • Europa Universalis IV: Dharma
  • Crusader Kings II: Holy Fury
  • Europa Universalis IV: Golden Century
  • Imperator: Rome Deluxe Edition
  • Stellaris: Ancient Relics
  • Stellaris: Lithoids
  • Crusader Kings II: Conclave
  • Europa Universalis III Complete
  • Europa Universalis III Complete
  • Victoria 2
  • 500k Club
  • Europa Universalis IV: El Dorado
  • Europa Universalis IV: Common Sense
  • Crusader Kings II: Way of Life
  • Crusader Kings II: Horse Lords
  • Europa Universalis IV: Cossacks
  • Europa Universalis III Complete
  • Heir to the Throne
  • Divine Wind
  • Europa Universalis IV: Art of War
  • Europa Universalis III
You're letting the AI PLAN!? Are you insane!? If you allow this to happen, there's no telling what will happen. What if the Stellaris AI starts planning to escape my computer into the internet? We need to kill it here and now before this thing becomes a threat to all of humanity,
 

sidestep

Blue Flame Provider
44 Badges
Feb 13, 2018
106
0
  • Victoria 2: A House Divided
  • Sengoku
  • Europa Universalis IV: Res Publica
  • March of the Eagles
  • Majesty 2 Collection
  • Warlock 2: The Exiled
  • War of the Roses
  • Teleglitch: Die More Edition
  • Victoria 2
  • Warlock: Master of the Arcane
  • Prison Architect
  • War of the Vikings
  • Magicka: Wizard Wars Founder Wizard
  • Mount & Blade: With Fire and Sword
  • Crusader Kings II: Way of Life
  • Pillars of Eternity
  • Age of Wonders III
  • Shadowrun Returns
  • Shadowrun: Dragonfall
  • Shadowrun: Hong Kong
  • Europa Universalis IV
  • Magicka
  • The Kings Crusade
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: The Republic
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: Charlemagne
  • Crusader Kings II
  • Crusader Kings II: Sword of Islam
  • Darkest Hour
  • Knights of Pen and Paper +1 Edition
  • King Arthur II
  • Hearts of Iron III: Their Finest Hour
  • Hearts of Iron III
  • For the Motherland
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Conquest of Paradise
  • Magicka 2
  • Crusader Kings II: Sunset Invasion
  • Arsenal of Democracy
  • Victoria 2: Heart of Darkness
  • Semper Fi
D O G
...
Am I reading this right that the AI will never build more than 3 Foundries per world? That seems like a... not good thing.

... this is, uh, not a reassuring thing to hear.
...

The above points that you bring up are good examples of why the old system wasn't really working. The AI no longer follow those scripts and therefore you need not worry about me not knowing how the numbers compare etc :)
 

RadioactiveHellion

First Lieutenant
46 Badges
Sep 18, 2009
203
19
  • Crusader Kings II: Charlemagne
  • Majesty 2
  • Magicka
  • Crusader Kings II: Sword of Islam
  • Crusader Kings II
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: The Republic
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Legacy of Rome
  • BATTLETECH
  • Stellaris: Federations
  • Crusader Kings II: Jade Dragon
  • Stellaris: Humanoids Species Pack
  • Stellaris: Apocalypse
  • BATTLETECH - Digital Deluxe Edition
  • Stellaris: Distant Stars
  • Shadowrun Returns
  • Shadowrun: Dragonfall
  • Shadowrun: Hong Kong
  • Stellaris: Megacorp
  • Crusader Kings II: Holy Fury
  • Stellaris: Ancient Relics
  • Age of Wonders: Planetfall
  • Stellaris: Lithoids
  • BATTLETECH: Heavy Metal
  • Stellaris: Galaxy Edition
  • Mount & Blade: Warband
  • 500k Club
  • Crusader Kings II: Way of Life
  • War of the Roses
  • Crusader Kings II: Horse Lords
  • Crusader Kings II: Conclave
  • Crusader Kings Complete
  • Stellaris
  • Stellaris: Galaxy Edition
  • Crusader Kings II: Reapers Due
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Leviathans Story Pack
  • Crusader Kings II: Monks and Mystics
  • Stellaris - Path to Destruction bundle
  • BATTLETECH: Flashpoint
  • Crusader Kings II: Sunset Invasion
  • BATTLETECH: Season pass
  • Imperator: Rome
  • Stellaris: Synthetic Dawn
‘pops = 500’
The pops field is the goal number of pops that the AI will try to reach. It will not stop producing pops when this number is reached, however pop growth and assembly buildings will be weighted much lower in favor of more resource production when the goal has been reached.

I don't know about this. Creating more pops (and thus jobs) seems like a cornerstone of building powerful economies and you lose ground when growth slows.
It seems to me that it'd be better to design economy AI plans around pop/job expansion rather than making it an incidental target number.
 

Karael

Recruit
74 Badges
May 24, 2016
4
3
  • Crusader Kings II
  • Europa Universalis IV: Cossacks
  • Europa Universalis IV
  • Stellaris - Path to Destruction bundle
  • Stellaris: Synthetic Dawn
  • Surviving Mars
  • Crusader Kings II: Reapers Due
  • Europa Universalis IV: Rights of Man
  • Tyranny: Archon Edition
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Leviathans Story Pack
  • Crusader Kings II: Monks and Mystics
  • Cities: Skylines - Mass Transit
  • Europa Universalis IV: Mandate of Heaven
  • Stellaris: Ancient Relics
  • BATTLETECH
  • Age of Wonders: Planetfall
  • Age of Wonders III
  • Cities: Skylines - Green Cities
  • Stellaris: Megacorp
  • Europa Universalis IV: Dharma
  • Stellaris: Humanoids Species Pack
  • Stellaris: Apocalypse
  • Europa Universalis IV: Rule Britannia
  • BATTLETECH - Digital Deluxe Edition
  • Cities: Skylines - Parklife
  • Stellaris: Distant Stars
  • Age of Wonders: Planetfall Deluxe edition
  • Stellaris: Federations
  • Age of Wonders: Planetfall Premium edition
  • Imperator: Rome
  • Stellaris: Necroids
  • Age of Wonders: Planetfall - Revelations
  • Europa Universalis IV: Golden Century
  • Age of Wonders: Planetfall Season pass
  • Imperator: Rome Deluxe Edition
  • Imperator: Rome - Magna Graecia
  • Europa Universalis IV: Conquest of Paradise
  • BATTLETECH: Heavy Metal
  • Hearts of Iron IV: Cadet
  • Cities: Skylines
  • Europa Universalis IV: El Dorado
  • Crusader Kings II: Holy Fury
  • Crusader Kings II: Way of Life
  • Pillars of Eternity
  • Europa Universalis IV: Common Sense
  • Crusader Kings II: Horse Lords
  • Stellaris: Lithoids
  • Knights of Pen and Paper 2
  • Crusader Kings II: Conclave
I have become a bit cynical after the effect that the last few updates and expansions have had on the AI. It’s been a while since I’ve played Stellaris, but this is probably the best dev diary I’ve ever read for this game and I haven’t been this excited to return to Stellaris in a long long time. Fantastic work.
 

sidestep

Blue Flame Provider
44 Badges
Feb 13, 2018
106
0
  • Victoria 2: A House Divided
  • Sengoku
  • Europa Universalis IV: Res Publica
  • March of the Eagles
  • Majesty 2 Collection
  • Warlock 2: The Exiled
  • War of the Roses
  • Teleglitch: Die More Edition
  • Victoria 2
  • Warlock: Master of the Arcane
  • Prison Architect
  • War of the Vikings
  • Magicka: Wizard Wars Founder Wizard
  • Mount & Blade: With Fire and Sword
  • Crusader Kings II: Way of Life
  • Pillars of Eternity
  • Age of Wonders III
  • Shadowrun Returns
  • Shadowrun: Dragonfall
  • Shadowrun: Hong Kong
  • Europa Universalis IV
  • Magicka
  • The Kings Crusade
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: The Republic
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: Charlemagne
  • Crusader Kings II
  • Crusader Kings II: Sword of Islam
  • Darkest Hour
  • Knights of Pen and Paper +1 Edition
  • King Arthur II
  • Hearts of Iron III: Their Finest Hour
  • Hearts of Iron III
  • For the Motherland
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Conquest of Paradise
  • Magicka 2
  • Crusader Kings II: Sunset Invasion
  • Arsenal of Democracy
  • Victoria 2: Heart of Darkness
  • Semper Fi
@sidestep I'm curious how much weight the economic AI puts on pop growth and assembly when forming its long term plans. Right now, those factors seem to be the most important in ensuring a snowballing economy.

Also, can you share any concrete metrics for what levels of economic output the AI is able to achieve by certain years in-game?
It weights pop growth and assembly heavily, its one of the highest weighted factors in the new economy.
Code:
AI_POPS_SCORE_MULT = 5                        # AI will score pop growth and assembly buildings this much more ( already fairly high weighted  in code )
This define makes sure that pops/assembly get a 5 times multiplier bonus when being selected. It's base weight is also very high since the pop goals are fairly large numbers
 

MatRopert

HoI4 Tech Lead
2 Badges
May 11, 2018
270
996
mropert.github.io
  • Battle for Bosporus
You're letting the AI PLAN!? Are you insane!? If you allow this to happen, there's no telling what will happen. What if the Stellaris AI starts planning to escape my computer into the internet? We need to kill it here and now before this thing becomes a threat to all of humanity,
If we give AI the controls of our missiles, I won't be surprised if it kills us all. Although I'd be surprised if it does it because it became sentient. It's way more likely to happen because it bugged, or computed that the best mathematical way to stop people from dying was to stop them from being born.
 

FlyingPhoenix

Lt. General
17 Badges
May 16, 2016
1.395
560
  • Tyranny - Tales from the Tiers
  • Stellaris: Synthetic Dawn
  • Stellaris: Federations
  • Stellaris: Lithoids
  • Stellaris: Ancient Relics
  • Stellaris: Megacorp
  • Stellaris: Distant Stars
  • Stellaris: Apocalypse
  • Stellaris: Humanoids Species Pack
  • Stellaris - Path to Destruction bundle
  • Stellaris: Leviathans Story Pack
  • Stellaris: Digital Anniversary Edition
  • Tyranny: Archon Edition
  • Stellaris: Galaxy Edition
  • Stellaris
  • Pillars of Eternity
  • Crusader Kings II
I don't know about this. Creating more pops (and thus jobs) seems like a cornerstone of building powerful economies and you lose ground when growth slows.
It seems to me that it'd be better to design economy AI plans around pop/job expansion rather than making it an incidental target number.
I agree.

To the devs, essentially if the AI can't resettle pops to a world with open jobs, then it is time to transition to build Habitats, Ecumenopolis and Ringworlds.
 

Alblaka

Foresightful Flag-Choser
100 Badges
Apr 12, 2013
3.988
1.482
  • Crusader Kings II
  • Stellaris - Path to Destruction bundle
  • Stellaris: Synthetic Dawn
  • Europa Universalis IV: Mare Nostrum
  • Europa Universalis IV: Pre-order
  • Europa Universalis IV: Third Rome
  • Victoria 2: Heart of Darkness
  • Victoria 2: A House Divided
  • Sword of the Stars
  • Sengoku
  • Semper Fi
  • Victoria: Revolutions
  • Europa Universalis IV: Res Publica
  • Magicka
  • Hearts of Iron III: Their Finest Hour
  • Hearts of Iron III
  • Europa Universalis IV: Call to arms event
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: Charlemagne
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Republic
  • Crusader Kings II: Sons of Abraham
  • Cities in Motion 2
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sword of Islam
  • For the Motherland
  • Europa Universalis IV: Art of War
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Wealth of Nations
  • Crusader Kings II: Monks and Mystics
  • Hearts of Iron IV: Together for Victory
  • Stellaris: Digital Anniversary Edition
  • Tyranny: Archon Edition
  • Europa Universalis IV: Rights of Man
  • Crusader Kings II: Reapers Due
  • Hearts of Iron IV: Colonel
  • Hearts of Iron IV: Cadet
  • Europa Universalis IV: Mandate of Heaven
  • Stellaris
  • Crusader Kings II: Conclave
  • Stellaris: Nemesis
  • Crusader Kings II: Horse Lords
  • Europa Universalis IV: Common Sense
  • Magicka 2
  • Crusader Kings II: Way of Life
  • Magicka: Wizard Wars Founder Wizard
  • Europa Universalis IV: El Dorado
  • Cities: Skylines
  • Victoria 2
I've got to say, this has to be one of the more interesting and informative DDs since quite some time. Primarily because it shows work is being done on the engine (in this case AI, an integral part) of the game, not just fancy features tacked to it's outside.

I'm looking forward to see this new AI in action (especially since it's moddable, which means +- a month after 2.6 we'll see a mod making the AI even more competitive),

albeit I still retain the right to be miffed about the questionable scope of the Federations expansion.

or computed that the best mathematical way to stop people from dying was to stop them from being born.

... I'm stealing that for my next AI round in SS13.
 

sidestep

Blue Flame Provider
44 Badges
Feb 13, 2018
106
0
  • Victoria 2: A House Divided
  • Sengoku
  • Europa Universalis IV: Res Publica
  • March of the Eagles
  • Majesty 2 Collection
  • Warlock 2: The Exiled
  • War of the Roses
  • Teleglitch: Die More Edition
  • Victoria 2
  • Warlock: Master of the Arcane
  • Prison Architect
  • War of the Vikings
  • Magicka: Wizard Wars Founder Wizard
  • Mount & Blade: With Fire and Sword
  • Crusader Kings II: Way of Life
  • Pillars of Eternity
  • Age of Wonders III
  • Shadowrun Returns
  • Shadowrun: Dragonfall
  • Shadowrun: Hong Kong
  • Europa Universalis IV
  • Magicka
  • The Kings Crusade
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: The Republic
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: Charlemagne
  • Crusader Kings II
  • Crusader Kings II: Sword of Islam
  • Darkest Hour
  • Knights of Pen and Paper +1 Edition
  • King Arthur II
  • Hearts of Iron III: Their Finest Hour
  • Hearts of Iron III
  • For the Motherland
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Conquest of Paradise
  • Magicka 2
  • Crusader Kings II: Sunset Invasion
  • Arsenal of Democracy
  • Victoria 2: Heart of Darkness
  • Semper Fi
Very interesting read. Thank you.
About AI plans: Are there specific "builds" for empire types? For example, will a Technocracy empire focus more on science if it is not forced to invest into alloys and follow a set Ascension perk plan, just like the player would? So for example: Tech Ascendancy, Flesh is Weak (insert potential perk 3 like Arcology project), Synthethic Evolution?
Right now there exists no such specific plans, BUT the system is setup so that you can do that very easily. You could for example make a general "high science" plan and weight it higher for technocracy empires. Or make a Technocracy specific plan that is limited to them only via the potential = {} trigger!
 

Mr. Morague

Second Lieutenant
14 Badges
Dec 19, 2017
147
49
  • Stellaris
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Leviathans Story Pack
  • Stellaris - Path to Destruction bundle
  • Stellaris: Humanoids Species Pack
  • Stellaris: Apocalypse
  • Stellaris: Distant Stars
  • Stellaris: Megacorp
  • Stellaris: Ancient Relics
  • Stellaris: Lithoids
  • Stellaris: Federations
  • Stellaris: Necroids
  • Stellaris: Nemesis
  • Stellaris: Synthetic Dawn
D O G

Interesting, and a good idea to give them distinct personalities, but is there anything about fixing the 'crisis is very slow and gets slower as their territory grows' issue? I had the Unbidden spawn and, despite 50 years of being unchallenged, they took 60 systems out of 1000!

I have a couple questions regarding this. Lets start with the crisis. One of its biggest issues that prevents the crisis from ever conquering the galaxy was apparently the fact that they expand slower and slower, because most of their time is spend sending construction ships all across their territory. Did you adress this? How long does it take for each Crisis to full conquer, lets say a medium galaxy now? If the Crisis can't conquer territory, then at worst you end up in a stalemate of both the crisis and the player throwing ships at each other.
Along with seemingly ignoring distance between constructors and their targets, I did a test and gave the Unbidden a few extra constructors yearly for about 40 years. As it turned out, the Unbidden only ever used up to 4 of them at a time even when they had more than 100. Hopefully some sort of fix for this is included in the upcoming update.
 

sidestep

Blue Flame Provider
44 Badges
Feb 13, 2018
106
0
  • Victoria 2: A House Divided
  • Sengoku
  • Europa Universalis IV: Res Publica
  • March of the Eagles
  • Majesty 2 Collection
  • Warlock 2: The Exiled
  • War of the Roses
  • Teleglitch: Die More Edition
  • Victoria 2
  • Warlock: Master of the Arcane
  • Prison Architect
  • War of the Vikings
  • Magicka: Wizard Wars Founder Wizard
  • Mount & Blade: With Fire and Sword
  • Crusader Kings II: Way of Life
  • Pillars of Eternity
  • Age of Wonders III
  • Shadowrun Returns
  • Shadowrun: Dragonfall
  • Shadowrun: Hong Kong
  • Europa Universalis IV
  • Magicka
  • The Kings Crusade
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: The Republic
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: Charlemagne
  • Crusader Kings II
  • Crusader Kings II: Sword of Islam
  • Darkest Hour
  • Knights of Pen and Paper +1 Edition
  • King Arthur II
  • Hearts of Iron III: Their Finest Hour
  • Hearts of Iron III
  • For the Motherland
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Conquest of Paradise
  • Magicka 2
  • Crusader Kings II: Sunset Invasion
  • Arsenal of Democracy
  • Victoria 2: Heart of Darkness
  • Semper Fi
Because you knew I'd ask ;)

If plans are moddable, does that mean modded assets can be integrated into plans, so they don't have to wait on vanilla plans to finish before they're considered?

(Also, genius solution, if yes. This is pretty much what EDAI did, but that was one plan for all. You went and did better. Thank you.)
Of course I knew that SPECIFICALLY you would ask ;)

Yeah, you can add any modded stuff to the existing plans, or just change them out completely if you want. The system does not rely on any static data that way and does not require the vanilla mods to function or anything.
 

Indignation211

Corporal
17 Badges
Dec 27, 2018
40
27
  • Hearts of Iron IV: Death or Dishonor
  • Stellaris: Federations
  • Hearts of Iron IV: La Resistance
  • Hearts of Iron IV: Expansion Pass
  • Stellaris: Megacorp
  • Cities: Skylines Industries
  • Stellaris: Apocalypse
  • Hearts of Iron IV: Expansion Pass
  • Stellaris: Synthetic Dawn
  • Victoria 2
  • Stellaris - Path to Destruction bundle
  • Hearts of Iron IV: Together for Victory
  • Hearts of Iron IV: Cadet
  • Stellaris
  • Cities: Skylines
  • Victoria 2: Heart of Darkness
  • Victoria 2: A House Divided
Question, how does trade with other empires factor into an AI economic plan? If they are trading away for example Minerals in exchange for Alloys will they build more Mining Districts and fewer Alloy Foundries?

Edit: Maybe Consumer Goods for Alloys is a better example because its a decision of one building or another.

Edit 2: Specifically monthly trades that directly affect monthly income/expense of resources as I can see that being easier to integrate into the plan.
 
Last edited:

sidestep

Blue Flame Provider
44 Badges
Feb 13, 2018
106
0
  • Victoria 2: A House Divided
  • Sengoku
  • Europa Universalis IV: Res Publica
  • March of the Eagles
  • Majesty 2 Collection
  • Warlock 2: The Exiled
  • War of the Roses
  • Teleglitch: Die More Edition
  • Victoria 2
  • Warlock: Master of the Arcane
  • Prison Architect
  • War of the Vikings
  • Magicka: Wizard Wars Founder Wizard
  • Mount & Blade: With Fire and Sword
  • Crusader Kings II: Way of Life
  • Pillars of Eternity
  • Age of Wonders III
  • Shadowrun Returns
  • Shadowrun: Dragonfall
  • Shadowrun: Hong Kong
  • Europa Universalis IV
  • Magicka
  • The Kings Crusade
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: The Republic
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: Charlemagne
  • Crusader Kings II
  • Crusader Kings II: Sword of Islam
  • Darkest Hour
  • Knights of Pen and Paper +1 Edition
  • King Arthur II
  • Hearts of Iron III: Their Finest Hour
  • Hearts of Iron III
  • For the Motherland
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Conquest of Paradise
  • Magicka 2
  • Crusader Kings II: Sunset Invasion
  • Arsenal of Democracy
  • Victoria 2: Heart of Darkness
  • Semper Fi
Does the AI also factor in potential tech improvements to their economic plans? For example, if they have a mineral deficit, will they prioritize researching mining techs in addition to building more districts?

Also will the AI demolish/rebuild their districts as the game progresses? From what I've read, their general lack of an ability to do so is why they ever end up getting ecumenopoli on their own.

And finally, have habitat weights been looked at during this sweep? From my own experience, I find they spam useless trade habitats everywhere, and never fill them with more than a couple buildings. Similar point as before, I've read that they have a hard time deconstructing old orbital mining/research stations to build the more useful habitats over.
I did not touch the research AI for this, but that would be nice indeed!

When it comes to demolish/rebuild the AI still looks at the destroy = {} triggers and ai_weight = {} ( if weight is < 0 they will destroy iirc ) when looking to demolish buildings, so they should be destroying bad buildings via that script

Habitats work just like any other planet with this system and from what I've seen the AI handles them better now as well :)
 

UltimateTobi

General
52 Badges
Mar 8, 2010
1.808
1.102
www.youtube.com
  • Stellaris: Nemesis
  • 500k Club
  • Stellaris
  • Stellaris: Galaxy Edition
  • Stellaris: Galaxy Edition
  • Stellaris - Path to Destruction bundle
  • Stellaris: Apocalypse
  • Stellaris: Megacorp
  • Stellaris: Federations
  • Stellaris: Leviathans Story Pack
  • Stellaris: Synthetic Dawn
  • Stellaris: Distant Stars
  • Stellaris: Ancient Relics
  • Stellaris: Humanoids Species Pack
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Lithoids
  • Stellaris: Necroids
  • Europa Universalis IV
  • Europa Universalis 4: Emperor
  • Island Bound
  • Prison Architect: Psych Ward
  • Arsenal of Democracy
  • Europa Universalis IV: Golden Century
  • Darkest Hour
  • Hearts of Iron III
  • Cities: Skylines
  • Cities: Skylines Industries
  • Cities: Skylines - Natural Disasters
  • Cities: Skylines - Mass Transit
  • Europa Universalis IV: Mandate of Heaven
  • Cities: Skylines - Green Cities
  • Prison Architect
  • Europa Universalis IV: Rights of Man
  • Cities: Skylines - Parklife
  • Europa Universalis IV: Dharma
  • Europa Universalis IV: Mare Nostrum
  • Europa Universalis IV: El Dorado
  • Europa Universalis IV: Common Sense
  • Europa Universalis IV: Rule Britannia
  • Europa Universalis IV: Cradle of Civilization
  • Europa Universalis IV: Pre-order
  • Cities: Skylines Deluxe Edition
  • Europa Universalis IV: Res Publica
  • Europa Universalis IV: Call to arms event
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Art of War
  • Cities: Skylines - After Dark
  • Europa Universalis IV: Cossacks
  • Europa Universalis IV: Third Rome
@MatRopert @sidestep You said most of the Military AI changes make it into 2.6 and the rest in 2.6.1.

Could you elaborate on what changes will come in 2.6.1? Will we miss out on a lot in the mean time or is it technical stuff?

I'd love to have the whole package; I've stayed away from Stellaris for more than a year now due to the AI but now my passion has been re-kindled. But... I hope 2.6.1 doesn't take too long to drop after 2.6.

And, will the AI finally be able to build Ecus, Resort worlds, etc pp? (Meaning demolishing districts and buildings in order to transform the planet.)