public override void GenerateIntoMap(Map map) { if (Find.GameInitData != null) { GenStep_ScatterThings genStep_ScatterThings = new GenStep_ScatterThings(); genStep_ScatterThings.nearPlayerStart = this.NearPlayerStart; genStep_ScatterThings.thingDef = base.thingDef; genStep_ScatterThings.stuff = base.stuff; genStep_ScatterThings.count = base.count; genStep_ScatterThings.spotMustBeStandable = true; genStep_ScatterThings.minSpacing = 5f; genStep_ScatterThings.clusterSize = ((base.thingDef.category == ThingCategory.Building) ? 1 : 4); genStep_ScatterThings.Generate(map); } }
public override void GenerateIntoMap(Map map) { if (Find.GameInitData != null) { GenStep_ScatterThings genStep_ScatterThings = new GenStep_ScatterThings(); genStep_ScatterThings.nearPlayerStart = NearPlayerStart; genStep_ScatterThings.allowFoggedPositions = !NearPlayerStart; genStep_ScatterThings.thingDef = thingDef; genStep_ScatterThings.stuff = stuff; genStep_ScatterThings.count = count; genStep_ScatterThings.spotMustBeStandable = true; genStep_ScatterThings.minSpacing = 5f; genStep_ScatterThings.clusterSize = ((thingDef.category == ThingCategory.Building) ? 1 : 4); genStep_ScatterThings.Generate(map, default(GenStepParams)); } }
internal static bool Prefix(Map map, GenStepParams parms, ref GenStep_ScatterThings __instance) { if (__instance.thingDef == ThingDefOf.SteamGeyser) { if (map.Biome.HasModExtension <BiomesMap>()) { if (map.Biome.GetModExtension <BiomesMap>().hasScatterables&& __instance.allowInWaterBiome == false) { bool seaSpawns = __instance.allowInWaterBiome; FloatRange range = __instance.countPer10kCellsRange; __instance.allowInWaterBiome = true; __instance.countPer10kCellsRange.min /= 2; __instance.countPer10kCellsRange.max /= 2; __instance.Generate(map, parms); __instance.allowInWaterBiome = seaSpawns; __instance.countPer10kCellsRange = range; return(false); } } } return(true); }