Ejemplo n.º 1
0
        private static Material MatFromColorPct(float colorPct, bool transparent)
        {
            int num = Mathf.RoundToInt(colorPct * 100f);

            num = GenMath.PositiveMod(num, 100);
            return(DebugMatsSpectrum.Mat(num, transparent));
        }
Ejemplo n.º 2
0
        private static Material MatFromColorPct(float colorPct, bool transparent)
        {
            int x = Mathf.RoundToInt((float)(colorPct * 100.0));

            x = GenMath.PositiveMod(x, 100);
            return(DebugMatsSpectrum.Mat(x, transparent));
        }
Ejemplo n.º 3
0
        public Color GetCellExtraColor(int index)
        {
            IntVec3  c        = map.cellIndices.IndexToCell(index);
            int      num      = CountAt(c);
            ThingDef thingDef = ThingDefAt(c);

            return(DebugMatsSpectrum.Mat(Mathf.RoundToInt((float)num / (float)thingDef.deepCountPerCell / 2f * 100f) % 100, transparent: true).color);
        }
        public Color GetCellExtraColor(int index)
        {
            IntVec3  c        = this.map.cellIndices.IndexToCell(index);
            int      num      = this.CountAt(c);
            ThingDef thingDef = this.ThingDefAt(c);
            float    num2     = (float)num / (float)thingDef.deepCountPerCell / 2f;
            int      num3     = Mathf.RoundToInt(num2 * 100f);

            num3 %= 100;
            return(DebugMatsSpectrum.Mat(num3, true).color);
        }
Ejemplo n.º 5
0
 private static Material MatFromColorPct(float colorPct, bool transparent)
 {
     return(DebugMatsSpectrum.Mat(GenMath.PositiveMod(Mathf.RoundToInt(colorPct * 100f), 100), transparent));
 }