示例#1
0
        public override void Tick()
        {
            base.Tick();

            if (turretGun == null)
            {
                turretGun = ThingMaker.MakeThing(DefDatabase<ThingDef>.GetNamed("Component_TurretGun"), (ThingDef)null) as Component_TurretGun;
                turretGun.Position = (this.Position.ToVector3() + componentOffset).ToIntVec3();
                turretGun.SpawnSetup();
                turretGun.SetFaction(Faction.OfColony);
            }
            turretGun.Position = (this.Position.ToVector3() + componentOffset).ToIntVec3();
        }
示例#2
0
        public override void SpawnSetup()
        {
            base.SpawnSetup();

             UpdateGraphics();

             backDoorIsOpen = false;
             hetchIsOpen = false;

             turretGun = ThingMaker.MakeThing(DefDatabase<ThingDef>.GetNamed("Component_TurretGun"), (ThingDef)null) as Component_TurretGun;
        }