public override void EjectContents() { ThingDef named = DefDatabase <ThingDef> .GetNamed("FilthSlime", true); foreach (Thing current in this.container) { Pawn pawn = current as Pawn; if (pawn != null) { pawn.filth.GainFilth(named); if (this.IcookingTicking != IcookingTime) { PawnChanger.ExecuteBadThings(pawn); } } } if (!base.Destroyed) { SoundDef.Named("CryptosleepCasketEject").PlayOneShot(SoundInfo.InWorld(base.Position, MaintenanceType.None)); } this.IcookingTicking = 0; ChangeColour(this.red); base.EjectContents(); }
public void ConclusionAdder(Pawn pawn) { pawn.health.AddHediff(HediffDef.Named("Rewire"), null, null); if (PawnChanger.HasMood(pawn, ThoughtDef.Named("Wrecked")) || PawnChanger.HasMood(pawn, ThoughtDef.Named("Scrambled"))) { PawnChanger.ExecuteBadThings(pawn); } PawnChanger.SetMood(pawn); }
public void CookIt() { foreach (Thing current in this.container) { Pawn pawn = current as Pawn; if (pawn != null) { PawnChanger.SetPawnTraits(pawn, Rand.RangeInclusive(2, 3)); pawn.health.AddHediff(HediffDef.Named("Rewire"), null, null); if (PawnChanger.HasMood(pawn, ThoughtDef.Named("Wrecked")) || PawnChanger.HasMood(pawn, ThoughtDef.Named("Scrambled"))) { PawnChanger.ExecuteBadThings(pawn); } PawnChanger.SetMood(pawn); } } }
public override void EjectContents() { foreach (Thing current in this.innerContainer) { Pawn pawn = current as Pawn; if (pawn != null) { if (this.IcookingTicking != IcookingTime) { PawnChanger.ExecuteBadThings(pawn); } } } if (!base.Destroyed) { SoundDef.Named("CryptosleepCasketEject").PlayOneShot(SoundInfo.InMap(new TargetInfo(base.Position, base.Map, false), MaintenanceType.None)); } this.IcookingTicking = 0; ChangeColour(this.red); base.EjectContents(); }
public void TraitChanger(Pawn pawn) { PawnChanger.SetPawnTraits(pawn, Rand.RangeInclusive(2, 3)); }