Revisit noise values

This commit is contained in:
Simon Brodtmann 2026-01-05 14:56:23 +01:00
parent 82ea32b7e2
commit 6563753a8d
11 changed files with 137 additions and 54 deletions

View file

@ -93,6 +93,8 @@ stone-wall=Better acoustic and physical protection than the wooden counterpart.
gold-stromatolite-seed=Plant the seed to grow gold stromatolites. They house bacteria that enrich gold from the ground.\n__REMARK_COLOR_BEGIN__Expected yield:__REMARK_COLOR_END__ 1.5 [item=gold-ore]/m gold-stromatolite-seed=Plant the seed to grow gold stromatolites. They house bacteria that enrich gold from the ground.\n__REMARK_COLOR_BEGIN__Expected yield:__REMARK_COLOR_END__ 1.5 [item=gold-ore]/m
steam-science-pack-spoiled=Spoiled steam science pack. Put it in a furnace to bring it to the right temperature. steam-science-pack-spoiled=Spoiled steam science pack. Put it in a furnace to bring it to the right temperature.
gold-module-3=When you mastered quality assembling, this pristine module is unlocked, enabling you to craft the finest items available. gold-module-3=When you mastered quality assembling, this pristine module is unlocked, enabling you to craft the finest items available.
produces-noise=Produces __1__ noise/m
consumes-noise=Consumes __1__ noise/m
[fluid-name] [fluid-name]
wood-pulp=Wood pulp wood-pulp=Wood pulp

View file

@ -17,8 +17,7 @@ agricultural_tower.energy_source = {
type = "burner", type = "burner",
fuel_categories = { "chemical" }, fuel_categories = { "chemical" },
effectivity = 1, effectivity = 1,
fuel_inventory_size = 1, fuel_inventory_size = 1
emissions_per_minute = { noise = 75 }
} }
agricultural_tower.resistances = nil agricultural_tower.resistances = nil
agricultural_tower.input_inventory_size = 1 agricultural_tower.input_inventory_size = 1

View file

