public static void EnterMapWithShip(LandedShip caravan, Map map, CaravanEnterMode enterMode) { IntVec3 enterCell = TravelingShipsUtility.CenterCell(map); Func <ShipBase, IntVec3> spawnCellGetter = (ShipBase p) => CellFinder.RandomSpawnCellForPawnNear(enterCell, map); TravelingShipsUtility.Enter(caravan, map, spawnCellGetter); }
public static void Enter(LandedShip caravan, Map map, Func <ShipBase, IntVec3> spawnCellGetter) { List <ShipBase> ships = caravan.ships; DropShipUtility.DropShipGroups(TravelingShipsUtility.CenterCell(map), map, ships, ShipArrivalAction.EnterMapFriendly); //caravan.RemoveAllPawns(); if (caravan.Spawned) { Find.WorldObjects.Remove(caravan); } }
public static void Enter(List <ShipBase> ships, Map map, bool centerDrop = true) { IntVec3 loc; if (centerDrop) { loc = TravelingShipsUtility.CenterCell(map); } else { loc = DropCellFinder.FindRaidDropCenterDistant(map); } DropShipUtility.DropShipGroups(loc, map, ships, ShipArrivalAction.EnterMapFriendly); }
public static void Enter(List <ShipBase> ships, Map map, bool centerDrop = true) { foreach (ShipBase ship in ships) { DropShipUtility.ReimbarkWorldPawnsForLandedShip(ship); } IntVec3 loc; if (centerDrop) { loc = TravelingShipsUtility.CenterCell(map); } else { loc = DropCellFinder.FindRaidDropCenterDistant(map); } DropShipUtility.DropShipGroups(loc, map, ships, TravelingShipArrivalAction.EnterMapFriendly); }