Example #1
0
        public GameCondition_VolcanicWinter()
        {
            ColorInt colorInt = new ColorInt(0, 0, 0);

            this.VolcanicWinterColors = new SkyColorSet(colorInt.ToColor, Color.white, new Color(0.6f, 0.6f, 0.6f), 0.65f);
            base..ctor();
        }
Example #2
0
        public override SkyTarget?SkyTarget(Map map)
        {
            SkyColorSet colorSet = new SkyColorSet(new Color(SkyColorR, SkyColorG, SkyColorB), new Color(SkyShadowR, SkyShadowG, SkyShadowB), new Color(SkyOverlayR, SkyOverlayG, SkyOverlayB), SkySaturation);
            float       glow     = 0f;

            return(new SkyTarget?(new SkyTarget(glow, colorSet, 1f, 1f)));
        }
        public override void GameConditionTick()
        {
            base.GameConditionTick();
            var affectedMaps = AffectedMaps;

            if (firstTick)
            {
                foreach (var map in affectedMaps)
                {
                    foreach (var pawn in map.mapPawns.FreeColonistsAndPrisoners)
                    {
                        if (!pawn.Position.Roofed(map) && pawn.def.race.IsFlesh)
                        {
                            pawn.needs.mood.thoughts.memories.TryGainMemory(CultsDefOf.Cults_SawAurora);
                        }
                    }
                }

                firstTick = false;
            }

            foreach (var map in affectedMaps)
            {
                foreach (var unused in map.mapPawns.FreeColonistsAndPrisoners)
                {
                    if (!switchTime)
                    {
                        Red            -= 0.03f;
                        Green          += 0.03f;
                        transition.r    = (int)Red;
                        transition.g    = (int)Green;
                        AuroraSkyColors = new SkyColorSet(transition.ToColor, Color.white, new Color(0.6f, 0.6f, 0.6f),
                                                          0.8f);
                        SkyTarget(map);
                    }

                    if (switchTime)
                    {
                        Red            += 0.03f;
                        Green          -= 0.03f;
                        transition.r    = (int)Red;
                        transition.g    = (int)Green;
                        AuroraSkyColors = new SkyColorSet(transition.ToColor, Color.white, new Color(0.6f, 0.6f, 0.6f),
                                                          0.8f);
                        SkyTarget(map);
                    }

                    if (switchCount >= 0)
                    {
                        switchCount -= 1;
                    }
                    else
                    {
                        switchCount = switchTicks;
                        switchTime  = !switchTime;
                    }
                }
            }
        }
Example #4
0
        public MapCondition_CorruptiveDrone()
        {
            ColorInt colorInt  = new ColorInt(240, 141, 74);
            ColorInt colorInt2 = new ColorInt(254, 245, 176);
            ColorInt colorInt3 = new ColorInt(170, 95, 60);

            this.CorruptiveDroneColors = new SkyColorSet(colorInt.ToColor, colorInt2.ToColor, colorInt3.ToColor, 1.0f);
        }
Example #5
0
        public override SkyTarget?SkyTarget(Map map)
        {
            Color       currentColor = this.CurrentColor;
            SkyColorSet colorSet     = new SkyColorSet(Color.Lerp(Color.white, currentColor, 0.075f) * this.Brightness(map), new Color(0.92f, 0.92f, 0.92f), Color.Lerp(Color.white, currentColor, 0.025f) * this.Brightness(map), 1f);
            float       glow         = Mathf.Max(GenCelestial.CurCelestialSunGlow(map), 0.25f);

            return(new SkyTarget?(new SkyTarget(glow, colorSet, 1f, 1f)));
        }
