RectTriggerIntrusion class.
Наследование: Thing
Пример #1
0
        public static void SpawnRectTriggerUnfogArea(CellRect rect, ref TriggerIntrusion triggerIntrusion)
        {
            RectTriggerUnfogArea rectTrigger = (RectTriggerUnfogArea)ThingMaker.MakeThing(ThingDef.Named("RectTriggerUnfogArea"));

            rectTrigger.Rect = rect;
            GenSpawn.Spawn(rectTrigger, rect.Center);

            // Update the trigger intrusion watched cells.
            foreach (IntVec3 cell in rect.Cells)
            {
                if (triggerIntrusion.watchedCells.Contains(cell) == false)
                {
                    triggerIntrusion.watchedCells.Add(cell);
                }
            }
        }
Пример #2
0
        public static void SpawnRectTriggerUnfogArea(CellRect rect, ref TriggerIntrusion triggerIntrusion)
        {
            RectTriggerUnfogArea rectTrigger = (RectTriggerUnfogArea)ThingMaker.MakeThing(ThingDef.Named("RectTriggerUnfogArea"));
            rectTrigger.Rect = rect;
            GenSpawn.Spawn(rectTrigger, rect.CenterCell);

            // Update the trigger intrusion watched cells.
            foreach (IntVec3 cell in rect.Cells)
            {
                if (triggerIntrusion.watchedCells.Contains(cell) == false)
                {
                    triggerIntrusion.watchedCells.Add(cell);
                }
            }
        }