public void turnTick()
        {
            if (location != null)
            {
                location.turnTick();
            }

            if (settlement != null)
            {
            }
            else
            {
                List <Hex> neighbours = this.map.getNeighbours(this);
                float      newPurity  = 0;
                foreach (Hex h in neighbours)
                {
                    newPurity += h.purity;
                }
                newPurity /= neighbours.Count;
                purity     = (purity + newPurity) / 2;
            }
            if (Math.Abs(temporaryTempDelta) < map.param.map_tempTemperatureReversion)
            {
                temporaryTempDelta = 0;
            }
            else if (temporaryTempDelta > 0)
            {
                temporaryTempDelta -= map.param.map_tempTemperatureReversion;
            }
            else
            {
                temporaryTempDelta += map.param.map_tempTemperatureReversion;
            }
        }
Example #2
0
        public void turnTick()
        {
            if (location != null)
            {
                location.turnTick();
            }

            if (settlement != null)
            {
            }
            else
            {
                List <Hex> neighbours = this.map.getNeighbours(this);
                float      newPurity  = 0;
                foreach (Hex h in neighbours)
                {
                    newPurity += h.purity;
                }
                newPurity /= neighbours.Count;
                purity     = (purity + newPurity) / 2;
            }
            float reversion = (float)map.param.map_tempTemperatureReversion;

            if (map.burnInComplete == false)
            {
                reversion *= 10;
            }
            if (Math.Abs(transientTempDelta) < reversion)
            {
                transientTempDelta = 0;
            }
            else if (transientTempDelta > 0)
            {
                transientTempDelta -= reversion;
            }
            else
            {
                transientTempDelta += reversion;
            }
            if (World.cheat_globalCooling)
            {
                transientTempDelta -= 0.01f;
            }
            if (cloud != null)
            {
                cloud.turnTick(this);
            }

            map.data_globalTempSum += getTemperature();
        }