• 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.

Measter

Major
70 Badges
Jan 2, 2011
612
4
  • Crusader Kings II
  • Europa Universalis IV: Pre-order
  • Sword of the Stars II
  • Sword of the Stars
  • Sengoku
  • Semper Fi
  • Europa Universalis IV: Res Publica
  • Magicka
  • Heir to the Throne
  • 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
  • Europa Universalis IV
  • Cities in Motion 2
  • 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
  • Crusader Kings II: Sword of Islam
  • Europa Universalis III
  • Europa Universalis III Complete
  • Divine Wind
  • Europa Universalis IV: Art of War
  • Crusader Kings II: Conclave
  • Stellaris - Path to Destruction bundle
  • Europa Universalis IV: Mare Nostrum
  • Stellaris
  • Stellaris: Galaxy Edition
  • Europa Universalis IV: Mandate of Heaven
  • BATTLETECH
  • Crusader Kings II: Reapers Due
  • Europa Universalis IV: Rights of Man
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Leviathans Story Pack
  • Crusader Kings II: Monks and Mystics
  • Europa Universalis IV: Cossacks
  • Crusader Kings II: Horse Lords
  • Europa Universalis IV: Common Sense
  • Pillars of Eternity
  • Crusader Kings II: Way of Life
  • Europa Universalis IV: El Dorado
  • Age of Wonders III
  • 500k Club
  • Teleglitch: Die More Edition
  • Europa Universalis IV: Cradle of Civilization
  • Europa Universalis III Complete
  • Europa Universalis III Complete
I'm trying to create static maps, and the map itself is working fine. However, the game isn't handling home systems correctly, resulting in the players being spawned in players being spawned on uninhabitable planets. Like so:
9ZZlosE.png


I've tried setting a certain number of the system initializers to have valid home planets, including with the home_planet flag, but the game isn't using those correctly. In fact, even when all the systems have a home planet, planet is uninhabitable, despite being set to random ideal.

vhKz0GA.png


Have I completely missed something, or is this feature broken?
 
  • 1
Reactions:
Similar problem here, I would like to spawn the player empire on a predefined planet whose solar system initializer is limited to one, but it just appears somewhere random.
 
I'm having much this same issue.

I don't know if I can help or not, but I'd love to take a look at your mod files.

There's not a great deal to it. The maps are basic static maps like this:

Code:
static_galaxy_scenario = {
   name = "New Eden - Caldari (326 Stars)"
   priority = -1
   colonizable_planet_odds = 1.0
   num_empires = { min = 1 max = 32 }
   num_empire_default = 8
   advanced_empire_default = 0
   core_radius = 0
   random_hyperlanes = no
   nebula = {
     name = "The Forge"
     position = { x = -265 y = -91 }
     radius = 90
   }

...

   system = {
     id = "itamo"
     position = { x = -195 y = -89 }
     initializer = itamo_system_initializer
   }

...

   add_hyperlane = { from = "rakapas" to = "reitsato" }

...
}

And the initialisers are all like this for now:

Code:
itamo_system_initializer = {
     name="Itamo"
     class = "sc_m"
     flags = { itamo_system }
     planet = {
       name = "Itamo"
       class = "pc_m_star"
       orbit_distance = 0
       orbit_angle = 1
       size = 30
       has_ring = no
     }
     planet = {
       count = { min = 1 max = 10 }
       class = random
       orbit_distance = { min = 30 max = 100 }
       orbit_angle = { min = 0 max = 360 }
       change_orbit = 10
       moon = {
         count = { min = 0 max = 3 }
         class = random
         orbit_distance = { min = 2 max = 5 }
         orbit_angle = { min = 0 max = 360 }
       }
     }
}

I've had some success with creating an event to create the homeworlds. So far, I've set up three events that fire at game start, that do this:

The first one resizes the planet:
Code:
event = {
   id = new_eden_start.1
   hide_window = yes
   is_triggered_only = yes

   immediate = {
     every_country = {
       if = {
         limit = { exists = capital_scope }
         capital_scope = {
           if = {
             limit = { planet_size = 1 }
             change_planet_size = 15
           }
           ...
           if = {
             limit = { planet_size = 2 }
             change_planet_size = -1
             change_planet_size = 15
           }
         }
       }
     }
   }
}

It's setting the size to 1 then back to 16 to force the area to be square. Otherwise it can cause some issues with the capital. The second sets the planet type:

Code:
event = {
   id = new_eden_start.2
   hide_window = yes
   is_triggered_only = yes

   immediate = {
     every_country = {
       if = {
         limit = {
           ideal_planet_class = pc_arid
           exists = capital_scope
         }
         capital_scope = {
           change_pc = pc_arid
         }
       }
    }
   }
}

The final one is basically the same as the homeworlds are set up in the default empire_initializers.txt file.

I am having a couple problems, however. The first is that this planet isn't considered a homeworld, so its habitability is 80%, not 100%. The second is that the number of pops is inconsistant.
 
Well, this is irritating. I had the script mostly working, aside form the habitability, and then the patch goes and breaks one of the events. The first two are working correctly, as the planet size, buldings and pop are correct. Event 2, however, is only setting the planet class for the player.

Anyone got any ideas?

https://gist.github.com/Measter/3881d30e8145d739a69c46513bb1115b#file-gistfile1-txt-L143

[Edit] I think I've found the cause. On a static map it looks like AI races don't have a class preference, so that event ends up not doing anything.
 
Last edited: