Alpha Centauri 2

Sid Meier's Alpha Centauri & Alien Crossfire => The Theory of Everything => Topic started by: Yitzi on December 22, 2015, 12:32:42 AM

Title: Pop location calculation
Post by: Yitzi on December 22, 2015, 12:32:42 AM
I've parsed the calculations for determining, when a base has a fungal pop, where it will happen, so here they are:

For each square within distance 3 of the base (counting diagonals as 1, so this is the base radius+anything next to it+corners), except those that already have fungus or a base, roll a virtual die with number of sides determined as follows:
-Squares next to the popping base (including diagonally) start with 10 if adjacent to fungus, and are ignored (don't roll for them) otherwise.  Squares next to those start with 0 if adjacent to fungus, and are ignored otherwise.  Squares next to those start with 10 and are not ignored even if not next to fungus, but are completely ignored if the popping base is not the closest one*, even if the closer one is owned by a different faction.
-If it is adjacent to fungus along an edge (not corners, just a full edge), add 20 for each such fungus square, plus 10 each for a mine, solar, farm, enricher, or forest in the square.  (If not adjacent to fungus, it doesn't add for improvements).
Whichever die rolls highest gets the pop**.
-If the square is a sea square of any depth, halve the die size, rounding up to the next 10.

*Ties for "closest base" seem to be resolved in favor of the older base.
**Ties here are resolved in a particular order that tends to prefer squares closer to the base.

Note that if there is no eligible square (e.g. no fungus within distance 3 and all squares of distance exactly 3 have a closer base, or every square within distance 3 has fungus), then there will be no pop even if ecodamage chance is 100 or more; these two scenarios are demonstrated in the attached savegames.
Title: Re: Pop location calculation
Post by: Dio on December 22, 2015, 02:17:17 AM
I think this represents a cool advance in the understanding of native life formation.  ;b;
Templates: 1: Printpage (default).
Sub templates: 4: init, print_above, main, print_below.
Language files: 4: index+Modifications.english (default), TopicRating/.english (default), PortaMx/PortaMx.english (default), OharaYTEmbed.english (default).
Style sheets: 0: .
Files included: 33 - 892KB. (show)
Queries used: 19.

[Show Queries]