@ -27,7 +27,6 @@ assembling_machine.energy_source = {
fuel_categories = { "chemical" }, fuel_categories = { "chemical" },
effectivity = 1, effectivity = 1,
fuel_inventory_size = 1, fuel_inventory_size = 1,
emissions_per_minute = { noise = 50, pollution = 6 },
smoke = { smoke = {
{ {
name = "smoke", name = "smoke",

View file

@ -59,8 +59,7 @@ data:extend({
resource_drain_rate_percent = 75, resource_drain_rate_percent = 75,
energy_source = { energy_source = {
type = "electric", type = "electric",
usage_priority = "secondary-input", usage_priority = "secondary-input"
emissions_per_minute = { noise = 2000 }
}, },
energy_usage = "25MW", energy_usage = "25MW",
perceived_performance = { minimum = 0.25, performance_to_activity_rate = 0.25, maximum = 2 }, perceived_performance = { minimum = 0.25, performance_to_activity_rate = 0.25, maximum = 2 },

View file

@ -24,13 +24,12 @@ end
local energy_source = electric_lumber_mill and { local energy_source = electric_lumber_mill and {
type = "electric", type = "electric",
usage_priority = "secondary-input", usage_priority = "secondary-input",
emissions_per_minute = { noise = 100 }
} or { } or {
type = "burner", type = "burner",
fuel_categories = { "chemical" }, fuel_categories = { "chemical" },
effectivity = 1, effectivity = 1,
fuel_inventory_size = 3, fuel_inventory_size = 3,
emissions_per_minute = { pollution = 10, noise = 100 } emissions_per_minute = { pollution = 10 }
} }
data:extend({ data:extend({

View file

@ -1,16 +1,33 @@
-- Entities added by Lignumis define noise emissions/absorption in their own file. -- Entities added by Lignumis define noise emissions/absorption in their own file.
local function add_description(prototype, amount)
if prototype and not prototype.localised_description then
if amount > 0 then
prototype.localised_description = { "item-description.produces-noise", tostring(amount) }
else
prototype.localised_description = { "item-description.consumes-noise", tostring(amount * -1) }
end
end
end
local function emit(type, name, amount) local function emit(type, name, amount)
local entity = data.raw[type][name] local entity = data.raw[type][name]
entity.energy_source = entity.energy_source or {} if entity and entity.energy_source then
entity.energy_source.emissions_per_minute = entity.energy_source.emissions_per_minute or {} entity.energy_source.emissions_per_minute = entity.energy_source.emissions_per_minute or {}
entity.energy_source.emissions_per_minute.noise = amount entity.energy_source.emissions_per_minute.noise = amount
end end
end
local function emit_constant(type, name, amount) local function emit_constant(type, name, amount)
local entity = data.raw[type][name] local entity = data.raw[type][name]
local item = data.raw.item[name]
if entity then
entity.emissions_per_second = entity.emissions_per_second or {} entity.emissions_per_second = entity.emissions_per_second or {}
entity.emissions_per_second.noise = amount / 60 entity.emissions_per_second.noise = amount / 60
add_description(entity, amount)
add_description(item, amount)
end
end end
data:extend({ data:extend({
@ -72,46 +89,120 @@ emit_constant("gate", "gate", -30)
-- Buildings emit noise -- Buildings emit noise
emit("furnace", "stone-furnace", 10) -- Belts
emit("furnace", "electric-furnace", 10) emit_constant("transport-belt", "wood-transport-belt", 2)
emit("mining-drill", "burner-mining-drill", 50) emit_constant("transport-belt", "transport-belt", 2.5)
emit("mining-drill", "electric-mining-drill", 100) emit_constant("transport-belt", "fast-transport-belt", 3)
emit("mining-drill", "big-mining-drill", 200) emit_constant("transport-belt", "express-transport-belt", 4)
--emit("mining-drill", "deep-miner", 2000) emit_constant("transport-belt", "turbo-transport-belt", 6)
--emit("agricultural-tower", "burner-agricultural-tower", 75) emit_constant("underground-belt", "wood-underground-belt", 4)
emit("agricultural-tower", "agricultural-tower", 75) emit_constant("underground-belt", "underground-belt", 5)
--emit("assembling-machine", "burner-assembling-machine", 50) emit_constant("underground-belt", "fast-underground-belt", 6)
--emit("assembling-machine", "steam-assembling-machine", 50) emit_constant("underground-belt", "express-underground-belt", 8)
emit("assembling-machine", "assembling-machine-1", 10) emit_constant("underground-belt", "turbo-underground-belt", 12)
emit("assembling-machine", "assembling-machine-2", 15) emit_constant("splitter", "wood-splitter", 10)
emit("assembling-machine", "assembling-machine-3", 20) emit_constant("splitter", "splitter", 12.5)
emit("assembling-machine", "chemical-plant", 10) emit_constant("splitter", "fast-splitter", 15)
emit_constant("splitter", "express-splitter", 20)
emit_constant("splitter", "turbo-splitter", 30)
-- Electricity
emit("boiler", "boiler", 5) emit("boiler", "boiler", 5)
emit("generator", "steam-engine", 10) emit("generator", "steam-engine", 10)
emit("boiler", "heat-exchanger", 1) emit("boiler", "heat-exchanger", 1)
emit("generator", "steam-turbine", 20) emit("generator", "steam-turbine", 20)
--emit("rocket-silo", "provisional-rocket-silo", 10000) emit("reactor", "nuclear-reactor", 20)
--emit_constant("rocket-silo", "provisional-rocket-silo", 1000) emit("fusion-generator", "fusion-generator", 50)
emit("rocket-silo", "rocket-silo", 10000) emit("fusion-reactor", "fusion-reactor", 50)
emit_constant("rocket-silo", "rocket-silo", 1000) emit("reactor", "heating-tower", 10)
--emit("lab", "wood-lab", 10)
-- Mining drills
emit("mining-drill", "burner-mining-drill", 50)
emit("mining-drill", "electric-mining-drill", 100)
emit("mining-drill", "big-mining-drill", 200)
emit("mining-drill", "deep-miner", 2000)
-- Furnaces and assembling machines
emit("furnace", "stone-furnace", 20)
emit("furnace", "desiccation-furnace", 20)
emit("furnace", "electric-furnace", 20)
emit("assembling-machine", "foundry", 100)
emit("furnace", "recylcer", 40)
emit("agricultural-tower", "burner-agricultural-tower", 50)
emit("agricultural-tower", "agricultural-tower", 50)
emit("assembling-machine", "biochamber", 20)
emit("assembling-machine", "burner-assembling-machine", 40)
emit("assembling-machine", "steam-assembling-machine", 40)
emit("assembling-machine", "assembling-machine-1", 20)
emit("assembling-machine", "assembling-machine-2", 40)
emit("assembling-machine", "assembling-machine-3", 60)
emit("assembling-machine", "chemical-plant", 20)
emit("assembling-machine", "lumber-mill", 100)
emit("assembling-machine", "electromagnetic-plant", 75)
emit("lab", "wood-lab", 10)
emit("lab", "lab", 5) emit("lab", "lab", 5)
emit("lab", "biolab", 20) emit("lab", "biolab", 20)
emit("assembling-machine", "quality-assembler", 60)
-- Misc stuff
emit("rocket-silo", "provisional-rocket-silo", 10000)
emit_constant("rocket-silo", "provisional-rocket-silo", 1000)
emit("rocket-silo", "rocket-silo", 10000)
emit_constant("rocket-silo", "rocket-silo", 1000)
emit("locomotive", "locomotive", 200) emit("locomotive", "locomotive", 200)
emit_constant("locomotive", "locomotive", 10) emit_constant("locomotive", "locomotive", 10)
emit_constant("transport-belt", "wood-transport-belt", 2)
emit_constant("transport-belt", "transport-belt", 3) -- Mods
emit_constant("transport-belt", "fast-transport-belt", 4)
emit_constant("transport-belt", "express-transport-belt", 6) -- Loaders
emit_constant("transport-belt", "turbo-transport-belt", 8) emit_constant("loader-1x1", "aai-wood-loader", 10)
emit_constant("underground-belt", "wood-underground-belt", 7.5) emit_constant("loader-1x1", "aai-loader", 12.5)
emit_constant("underground-belt", "underground-belt", 10) emit_constant("loader-1x1", "aai-fast-loader", 15)
emit_constant("underground-belt", "fast-underground-belt", 20) emit_constant("loader-1x1", "aai-express-loader", 20)
emit_constant("underground-belt", "express-underground-belt", 30) emit_constant("loader-1x1", "aai-turbo-loader", 30)
emit_constant("underground-belt", "turbo-underground-belt", 40)
emit_constant("splitter", "wood-splitter", 20) -- AAI Industry
emit_constant("splitter", "splitter", 30) emit("burner-generator", "burner-turbine", 20)
emit_constant("splitter", "fast-splitter", 40) emit("assembling-machine", "fuel-processor", 40)
emit_constant("splitter", "express-splitter", 50)
emit_constant("splitter", "turbo-splitter", 60) -- Canal excavator
emit("mining-drill", "canex-excavator", 200)
-- Crushing Industry
emit("furnace", "burner-crusher", 100)
emit("furnace", "electric-crusher", 100)
emit("assembling-machine", "big-crusher", 200)
-- Wooden Industry
emit("furnace", "brick-kiln", 20)
emit("furnace", "electric-kiln", 20)
-- Advanced belts
emit_constant("transport-belt", "extreme-transport-belt", 8)
emit_constant("transport-belt", "ultimate-transport-belt", 10)
emit_constant("transport-belt", "high-speed-transport-belt", 12)
emit_constant("underground-belt", "extreme-underground-belt", 16)
emit_constant("underground-belt", "ultimate-underground-belt", 20)
emit_constant("underground-belt", "high-speed-underground-belt", 24)
emit_constant("splitter", "extreme-splitter", 40)
emit_constant("splitter", "ultimate-splitter", 50)
emit_constant("splitter", "high-speed-splitter", 60)
emit_constant("loader-1x1", "aai-extreme-loader", 40)
emit_constant("loader-1x1", "aai-ultimate-loader", 50)
emit_constant("loader-1x1", "aai-high-speed-loader", 60)
-- Castra
emit_constant("transport-belt", "military-transport-belt", 4)
emit_constant("underground-belt", "military-underground-belt", 8)
emit_constant("splitter", "military-splitter", 20)
emit("assembling-machine", "forge", 80)
emit_constant("wall", "carbon-fiber-wall", -80)
-- Arig
emit_constant("transport-belt", "planetaris-hyper-transport-belt", 7)
emit_constant("underground-belt", "planetaris-hyper-underground-belt", 14)
emit_constant("splitter", "planetaris-hyper-splitter", 35)
-- Rubia
emit_constant("wall", "craptonite-wall", -60)

View file

@ -143,7 +143,7 @@ data:extend({
fuel_categories = { "quality-catalyst" }, fuel_categories = { "quality-catalyst" },
effectivity = 1, effectivity = 1,
fuel_inventory_size = 1, fuel_inventory_size = 1,
emissions_per_minute = { noise = 100, pollution = 6 }, emissions_per_minute = { pollution = 6 },
}, },
energy_usage = "1MW", energy_usage = "1MW",
heating_energy = "200kW", heating_energy = "200kW",

View file

@ -33,7 +33,6 @@ assembling_machine.energy_source = {
maximum_temperature = 165, maximum_temperature = 165,
scale_fluid_usage = true, scale_fluid_usage = true,
effectivity = 1, effectivity = 1,
emissions_per_minute = { noise = 50 },
fluid_box = { fluid_box = {
filter = "steam", filter = "steam",
production_type = "input", production_type = "input",

View file

@ -105,7 +105,7 @@ data:extend({
fuel_categories = { "chemical" }, fuel_categories = { "chemical" },
effectivity = 1, effectivity = 1,
fuel_inventory_size = 1, fuel_inventory_size = 1,
emissions_per_minute = { pollution = 12, noise = 10 }, emissions_per_minute = { pollution = 12 },
light_flicker = { color = { 0, 0, 0 } }, light_flicker = { color = { 0, 0, 0 } },
smoke = { smoke = {
{ {

View file

@ -46,7 +46,6 @@ data:extend({
percent = 90 percent = 90
} }
}, },
emissions_per_second = { noise = 2 / 60 },
collision_box = { { -0.4, -0.4 }, { 0.4, 0.4 } }, collision_box = { { -0.4, -0.4 }, { 0.4, 0.4 } },
selection_box = { { -0.5, -0.5 }, { 0.5, 0.5 } }, selection_box = { { -0.5, -0.5 }, { 0.5, 0.5 } },
damaged_trigger_effect = hit_effects.entity(), damaged_trigger_effect = hit_effects.entity(),
@ -127,7 +126,6 @@ data:extend({
percent = 30 percent = 30
} }
}, },
emissions_per_second = { noise = 7.5 / 60 },
collision_box = { { -0.4, -0.4 }, { 0.4, 0.4 } }, collision_box = { { -0.4, -0.4 }, { 0.4, 0.4 } },
selection_box = { { -0.5, -0.5 }, { 0.5, 0.5 } }, selection_box = { { -0.5, -0.5 }, { 0.5, 0.5 } },
damaged_trigger_effect = hit_effects.entity(), damaged_trigger_effect = hit_effects.entity(),
@ -239,7 +237,6 @@ data:extend({
percent = 60 percent = 60
} }
}, },
emissions_per_second = { noise = 20 / 60 },
collision_box = { { -0.9, -0.4 }, { 0.9, 0.4 } }, collision_box = { { -0.9, -0.4 }, { 0.9, 0.4 } },
selection_box = { { -0.9, -0.5 }, { 0.9, 0.5 } }, selection_box = { { -0.9, -0.5 }, { 0.9, 0.5 } },
damaged_trigger_effect = hit_effects.entity(), damaged_trigger_effect = hit_effects.entity(),

View file

@ -15,7 +15,6 @@ silo.energy_source = {
fuel_categories = { "chemical" }, fuel_categories = { "chemical" },
effectivity = 1, effectivity = 1,
fuel_inventory_size = 1, fuel_inventory_size = 1,
emissions_per_minute = { noise = 10000 },
smoke = { smoke = {
{ {
name = "smoke", name = "smoke",
@ -27,7 +26,6 @@ silo.energy_source = {
} }
} }
} }
silo.emissions_per_second = { noise = 1000 / 60 }
silo.energy_usage = "1MW" silo.energy_usage = "1MW"
silo.rocket_entity = "provisional-rocket" silo.rocket_entity = "provisional-rocket"
silo.fixed_recipe = "provisional-rocket-part" silo.fixed_recipe = "provisional-rocket-part"