Stellaris

Stellaris

Not enough ratings
Limit Habitats to 2
   
Award
Favorite
Favorited
Unfavorite
File Size
Posted
328.614 KB
14 Apr @ 11:24pm
1 Change Note ( view )

Subscribe to download
Limit Habitats to 2

Description
After Paradox reworked habitats, it vastly cut down on lag and tediousness when conducting wars. However, even with the new habitats, there are just way too many. Some empires can have a total of 20-30, majorly slowing down the game.

This mod introduces a fix. It makes habitats work like regular megastructures: building one conflicts with other megastructure development AND you can only build 2 throughout the entire game. This is not changed for any origins that start with a habitat either, so choose your habitat placement wisely if you decide to pick those origins.


Things you get:
> Players and AI can only build 2 habitats throughout the game.
> Habitat construction conflicts with Megastructure construction.


Hope this helps and suggestions welcome.

P.s. This mod replaces the habitats file so if there's another mod that changes habitats it might conflict.
3 Comments
FuriousGreg 22 Apr @ 4:51pm 
Yep, that makes sense. Thanks :)
Xenoerates Xanthopoulos  [author] 22 Apr @ 4:22am 
The way I did it is in the habitats file in the mod (it's one of the only files in the mod) and copying the code from how megastructures give themselves limits. Basically, the game checks to see if you've already tried to make that specific megastructure and then stops you from making more. It creates 2 flags (both flags have to be triggered before it stops you) if you have the contingency relic, allowing you to build 2 of that specific mega instead.

I did the same thing with habitats. It essentially works the same way but doesn't need the contingency relic. If you wanted to have a higher limit, you'd have to create more flags. I can't write all the specifics here, but basically do the same thing I already did in the mod but more times.

Something like "if you've built 1 habitat, trigger flag 1, if you've built 2 habitats, trigger flag 2, etc. etc." And then, if you want them to only build 5 habitats, say something like "if triggered flag 5, no more habitats".

Hope that helps. :)
FuriousGreg 21 Apr @ 2:40pm 
HI, I'm about to try your mod but I was wondering why just 2 and is it possible to change that number? If you tell us where in your code to change the number I can do it myself locally (not upload) rather than you having to deal with individual requests :)