Example #6
0
        // Token: 0x06000010 RID: 16 RVA: 0x000024E0 File Offset: 0x000006E0
        public GameCondition_Spores()
        {
            var colorInt  = new ColorInt(216, 255, 0);
            var toColor   = colorInt.ToColor;
            var colorInt2 = new ColorInt(234, 200, 255);

            ToxicFalloutColors = new SkyColorSet(toColor, colorInt2.ToColor, new Color(1f, 1f, 1f), SkyGlow);
            overlays           = new List <SkyOverlay>
            {
                new WeatherOverlay_Spores()
            };
        }
    public GameCondition_LuciferiumRain()
    {
        var colorInt  = new ColorInt(216, 25, 0);
        var toColor   = colorInt.ToColor;
        var colorInt2 = new ColorInt(234, 10, 25);

        LuciferiumRainColors = new SkyColorSet(toColor, colorInt2.ToColor, new Color(0.6f, 0.8f, 0.5f), 0.85f);
        overlays             = new List <SkyOverlay>
        {
            new WeatherOverlay_LuciferiumRain()
        };
    }
Example #8
0
        public GameCondition_ToxicFallout()
        {
            ColorInt colorInt  = new ColorInt(216, 255, 0);
            Color    toColor   = colorInt.ToColor;
            ColorInt colorInt2 = new ColorInt(234, 200, 255);

            this.ToxicFalloutColors = new SkyColorSet(toColor, colorInt2.ToColor, new Color(0.6f, 0.8f, 0.5f), 0.85f);
            this.overlays           = new List <SkyOverlay>
            {
                new WeatherOverlay_Fallout()
            };
            base..ctor();
        }
Example #9
0
        public GameCondition_DrugMist()
        {
            ColorInt colorInt  = new ColorInt(255, 191, 241);
            Color    hilights  = colorInt.ToColor;
            ColorInt colorInt2 = new ColorInt(112, 147, 179);
            Color    shadows   = colorInt2.ToColor;
            ColorInt colorInt3 = new ColorInt(230, 202, 229);
            Color    overlay   = colorInt2.ToColor;


            //this.DrugMistColors = new SkyColorSet(hilights, shadows, overlay, 0.65f);     // This was too saturated

            this.DrugMistColors = new SkyColorSet(hilights, shadows, overlay, 0.3f);
            this.overlays       = new List <SkyOverlay>
            {
                new WeatherOverlay_DrugMist()
            };
        }
        public override void GameConditionTick()
        {
            base.GameConditionTick();
            var affectedMaps = AffectedMaps;

            if (firstTick)
            {
                for (var i = 0; i < affectedMaps.Count; i++)
                {
                    foreach (var pawn in affectedMaps[i].mapPawns.FreeColonistsAndPrisoners)
                    {
                        if (!pawn.Position.Roofed(affectedMaps[i]) && pawn.def.race.IsFlesh)
                        {
                            pawn.needs.mood.thoughts.memories.TryGainMemory(CultsDefOf.Cults_SawAurora);
                        }
                    }
                }

                firstTick = false;
            }

            for (var i = 0; i < affectedMaps.Count; i++)
            {
                foreach (var pawn in affectedMaps[i].mapPawns.FreeColonistsAndPrisoners)
                {
                    if (!switchTime)
                    {
                        Red            -= 0.03f;
                        Green          += 0.03f;
                        transition.r    = (int)Red;
                        transition.g    = (int)Green;
                        AuroraSkyColors = new SkyColorSet(transition.ToColor, Color.white, new Color(0.6f, 0.6f, 0.6f),
                                                          0.8f);
                        SkyTarget(affectedMaps[i]);
                    }

                    if (switchTime)
                    {
                        Red            += 0.03f;
                        Green          -= 0.03f;
                        transition.r    = (int)Red;
                        transition.g    = (int)Green;
                        AuroraSkyColors = new SkyColorSet(transition.ToColor, Color.white, new Color(0.6f, 0.6f, 0.6f),
                                                          0.8f);
                        SkyTarget(affectedMaps[i]);
                    }

                    if (switchCount >= 0)
                    {
                        switchCount -= 1;
                    }
                    else
                    {
                        switchCount = switchTicks;
                        if (switchTime)
                        {
                            //Cthulhu.Utility.DebugReport("Switch");
                            switchTime = false;
                        }

                        else
                        {
                            //Cthulhu.Utility.DebugReport("Switch");
                            switchTime = true;
                        }
                    }
                }
            }
        }