public override bool TryExecute(IncidentParms parms) { ////Spawn a Dark Young //if (CthulhuUtility.IsCosmicHorrorsLoaded()) //{ // CthulhuUtility.SpawnPawnsOfCountAt(DefDatabase<PawnKindDef>.GetNamed("DarkYoung"), altar.Position, 1, Faction.OfPlayer); //} //else //{ // CthulhuUtility.SpawnPawnsOfCountAt(PawnKindDefOf.Megaspider, altar.Position, Rand.Range(1,2), Faction.OfPlayer); //} //Messages.Message("The Dark Young of Shub Niggurath coils out from under the sacrifice.", MessageSound.Benefit); //return true; IntVec3 intVec; //Find a drop spot if (!ShipChunkDropCellFinder.TryFindShipChunkDropCell(out intVec, Find.Map.Center, 999999)) { return(false); } //Spawn 1 Womb Between Worlds Building_WombBetweenWorlds thing = (Building_WombBetweenWorlds)ThingMaker.MakeThing(CultDefOfs.WombBetweenWorlds, null); thing.SetFaction(Faction.OfPlayer); GenPlace.TryPlaceThing(thing, intVec.RandomAdjacentCell8Way(), ThingPlaceMode.Near); MapComponent_SacrificeTracker.Get.lastLocation = intVec; Messages.Message(".", intVec, MessageSound.Benefit); return(true); }
public override bool TryExecute(IncidentParms parms) { IntVec3 intVec; //Find a drop spot if (!ShipChunkDropCellFinder.TryFindShipChunkDropCell(out intVec, Find.Map.Center, 999999)) { return(false); } //Spawn 1 relic Building_TreasureChest thing = (Building_TreasureChest)ThingMaker.MakeThing(CultDefOfs.TreasureChest_Relic, null); GenPlace.TryPlaceThing(thing, intVec.RandomAdjacentCell8Way(), ThingPlaceMode.Near); //Spawn 1 treasure chest Building_TreasureChest thing2 = (Building_TreasureChest)ThingMaker.MakeThing(CultDefOfs.TreasureChest, null); GenPlace.TryPlaceThing(thing2, intVec.RandomAdjacentCell8Way(), ThingPlaceMode.Near); MapComponent_SacrificeTracker.Get.lastLocation = intVec; Messages.Message("Treasures from the deep mysteriously appear.", intVec, MessageSound.Benefit); return(true); }