// Token: 0x0600007C RID: 124 RVA: 0x00004CB8 File Offset: 0x00002EB8 private int GetEnemiesCount(Site site, SiteCoreOrPartParams parms) { return(PawnGroupMakerUtility.GeneratePawnKindsExample(new PawnGroupMakerParms { tile = site.Tile, faction = site.Faction, groupKind = PawnGroupKindDefOf.Combat, points = parms.threatPoints, inhabitants = true, seed = new int?(OutpostSitePartUtility.GetPawnGroupMakerSeed(parms)) }).Count <PawnKindDef>()); }
// Token: 0x06000064 RID: 100 RVA: 0x00004278 File Offset: 0x00002478 public override void Generate(Map map, GenStepParams parms) { CellRect rectToDefend; if (!MapGenerator.TryGetVar <CellRect>("RectOfInterest", out rectToDefend)) { rectToDefend = CellRect.SingleCell(map.Center); } Faction faction; if (map.ParentFaction == null || map.ParentFaction == Faction.OfPlayer) { faction = Find.FactionManager.RandomEnemyFaction(false, false, true, TechLevel.Industrial); } else { faction = map.ParentFaction; } ResolveParams resolveParams = default(ResolveParams); resolveParams.rect = this.GetOutpostRect(rectToDefend, map); resolveParams.faction = faction; resolveParams.edgeDefenseWidth = new int?(0); resolveParams.edgeDefenseTurretsCount = new int?(Rand.RangeInclusive(0, 0)); resolveParams.edgeDefenseMortarsCount = new int?(0); if (parms.siteCoreOrPart != null) { resolveParams.settlementPawnGroupPoints = new float?(parms.siteCoreOrPart.parms.threatPoints); resolveParams.settlementPawnGroupSeed = new int?(OutpostSitePartUtility.GetPawnGroupMakerSeed(parms.siteCoreOrPart.parms)); } else { resolveParams.settlementPawnGroupPoints = new float?(this.defaultPawnGroupPointsRange.RandomInRange); } BaseGen.globalSettings.map = map; BaseGen.globalSettings.minBuildings = 28; BaseGen.globalSettings.minBarracks = 4; BaseGen.symbolStack.Push("advancedGeneration", resolveParams); BaseGen.Generate(); }