Example #1
0
 public override void DoEffect(Pawn usedBy)
 {
     base.DoEffect(usedBy);
     if (this.VoidPawn != null)
     {
         VoidKeyUtility.ResurrectPawnFromVoid(this.parent.MapHeld, this.parent.PositionHeld, this.VoidPawn);
         VoidKeyUtility.GiveSideEffects(this.VoidPawn);
     }
 }
        private static void SpawningMissPawn()
        {
            List <DebugMenuOption> list = new List <DebugMenuOption>();

            foreach (Pawn pawn in (from x in Find.WorldPawns.AllPawnsDead
                                   where x.Corpse == null && x.Faction == Faction.OfPlayer
                                   select x))
            {
                list.Add(new DebugMenuOption(pawn.NameFullColored + "(" + pawn.kindDef.race.LabelCap + ")", DebugMenuOptionMode.Tool, delegate()
                {
                    if (pawn.Dead)
                    {
                        Map map     = Find.CurrentMap;
                        IntVec3 loc = UI.MouseCell();
                        VoidKeyUtility.ResurrectPawnFromVoid(map, loc, pawn);
                    }
                }));
            }

            Find.WindowStack.Add(new Dialog_DebugOptionListLister(list));
        }