public override BuildingDef CreateBuildingDef() { string id = ID; int width = 1; int height = 1; string anim = "walls_kanim"; int hitpoints = 30; float construction_time = 30f; float[] tieR4 = BUILDINGS.CONSTRUCTION_MASS_KG.TIER4; string[] rawMinerals = MATERIALS.RAW_MINERALS; float melting_point = 1600f; BuildLocationRule build_location_rule = BuildLocationRule.Anywhere; EffectorValues none = NOISE_POLLUTION.NONE; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(id, width, height, anim, hitpoints, construction_time, tieR4, rawMinerals, melting_point, build_location_rule, DECOR.NONE, none, 0.2f); buildingDef.Floodable = false; buildingDef.Overheatable = false; buildingDef.Entombable = false; buildingDef.AudioCategory = "Metal"; buildingDef.BaseTimeUntilRepair = -1f; buildingDef.DefaultAnimState = "off"; buildingDef.ObjectLayer = ObjectLayer.Backwall; buildingDef.SceneLayer = Grid.SceneLayer.Paintings; return(buildingDef); }
public override BuildingDef CreateBuildingDef() { string id = "LiquidReservoirSmart"; int width = 2; int height = 3; string anim = "liquidreservoir_kanim"; int hitpoints = 100; float construction_time = 120f; float[] tieR4 = TUNING.BUILDINGS.CONSTRUCTION_MASS_KG.TIER4; string[] allMetals = MATERIALS.ALL_METALS; float melting_point = 800f; BuildLocationRule build_location_rule = BuildLocationRule.Anywhere; EffectorValues none = TUNING.NOISE_POLLUTION.NONE; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(id, width, height, anim, hitpoints, construction_time, tieR4, allMetals, melting_point, build_location_rule, TUNING.BUILDINGS.DECOR.PENALTY.TIER1, none, 0.2f); buildingDef.InputConduitType = ConduitType.Liquid; buildingDef.OutputConduitType = ConduitType.Liquid; buildingDef.Floodable = false; buildingDef.ViewMode = OverlayModes.LiquidConduits.ID; buildingDef.AudioCategory = "HollowMetal"; buildingDef.UtilityInputOffset = new CellOffset(1, 2); buildingDef.UtilityOutputOffset = new CellOffset(0, 0); buildingDef.PermittedRotations = PermittedRotations.R360; return(buildingDef); }
public override BuildingDef CreateBuildingDef() { int width = 1; int height = 1; string anim = "door_internal_kanim"; int hitpoints = 30; float construction_time = 5f; float[] tieR1 = TUNING.BUILDINGS.CONSTRUCTION_MASS_KG.TIER1; string[] allMetals = MATERIALS.ALL_METALS; float melting_point = 1600f; BuildLocationRule build_location_rule = BuildLocationRule.Tile; EffectorValues none = TUNING.NOISE_POLLUTION.NONE; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(ID, width, height, anim, hitpoints, construction_time, tieR1, allMetals, melting_point, build_location_rule, TUNING.BUILDINGS.DECOR.NONE, none, 1f); buildingDef.Entombable = true; buildingDef.Floodable = false; buildingDef.IsFoundation = false; buildingDef.AudioCategory = "Metal"; buildingDef.PermittedRotations = PermittedRotations.R90; buildingDef.ForegroundLayer = Grid.SceneLayer.InteriorWall; SoundEventVolumeCache.instance.AddVolume("door_internal_kanim", "Open_DoorInternal", TUNING.NOISE_POLLUTION.NOISY.TIER2); SoundEventVolumeCache.instance.AddVolume("door_internal_kanim", "Close_DoorInternal", TUNING.NOISE_POLLUTION.NOISY.TIER2); return(buildingDef); }
public override BuildingDef CreateBuildingDef() { string id = ID; int width = 2; int height = 2; string anim = "gravitas_chair_kanim"; int hitpoints = 50; float construction_time = 20f; float[] construction_mass = BUILDINGS.CONSTRUCTION_MASS_KG.TIER3; string[] construction_materials = MATERIALS.PLASTICS; float melting_point = 1600f; BuildLocationRule build_location_rule = BuildLocationRule.OnFloor; EffectorValues none = NOISE_POLLUTION.NONE; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(id, width, height, anim, hitpoints, construction_time, construction_mass, construction_materials, melting_point, build_location_rule, BUILDINGS.DECOR.BONUS.TIER3, none); buildingDef.Floodable = true; buildingDef.Overheatable = false; buildingDef.AudioCategory = "Plastic"; buildingDef.AudioSize = "small"; buildingDef.BaseTimeUntilRepair = -1f; buildingDef.ViewMode = SimViewMode.Decor; buildingDef.SceneLayer = Grid.SceneLayer.Building; buildingDef.DefaultAnimState = "off"; return(buildingDef); }
public override BuildingDef CreateBuildingDef() { string id = "InverseElectrolyzer"; int width = 4; int height = 3; string anim = "waterpurifier_kanim"; int hitpoints = 100; float construction_time = 30f; float[] tIER = TUNING.BUILDINGS.CONSTRUCTION_MASS_KG.TIER3; string[] aLL_METALS = MATERIALS.ALL_METALS; float melting_point = 800f; BuildLocationRule build_location_rule = BuildLocationRule.OnFloor; EffectorValues tIER2 = NOISE_POLLUTION.NOISY.TIER3; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(id, width, height, anim, hitpoints, construction_time, tIER, aLL_METALS, melting_point, build_location_rule, TUNING.BUILDINGS.DECOR.PENALTY.TIER2, tIER2, 0.2f); buildingDef.RequiresPowerInput = true; buildingDef.EnergyConsumptionWhenActive = 120f; buildingDef.ExhaustKilowattsWhenActive = 0f; buildingDef.SelfHeatKilowattsWhenActive = 4f; buildingDef.InputConduitType = ConduitType.Gas; buildingDef.OutputConduitType = ConduitType.Gas; buildingDef.ViewMode = SimViewMode.GasVentMap; buildingDef.MaterialCategory = MATERIALS.ALL_METALS; buildingDef.AudioCategory = "HollowMetal"; buildingDef.PowerInputOffset = new CellOffset(2, 0); buildingDef.UtilityInputOffset = new CellOffset(-1, 2); buildingDef.UtilityOutputOffset = new CellOffset(2, 2); buildingDef.PermittedRotations = PermittedRotations.FlipH; return(buildingDef); }
public override BuildingDef CreateBuildingDef() { float[] tieR2_1 = BUILDINGS.CONSTRUCTION_MASS_KG.TIER2; string[] refinedMetals = MATERIALS.REFINED_METALS; EffectorValues tieR1 = NOISE_POLLUTION.NOISY.TIER1; EffectorValues tieR2_2 = BUILDINGS.DECOR.PENALTY.TIER2; EffectorValues noise = tieR1; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef( ID, 1, 3, "gas_emptying_station_kanim", 30, 60f, tieR2_1, refinedMetals, 1600f, BuildLocationRule.OnFloor, tieR2_2, noise); buildingDef.Floodable = false; buildingDef.Overheatable = false; buildingDef.Entombable = true; buildingDef.AudioCategory = "HollowMetal"; buildingDef.PermittedRotations = PermittedRotations.FlipH; buildingDef.OutputConduitType = ConduitType.Liquid; buildingDef.UtilityOutputOffset = new CellOffset(0, 0); buildingDef.ViewMode = OverlayModes.LiquidConduits.ID; return(buildingDef); }
public override BuildingDef CreateBuildingDef() { string id = "CornerMoulding"; int width = 1; int height = 1; string anim = "corner_tile_kanim"; int hitpoints = 10; float construction_time = 30f; float[] tIER = BUILDINGS.CONSTRUCTION_MASS_KG.TIER2; string[] rAW_MINERALS = MATERIALS.RAW_MINERALS; float melting_point = 800f; BuildLocationRule build_location_rule = BuildLocationRule.InCorner; EffectorValues nONE = NOISE_POLLUTION.NONE; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(id, width, height, anim, hitpoints, construction_time, tIER, rAW_MINERALS, melting_point, build_location_rule, new EffectorValues { amount = 5, radius = 3 }, nONE, 0.2f); buildingDef.DefaultAnimState = "corner"; buildingDef.Floodable = false; buildingDef.Overheatable = false; buildingDef.ViewMode = OverlayModes.Decor.ID; buildingDef.AudioCategory = "Metal"; buildingDef.AudioSize = "small"; buildingDef.PermittedRotations = PermittedRotations.FlipH; return(buildingDef); }
public override BuildingDef CreateBuildingDef() { string id = "GasConduitOverflow"; int width = 2; int height = 2; string anim = "valvegas_kanim"; int hitpoints = 10; float construction_time = 3f; float[] tIER = BUILDINGS.CONSTRUCTION_MASS_KG.TIER1; string[] rAW_MINERALS = MATERIALS.RAW_MINERALS; float melting_point = 1600f; BuildLocationRule build_location_rule = BuildLocationRule.Conduit; EffectorValues nONE = NOISE_POLLUTION.NONE; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(id, width, height, anim, hitpoints, construction_time, tIER, rAW_MINERALS, melting_point, build_location_rule, BUILDINGS.DECOR.NONE, nONE, 0.2f); buildingDef.Deprecated = true; buildingDef.InputConduitType = ConduitType.Gas; buildingDef.OutputConduitType = ConduitType.Gas; buildingDef.Floodable = false; buildingDef.Entombable = false; buildingDef.ViewMode = OverlayModes.GasConduits.ID; buildingDef.AudioCategory = "Metal"; buildingDef.AudioSize = "small"; buildingDef.BaseTimeUntilRepair = -1f; buildingDef.PermittedRotations = PermittedRotations.R360; buildingDef.UtilityInputOffset = new CellOffset(0, 0); buildingDef.UtilityOutputOffset = new CellOffset(1, 0); GeneratedBuildings.RegisterWithOverlay(OverlayScreen.GasVentIDs, buildingDef.PrefabID); return(buildingDef); }
public override BuildingDef CreateBuildingDef() { string id = "Ladder"; int width = 1; int height = 1; string anim = "ladder_kanim"; int hitpoints = 10; float construction_time = 10f; float[] tIER = BUILDINGS.CONSTRUCTION_MASS_KG.TIER2; string[] aLL_MINERALS = MATERIALS.ALL_MINERALS; float melting_point = 1600f; BuildLocationRule build_location_rule = BuildLocationRule.Anywhere; EffectorValues nONE = NOISE_POLLUTION.NONE; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(id, width, height, anim, hitpoints, construction_time, tIER, aLL_MINERALS, melting_point, build_location_rule, BUILDINGS.DECOR.PENALTY.TIER0, nONE, 0.2f); BuildingTemplates.CreateLadderDef(buildingDef); buildingDef.Floodable = false; buildingDef.Overheatable = false; buildingDef.Entombable = false; buildingDef.AudioCategory = "Metal"; buildingDef.AudioSize = "small"; buildingDef.BaseTimeUntilRepair = -1f; buildingDef.DragBuild = true; return(buildingDef); }
public override BuildingDef CreateBuildingDef() { string id = "IncubatorX"; int width = 2; int height = 3; string anim = "incubator_kanim"; int hitpoints = 30; float construction_time = 120f; float[] tieR3 = BUILDINGS.CONSTRUCTION_MASS_KG.TIER3; string[] refinedMetals = MATERIALS.REFINED_METALS; float melting_point = 1600f; BuildLocationRule build_location_rule = BuildLocationRule.Anywhere; EffectorValues none = NOISE_POLLUTION.NONE; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(id, width, height, anim, hitpoints, construction_time, tieR3, refinedMetals, melting_point, build_location_rule, BUILDINGS.DECOR.BONUS.TIER0, none, 0.2f); buildingDef.AudioCategory = "Metal"; buildingDef.RequiresPowerInput = true; buildingDef.EnergyConsumptionWhenActive = 240f; buildingDef.ExhaustKilowattsWhenActive = 0.5f; buildingDef.SelfHeatKilowattsWhenActive = 4f; buildingDef.OverheatTemperature = 363.15f; buildingDef.SceneLayer = Grid.SceneLayer.Building; buildingDef.ForegroundLayer = Grid.SceneLayer.BuildingFront; return(buildingDef); }
// Token: 0x06000037 RID: 55 RVA: 0x00002A34 File Offset: 0x00000C34 public override BuildingDef CreateBuildingDef() { string id = "HeavySmartBattery"; int width = 4; int height = 4; int hitpoints = 75; string anim = "smartbattery_kanim"; float construction_time = 160f; float[] construction_mass = new float[] { (float)ConfigFile.config.heavySmartBatteryCost }; string[] refined_METALS = MATERIALS.REFINED_METALS; float melting_point = 800f; float exhaust_temperature_active = (float)ConfigFile.config.heavySmartBatteryHeatExhaust; float self_heat_kilowatts_active = (float)ConfigFile.config.heavySmartBatterySelfHeat; EffectorValues tier = NOISE_POLLUTION.NOISY.TIER1; BuildingDef buildingDef = base.CreateBuildingDef(id, width, height, hitpoints, anim, construction_time, construction_mass, refined_METALS, melting_point, exhaust_temperature_active, self_heat_kilowatts_active, BUILDINGS.DECOR.PENALTY.TIER3, tier); SoundEventVolumeCache.instance.AddVolume("batterymed_kanim", "Battery_med_rattle", NOISE_POLLUTION.NOISY.TIER2); buildingDef.LogicOutputPorts = new List <LogicPorts.Port> { LogicPorts.Port.OutputPort(BatterySmart.PORT_ID, new CellOffset(0, 0), STRINGS.BUILDINGS.PREFABS.BATTERYSMART.LOGIC_PORT, STRINGS.BUILDINGS.PREFABS.BATTERYSMART.LOGIC_PORT_ACTIVE, STRINGS.BUILDINGS.PREFABS.BATTERYSMART.LOGIC_PORT_INACTIVE, true) }; return(buildingDef); }
public override BuildingDef CreateBuildingDef() { int width = 2; int height = 2; string anim = "icesculpture_kanim"; int hitpoints = 100; float construction_time = 240f; float[] tIER = TUNING.BUILDINGS.CONSTRUCTION_MASS_KG.TIER4; //string[] construction_materials = new string[1] //{ // "Ice" //}; string[] construction_materials = TUNING.MATERIALS.ANY_BUILDABLE; float melting_point = 273.15f; BuildLocationRule build_location_rule = BuildLocationRule.OnFloor; EffectorValues nONE = NOISE_POLLUTION.NONE; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(ID, width, height, anim, hitpoints, construction_time, tIER, construction_materials, melting_point, build_location_rule, new EffectorValues { amount = 10, radius = 10 }, nONE, 0.2f); buildingDef.Floodable = false; buildingDef.Overheatable = false; buildingDef.AudioCategory = "Metal"; buildingDef.BaseTimeUntilRepair = -1f; buildingDef.ViewMode = SimViewMode.Decor; buildingDef.DefaultAnimState = "slab"; return(buildingDef); }
public override BuildingDef CreateBuildingDef() { string id = "COALSCRUBBER"; int wd = 1; int hg = 1; string ani = "co2filter_kanim"; int hp = 100; float const_time = 30f; float[] MyTier = BUILDINGS.CONSTRUCTION_MASS_KG.TIER2; string[] MyMaterial = MATERIALS.ANY_BUILDABLE; float melt_pt = 1600f; BuildLocationRule build_loc_rule = BuildLocationRule.OnFloor; EffectorValues NoiseTier = NOISE_POLLUTION.NOISY.TIER0; EffectorValues MyDecor = BUILDINGS.DECOR.NONE; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(id, wd, hg, ani, hp, const_time, MyTier, MyMaterial, melt_pt, build_loc_rule, MyDecor, NoiseTier); buildingDef.Overheatable = false; buildingDef.RequiresPowerInput = true; buildingDef.EnergyConsumptionWhenActive = 666f; buildingDef.ExhaustKilowattsWhenActive = 0.5f; buildingDef.SelfHeatKilowattsWhenActive = 0f; buildingDef.PermittedRotations = PermittedRotations.R360; buildingDef.UtilityInputOffset = new CellOffset(0, 1); buildingDef.UtilityOutputOffset = new CellOffset(0, 0); buildingDef.Floodable = false; buildingDef.Entombable = true; buildingDef.ViewMode = OverlayModes.Oxygen.ID; buildingDef.AudioCategory = "Metal"; return(buildingDef); }
public override BuildingDef CreateBuildingDef() { int width = 1; int height = 2; string anim = "valvegas_kanim"; int hitpoints = 30; float construction_time = 5f; float[] tIER = BUILDINGS.CONSTRUCTION_MASS_KG.TIER1; string[] rAW_METALS = MATERIALS.ALL_METALS; float melting_point = 1600f; BuildLocationRule build_location_rule = BuildLocationRule.Anywhere; EffectorValues tIER6 = NOISE_POLLUTION.NOISY.TIER0; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(ID, width, height, anim, hitpoints, construction_time, tIER, rAW_METALS, melting_point, build_location_rule, BUILDINGS.DECOR.PENALTY.TIER5, tIER6, 0.2f); buildingDef.InputConduitType = _conduitType; buildingDef.OutputConduitType = ConduitType.None; buildingDef.Floodable = false; buildingDef.ViewMode = _conduitType == ConduitType.Liquid ? OverlayModes.LiquidConduits.ID : OverlayModes.GasConduits.ID; buildingDef.AudioCategory = "Metal"; buildingDef.PermittedRotations = PermittedRotations.R360; buildingDef.UtilityInputOffset = new CellOffset(0, 0); buildingDef.RequiresPowerInput = false; buildingDef.PowerInputOffset = new CellOffset(0, 1); buildingDef.EnergyConsumptionWhenActive = 0f; return(buildingDef); }
public override BuildingDef CreateBuildingDef() { string id = ID; int width = 2; int height = 2; string anim = "pumpgas_kanim"; int hitpoints = 30; float construction_time = 30f; float[] tIER = BUILDINGS.CONSTRUCTION_MASS_KG.TIER1; string[] aLL_METALS = MATERIALS.ALL_METALS; float melting_point = 1600f; BuildLocationRule build_location_rule = BuildLocationRule.Anywhere; EffectorValues tIER2 = NOISE_POLLUTION.NOISY.TIER2; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(id, width, height, anim, hitpoints, construction_time, tIER, aLL_METALS, melting_point, build_location_rule, BUILDINGS.DECOR.PENALTY.TIER1, tIER2, 0.2f); buildingDef.RequiresPowerInput = true; buildingDef.EnergyConsumptionWhenActive = 240f; buildingDef.ExhaustKilowattsWhenActive = 0f; buildingDef.SelfHeatKilowattsWhenActive = 0f; buildingDef.OutputConduitType = ConduitType.Gas; buildingDef.Floodable = true; buildingDef.ViewMode = OverlayModes.GasConduits.ID; buildingDef.AudioCategory = "Metal"; buildingDef.PowerInputOffset = new CellOffset(0, 1); buildingDef.UtilityOutputOffset = new CellOffset(1, 1); return(buildingDef); }
public override BuildingDef CreateBuildingDef() { int width = 1; int height = 1; string anim = "liquid_germs_sensor_kanim"; int hitpoints = 30; float construction_time = 30f; float[] tIER = TUNING.BUILDINGS.CONSTRUCTION_MASS_KG.TIER0; string[] rEFINED_METALS = MATERIALS.REFINED_METALS; float melting_point = 1600f; BuildLocationRule build_location_rule = BuildLocationRule.Anywhere; EffectorValues nONE = NOISE_POLLUTION.NONE; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(ID, width, height, anim, hitpoints, construction_time, tIER, rEFINED_METALS, melting_point, build_location_rule, TUNING.BUILDINGS.DECOR.PENALTY.TIER0, nONE, 0.2f); buildingDef.Overheatable = false; buildingDef.Floodable = false; buildingDef.Entombable = true; buildingDef.ViewMode = OverlayModes.Logic.ID; buildingDef.AudioCategory = "Metal"; buildingDef.SceneLayer = Grid.SceneLayer.Building; SoundEventVolumeCache.instance.AddVolume("switchliquidpressure_kanim", "PowerSwitch_on", NOISE_POLLUTION.NOISY.TIER3); SoundEventVolumeCache.instance.AddVolume("switchliquidpressure_kanim", "PowerSwitch_off", NOISE_POLLUTION.NOISY.TIER3); GeneratedBuildings.RegisterWithOverlay(OverlayModes.Logic.HighlightItemIDs, ID); return(buildingDef); }
public override BuildingDef CreateBuildingDef() { int width = 2; int height = 2; string anim = "painting_kanim"; int hitpoints = BUILDINGS.HITPOINTS.TIER4; float c_time = BUILDINGS.CONSTRUCTION_TIME_SECONDS.TIER0; float[] c_mass = BUILDINGS.CONSTRUCTION_MASS_KG.TIER0; string[] c_mats = MATERIALS.RAW_MINERALS; float melting_point = BUILDINGS.MELTING_POINT_KELVIN.TIER4; BuildLocationRule b_loc = BuildLocationRule.Anywhere; EffectorValues myArt = new EffectorValues() { amount = 220, radius = 50 }; EffectorValues noisy = NOISE_POLLUTION.NONE; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(GetContentBasicInfo().ID, width, height, anim, hitpoints, c_time, c_mass, c_mats, melting_point, b_loc, myArt, noisy, 0.2f); buildingDef.Floodable = false; buildingDef.SceneLayer = Grid.SceneLayer.InteriorWall; buildingDef.Overheatable = false; buildingDef.AudioCategory = "Metal"; buildingDef.BaseTimeUntilRepair = -1f; buildingDef.ViewMode = OverlayModes.Decor.ID; buildingDef.DefaultAnimState = "off"; buildingDef.PermittedRotations = PermittedRotations.FlipH; return(buildingDef); }
public override BuildingDef CreateBuildingDef() { string id = "ManualGenerator"; int width = 2; int height = 2; string anim = "generatormanual_kanim"; int hitpoints = 30; float construction_time = 30f; float[] tIER = BUILDINGS.CONSTRUCTION_MASS_KG.TIER3; string[] aLL_METALS = MATERIALS.ALL_METALS; float melting_point = 1600f; BuildLocationRule build_location_rule = BuildLocationRule.OnFloor; EffectorValues tIER2 = NOISE_POLLUTION.NOISY.TIER3; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(id, width, height, anim, hitpoints, construction_time, tIER, aLL_METALS, melting_point, build_location_rule, BUILDINGS.DECOR.NONE, tIER2, 0.2f); buildingDef.GeneratorWattageRating = 400f; buildingDef.GeneratorBaseCapacity = 10000f; buildingDef.ViewMode = OverlayModes.Power.ID; buildingDef.AudioCategory = "Metal"; buildingDef.Breakable = true; buildingDef.ForegroundLayer = Grid.SceneLayer.BuildingFront; buildingDef.SelfHeatKilowattsWhenActive = 1f; return(buildingDef); }
public GameObject CreatePrefab() { string id = "BeanPlant"; string name = STRINGS.CREATURES.SPECIES.BEAN_PLANT.NAME; string desc = STRINGS.CREATURES.SPECIES.BEAN_PLANT.DESC; float mass = 2f; KAnimFile anim = Assets.GetAnim("beanplant_kanim"); string initialAnim = "idle_empty"; EffectorValues tIER = DECOR.BONUS.TIER1; GameObject gameObject = EntityTemplates.CreatePlacedEntity(id, name, desc, mass, anim, initialAnim, Grid.SceneLayer.BuildingFront, 1, 2, tIER, default(EffectorValues), SimHashes.Creature, null, 258.15f); EntityTemplates.ExtendEntityToBasicPlant(gameObject, 198.15f, 248.15f, 273.15f, 323.15f, null, true, 0f, 0.15f, "BeanPlantSeed", true, true, true, true, 2400f); EntityTemplates.ExtendPlantToIrrigated(gameObject, new PlantElementAbsorber.ConsumeInfo[1] { new PlantElementAbsorber.ConsumeInfo { tag = SimHashes.Ethanol.CreateTag(), massConsumptionRate = 0.0333333351f } }); EntityTemplates.ExtendPlantToFertilizable(gameObject, new PlantElementAbsorber.ConsumeInfo[1] { new PlantElementAbsorber.ConsumeInfo { tag = SimHashes.Dirt.CreateTag(), massConsumptionRate = 0.008333334f } }); PressureVulnerable pressureVulnerable = gameObject.AddOrGet <PressureVulnerable>(); PressureVulnerable pressureVulnerable2 = pressureVulnerable; mass = 0.025f; float pressureLethalLow = 0f; SimHashes[] safeAtmospheres = new SimHashes[1] { SimHashes.CarbonDioxide }; pressureVulnerable2.Configure(mass, pressureLethalLow, 10f, 30f, safeAtmospheres); UprootedMonitor component = gameObject.GetComponent <UprootedMonitor>(); component.monitorCell = new CellOffset(0, -1); gameObject.AddOrGet <StandardCropPlant>(); GameObject plant = gameObject; SeedProducer.ProductionType productionType = SeedProducer.ProductionType.Harvest; initialAnim = "BeanPlantSeed"; desc = STRINGS.CREATURES.SPECIES.SEEDS.BEAN_PLANT.NAME; name = STRINGS.CREATURES.SPECIES.SEEDS.BEAN_PLANT.DESC; anim = Assets.GetAnim("seed_beanplant_kanim"); List <Tag> list = new List <Tag>(); list.Add(GameTags.CropSeed); list = list; GameObject gameObject2 = EntityTemplates.CreateAndRegisterSeedForPlant(plant, productionType, initialAnim, desc, name, anim, "object", 1, list, SingleEntityReceptacle.ReceptacleDirection.Top, default(Tag), 4, STRINGS.CREATURES.SPECIES.BEAN_PLANT.DOMESTICATEDDESC, EntityTemplates.CollisionShape.RECTANGLE, 0.6f, 0.3f, null, string.Empty, false); EntityTemplates.ExtendEntityToFood(gameObject2, FOOD.FOOD_TYPES.BEAN); EntityTemplates.CreateAndRegisterPreviewForPlant(gameObject2, "BeanPlant_preview", Assets.GetAnim("beanplant_kanim"), "place", 1, 2); return(gameObject); }
public override BuildingDef CreateBuildingDef() { string id = ID; int width = 2; int height = 2; string anim = "electrolyzer_kanim"; int hitpoints = 30; float construction_time = 30f; float[] tier = BUILDINGS.CONSTRUCTION_MASS_KG.TIER3; string[] all_metals = MATERIALS.ALL_METALS; float melting_point = 800f; BuildLocationRule build_location_rule = BuildLocationRule.OnFloor; EffectorValues tier2 = NOISE_POLLUTION.NOISY.TIER3; BuildingDef def = BuildingTemplates.CreateBuildingDef(id, width, height, anim, hitpoints, construction_time, tier, all_metals, melting_point, build_location_rule, BUILDINGS.DECOR.PENALTY.TIER1, tier2, 0.2f); def.RequiresPowerInput = true; def.PowerInputOffset = new CellOffset(1, 0); def.EnergyConsumptionWhenActive = 480f; def.ExhaustKilowattsWhenActive = 0.5f; def.SelfHeatKilowattsWhenActive = 1.5f; def.ViewMode = OverlayModes.Oxygen.ID; def.AudioCategory = "HollowMetal"; def.InputConduitType = ConduitType.Liquid; def.UtilityInputOffset = new CellOffset(0, 0); def.OutputConduitType = ConduitType.Gas; def.UtilityOutputOffset = new CellOffset(1, 1); return(def); }
public override BuildingDef CreateBuildingDef() { string id = ID; int width = 1; int height = 2; string anim = "valveliquid_advanced_kanim"; int hitpoints = 30; float construction_time = 30f; float[] tIER = { BUILDINGS.CONSTRUCTION_MASS_KG.TIER2[0], BUILDINGS.CONSTRUCTION_MASS_KG.TIER2[0] }; //100KG, 100KG string[] constructionMaterial = { SimHashes.Steel.ToString(), MATERIALS.PLASTIC }; float melting_point = 1600f; BuildLocationRule build_location_rule = BuildLocationRule.Anywhere; EffectorValues tIER2 = NOISE_POLLUTION.NOISY.TIER1; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(id, width, height, anim, hitpoints, construction_time, tIER, constructionMaterial, melting_point, build_location_rule, BUILDINGS.DECOR.PENALTY.TIER0, tIER2); buildingDef.InputConduitType = CONDUIT_TYPE; buildingDef.OutputConduitType = CONDUIT_TYPE; buildingDef.Floodable = false; buildingDef.ViewMode = OverlayModes.LiquidConduits.ID; buildingDef.AudioCategory = "Metal"; buildingDef.PermittedRotations = PermittedRotations.R360; buildingDef.UtilityInputOffset = new CellOffset(0, 0); buildingDef.UtilityOutputOffset = new CellOffset(0, 1); return(buildingDef); }
private void InitalizeEffectors() { if (provider == null) { provider = this.gameObject.GetComponent <DecorProvider>(); if (provider == null) { return; } } if (initialEffector.amount == 0) { initialEffector = new EffectorValues() { amount = (int)provider.baseDecor, radius = (int)provider.baseRadius } } ; if (bonusEffector.amount == 0) { bonusEffector = new EffectorValues() { amount = (int)((1 + BonusScale) * initialEffector.amount), radius = (int)((1 + BonusScale) * initialEffector.radius) } } ; }
public override BuildingDef CreateBuildingDef() { string id = "RustDeoxidizer"; int width = 2; int height = 3; string anim = "rust_deoxidizer_kanim"; int hitpoints = 30; float construction_time = 30f; float[] tIER = BUILDINGS.CONSTRUCTION_MASS_KG.TIER3; string[] aLL_METALS = MATERIALS.ALL_METALS; float melting_point = 800f; BuildLocationRule build_location_rule = BuildLocationRule.OnFloor; EffectorValues tIER2 = NOISE_POLLUTION.NOISY.TIER3; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(id, width, height, anim, hitpoints, construction_time, tIER, aLL_METALS, melting_point, build_location_rule, BUILDINGS.DECOR.PENALTY.TIER1, tIER2, 0.2f); buildingDef.RequiresPowerInput = true; buildingDef.PowerInputOffset = new CellOffset(1, 0); buildingDef.EnergyConsumptionWhenActive = 60f; buildingDef.ExhaustKilowattsWhenActive = 0.125f; buildingDef.SelfHeatKilowattsWhenActive = 1f; buildingDef.ViewMode = OverlayModes.Oxygen.ID; buildingDef.AudioCategory = "HollowMetal"; return(buildingDef); }
public override BuildingDef CreateBuildingDef() { Debug.Log(" === InsulatedPressureDoorConfig INI === "); string id = "InsulatedPressureDoor"; int width = 1; int height = 2; string anim = "door_external_kanim"; int hitpoints = 30; float construction_time = 60f; float[] tIER = TUNING.BUILDINGS.CONSTRUCTION_MASS_KG.TIER4; string[] aLL_METALS = MATERIALS.ANY_BUILDABLE; float melting_point = 1600f; BuildLocationRule build_location_rule = BuildLocationRule.Tile; EffectorValues nONE = NOISE_POLLUTION.NONE; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(id, width, height, anim, hitpoints, construction_time, tIER, aLL_METALS, melting_point, build_location_rule, TUNING.BUILDINGS.DECOR.PENALTY.TIER1, nONE, 0.2f); //buildingDef.Insulation = 0.01f; buildingDef.ThermalConductivity = 0.01f; buildingDef.Overheatable = false; buildingDef.RequiresPowerInput = true; //buildingDef.UseStructureTemperature = false; buildingDef.EnergyConsumptionWhenActive = 120f; buildingDef.Entombable = false; buildingDef.IsFoundation = true; buildingDef.ViewMode = SimViewMode.PowerMap; buildingDef.TileLayer = ObjectLayer.FoundationTile; buildingDef.MaterialCategory = MATERIALS.ANY_BUILDABLE; buildingDef.AudioCategory = "Metal"; buildingDef.PermittedRotations = PermittedRotations.R90; buildingDef.SceneLayer = Grid.SceneLayer.TileMain; SoundEventVolumeCache.instance.AddVolume("door_external_kanim", "Open_DoorPressure", NOISE_POLLUTION.NOISY.TIER2); SoundEventVolumeCache.instance.AddVolume("door_external_kanim", "Close_DoorPressure", NOISE_POLLUTION.NOISY.TIER2); return(buildingDef); }
public override BuildingDef CreateBuildingDef() { string id = "PressureGasPump"; int width = 2; int height = 2; string anim = "pumpgas_kanim"; int hitpoints = 30; float construction_time = 150f; float[] tieR1 = TUNING.BUILDINGS.CONSTRUCTION_MASS_KG.TIER1; string[] allMetals = new string[1] { SimHashes.Steel.ToString() }; float melting_point = 1600f; BuildLocationRule build_location_rule = BuildLocationRule.Anywhere; EffectorValues tieR2 = TUNING.NOISE_POLLUTION.NOISY.TIER2; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(id, width, height, anim, hitpoints, construction_time, tieR1, allMetals, melting_point, build_location_rule, TUNING.BUILDINGS.DECOR.PENALTY.TIER1, tieR2, 0.2f); buildingDef.RequiresPowerInput = true; buildingDef.EnergyConsumptionWhenActive = 490f; buildingDef.ExhaustKilowattsWhenActive = 0.0f; buildingDef.SelfHeatKilowattsWhenActive = 0.0f; buildingDef.OutputConduitType = ConduitType.Gas; buildingDef.Floodable = true; buildingDef.ViewMode = OverlayModes.GasConduits.ID; buildingDef.AudioCategory = "Metal"; buildingDef.PowerInputOffset = new CellOffset(0, 1); buildingDef.UtilityOutputOffset = new CellOffset(1, 1); return(buildingDef); }
public override BuildingDef CreateBuildingDef() { string id = "SteelLadder"; int width = 1; int height = 1; string anim = "ladder_poi_kanim"; int hitpoints = 10; float construction_time = 10f; float[] construction_mass = new float[] { BUILDINGS.CONSTRUCTION_MASS_KG.TIER0[0] }; string[] construction_materials = new string[] { SimHashes.Steel.ToString() }; float melting_point = 1600f; BuildLocationRule build_location_rule = BuildLocationRule.Anywhere; EffectorValues none = NOISE_POLLUTION.NONE; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(id, width, height, anim, hitpoints, construction_time, construction_mass, construction_materials, melting_point, build_location_rule, BUILDINGS.DECOR.PENALTY.TIER0, none, 0.2f); buildingDef.Floodable = false; buildingDef.Overheatable = false; buildingDef.Entombable = false; buildingDef.AudioCategory = "Plastic"; buildingDef.AudioSize = "small"; buildingDef.BaseTimeUntilRepair = -1f; buildingDef.DragBuild = true; return(buildingDef); }
public override BuildingDef CreateBuildingDef() { string id = EggsSensorConfig.ID; int width = 1; int height = 1; string anim = "switchtimeofday_kanim"; int hitpoints = 30; float construction_time = 30f; float[] construction_mass = BUILDINGS.CONSTRUCTION_MASS_KG.TIER1; string[] construction_materials = MATERIALS.REFINED_METALS; float melting_point = 1600f; BuildLocationRule build_location_rule = BuildLocationRule.Anywhere; EffectorValues none = NOISE_POLLUTION.NONE; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(id, width, height, anim, hitpoints, construction_time, construction_mass, construction_materials, melting_point, build_location_rule, BUILDINGS.DECOR.PENALTY.TIER0, none, 0.2f); buildingDef.Overheatable = false; buildingDef.Floodable = false; buildingDef.Entombable = false; buildingDef.ViewMode = SimViewMode.Logic; buildingDef.AudioCategory = "Metal"; buildingDef.SceneLayer = Grid.SceneLayer.Building; SoundEventVolumeCache.instance.AddVolume("switchgaspressure_kanim", "PowerSwitch_on", NOISE_POLLUTION.NOISY.TIER3); SoundEventVolumeCache.instance.AddVolume("switchgaspressure_kanim", "PowerSwitch_off", NOISE_POLLUTION.NOISY.TIER3); GeneratedBuildings.RegisterWithOverlay(Logic.HighlightItemIDs, EggsSensorConfig.ID); return(buildingDef); }
public override BuildingDef CreateBuildingDef() { string id = "LiquidConditioner"; int width = 2; int height = 2; string anim = "liquidconditioner_kanim"; int hitpoints = 100; float construction_time = 120f; float[] tIER = BUILDINGS.CONSTRUCTION_MASS_KG.TIER6; string[] aLL_METALS = MATERIALS.ALL_METALS; float melting_point = 1600f; BuildLocationRule build_location_rule = BuildLocationRule.OnFloor; EffectorValues tIER2 = NOISE_POLLUTION.NOISY.TIER2; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(id, width, height, anim, hitpoints, construction_time, tIER, aLL_METALS, melting_point, build_location_rule, BUILDINGS.DECOR.NONE, tIER2, 0.2f); BuildingTemplates.CreateElectricalBuildingDef(buildingDef); buildingDef.EnergyConsumptionWhenActive = 1200f; buildingDef.SelfHeatKilowattsWhenActive = 0f; buildingDef.InputConduitType = ConduitType.Liquid; buildingDef.OutputConduitType = ConduitType.Liquid; buildingDef.Floodable = false; buildingDef.PowerInputOffset = new CellOffset(1, 0); buildingDef.UtilityInputOffset = new CellOffset(0, 0); buildingDef.PermittedRotations = PermittedRotations.FlipH; buildingDef.ViewMode = OverlayModes.LiquidConduits.ID; buildingDef.OverheatTemperature = 398.15f; return(buildingDef); }
public override BuildingDef CreateBuildingDef() { string id = "RadiumFuelCell"; int width = 1; int height = 1; string anim = "thermalblock_kanim"; int hitpoints = 30; float construction_time = 120f; float[] tieR5 = BUILDINGS.CONSTRUCTION_MASS_KG.TIER5; string[] anyBuildable = new string[1] { "Radium" }; float melting_point = 8000f; BuildLocationRule build_location_rule = BuildLocationRule.NotInTiles; EffectorValues none = NOISE_POLLUTION.NONE; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(id, width, height, anim, hitpoints, construction_time, tieR5, anyBuildable, melting_point, build_location_rule, DECOR.NONE, none, 0.2f); buildingDef.Floodable = false; buildingDef.Overheatable = false; buildingDef.AudioCategory = "Metal"; buildingDef.BaseTimeUntilRepair = -1f; buildingDef.ViewMode = SimViewMode.TemperatureMap; buildingDef.DefaultAnimState = "off"; buildingDef.ObjectLayer = ObjectLayer.Backwall; buildingDef.SceneLayer = Grid.SceneLayer.TempShiftPlate; return(buildingDef); }
public override BuildingDef CreateBuildingDef() { string id = "MethaneGenerator"; int width = 4; int height = 3; string anim = "generatormethane_kanim"; int hitpoints = 100; float construction_time = 120f; float[] tIER = BUILDINGS.CONSTRUCTION_MASS_KG.TIER5; string[] rAW_METALS = MATERIALS.RAW_METALS; float melting_point = 2400f; BuildLocationRule build_location_rule = BuildLocationRule.OnFloor; EffectorValues tIER2 = NOISE_POLLUTION.NOISY.TIER5; BuildingDef buildingDef = BuildingTemplates.CreateBuildingDef(id, width, height, anim, hitpoints, construction_time, tIER, rAW_METALS, melting_point, build_location_rule, BUILDINGS.DECOR.PENALTY.TIER2, tIER2, 0.2f); buildingDef.GeneratorWattageRating = 800f; buildingDef.GeneratorBaseCapacity = 1000f; buildingDef.ExhaustKilowattsWhenActive = 2f; buildingDef.SelfHeatKilowattsWhenActive = 8f; buildingDef.ViewMode = OverlayModes.Power.ID; buildingDef.AudioCategory = "Metal"; buildingDef.UtilityInputOffset = new CellOffset(0, 0); buildingDef.UtilityOutputOffset = new CellOffset(2, 2); buildingDef.PowerOutputOffset = new CellOffset(0, 0); buildingDef.InputConduitType = ConduitType.Gas; buildingDef.OutputConduitType = ConduitType.Gas; return(buildingDef); }