diff --git a/code/ATMOSPHERICS/components/binary_devices/dp_vent_pump.dm b/code/ATMOSPHERICS/components/binary_devices/dp_vent_pump.dm index 8cee350a26..e3df72628c 100644 --- a/code/ATMOSPHERICS/components/binary_devices/dp_vent_pump.dm +++ b/code/ATMOSPHERICS/components/binary_devices/dp_vent_pump.dm @@ -45,6 +45,8 @@ /obj/machinery/atmospherics/binary/dp_vent_pump/New() ..() + air1.volume = ATMOS_DEFAULT_VOLUME_PUMP + air2.volume = ATMOS_DEFAULT_VOLUME_PUMP icon = null /obj/machinery/atmospherics/binary/dp_vent_pump/high_volume @@ -52,8 +54,8 @@ /obj/machinery/atmospherics/binary/dp_vent_pump/high_volume/New() ..() - air1.volume = 1000 - air2.volume = 1000 + air1.volume = ATMOS_DEFAULT_VOLUME_PUMP + 800 + air2.volume = ATMOS_DEFAULT_VOLUME_PUMP + 800 /obj/machinery/atmospherics/binary/dp_vent_pump/update_icon(var/safety = 0) if(!check_icon_cache()) diff --git a/code/ATMOSPHERICS/components/binary_devices/pump.dm b/code/ATMOSPHERICS/components/binary_devices/pump.dm index f891a5aa5e..b684232706 100644 --- a/code/ATMOSPHERICS/components/binary_devices/pump.dm +++ b/code/ATMOSPHERICS/components/binary_devices/pump.dm @@ -36,6 +36,11 @@ Thus, the two variables affect pump operation are set in New(): var/id = null var/datum/radio_frequency/radio_connection +/obj/machinery/atmospherics/binary/pump/New() + ..() + air1.volume = ATMOS_DEFAULT_VOLUME_PUMP + air2.volume = ATMOS_DEFAULT_VOLUME_PUMP + /obj/machinery/atmospherics/binary/pump/on icon_state = "map_on" on = 1 diff --git a/code/ATMOSPHERICS/components/omni_devices/filter.dm b/code/ATMOSPHERICS/components/omni_devices/filter.dm index 2f4c9c509e..8f4c334da2 100644 --- a/code/ATMOSPHERICS/components/omni_devices/filter.dm +++ b/code/ATMOSPHERICS/components/omni_devices/filter.dm @@ -21,6 +21,8 @@ /obj/machinery/atmospherics/omni/filter/New() ..() rebuild_filtering_list() + for(var/datum/omni_port/P in ports) + P.air.volume = ATMOS_DEFAULT_VOLUME_FILTER /obj/machinery/atmospherics/omni/filter/Del() input = null diff --git a/code/ATMOSPHERICS/components/omni_devices/mixer.dm b/code/ATMOSPHERICS/components/omni_devices/mixer.dm index 6e037f57a2..171eaa254a 100644 --- a/code/ATMOSPHERICS/components/omni_devices/mixer.dm +++ b/code/ATMOSPHERICS/components/omni_devices/mixer.dm @@ -45,6 +45,9 @@ if(tag_west_con && tag_west == 1) P.concentration = tag_west_con con += max(0, tag_west_con) + + for(var/datum/omni_port/P in ports) + P.air.volume = ATMOS_DEFAULT_VOLUME_MIXER rebuild_mixing_inputs() @@ -61,7 +64,6 @@ if(inputs.Find(P)) inputs -= P - P.air.volume = 200 switch(P.mode) if(ATM_INPUT) inputs += P @@ -73,7 +75,7 @@ P.concentration = 1 / max(1, inputs.len) if(output) - output.air.volume = 200 * 0.75 * inputs.len + output.air.volume = ATMOS_DEFAULT_VOLUME_MIXER * 0.75 * inputs.len output.concentration = 1 /obj/machinery/atmospherics/omni/mixer/proc/mapper_set() diff --git a/code/ATMOSPHERICS/components/trinary_devices/filter.dm b/code/ATMOSPHERICS/components/trinary_devices/filter.dm index 5dc5f41c12..89e6ce94d3 100755 --- a/code/ATMOSPHERICS/components/trinary_devices/filter.dm +++ b/code/ATMOSPHERICS/components/trinary_devices/filter.dm @@ -12,8 +12,7 @@ var/temp = null // -- TLE - var/max_flow_rate = 200 //L/s - var/set_flow_rate = 200 + var/set_flow_rate = ATMOS_DEFAULT_VOLUME_FILTER /* Filter types: @@ -39,6 +38,10 @@ /obj/machinery/atmospherics/trinary/filter/New() ..() + air1.volume = ATMOS_DEFAULT_VOLUME_FILTER + air2.volume = ATMOS_DEFAULT_VOLUME_FILTER + air3.volume = ATMOS_DEFAULT_VOLUME_FILTER + if(radio_controller) initialize() @@ -217,8 +220,8 @@ if (href_list["temp"]) src.temp = null if(href_list["set_flow_rate"]) - var/new_pressure = input(usr,"Enter new flow rate (0-[max_flow_rate]L/s)","Flow Rate Control",src.set_flow_rate) as num - src.set_flow_rate = max(0, min(max_flow_rate, new_pressure)) + var/new_flow_rate = input(usr,"Enter new flow rate (0-[air1.volume]L/s)","Flow Rate Control",src.set_flow_rate) as num + src.set_flow_rate = max(0, min(air1.volume, new_flow_rate)) if(href_list["power"]) on=!on src.update_icon() diff --git a/code/ATMOSPHERICS/components/trinary_devices/mixer.dm b/code/ATMOSPHERICS/components/trinary_devices/mixer.dm index 5ecde80934..7684f7e9d5 100644 --- a/code/ATMOSPHERICS/components/trinary_devices/mixer.dm +++ b/code/ATMOSPHERICS/components/trinary_devices/mixer.dm @@ -10,8 +10,7 @@ idle_power_usage = 150 //internal circuitry, friction losses and stuff active_power_usage = 3700 //This also doubles as a measure of how powerful the mixer is, in Watts. 3700 W ~ 5 HP - var/max_flow_rate = 200 //L/s - var/set_flow_rate = 200 + var/set_flow_rate = ATMOS_DEFAULT_VOLUME_MIXER var/list/mixing_inputs //for mapping @@ -66,7 +65,9 @@ /obj/machinery/atmospherics/trinary/mixer/New() ..() - air3.volume = 300 + air1.volume = ATMOS_DEFAULT_VOLUME_MIXER + air2.volume = ATMOS_DEFAULT_VOLUME_MIXER + air3.volume = ATMOS_DEFAULT_VOLUME_MIXER * 1.5 /obj/machinery/atmospherics/trinary/mixer/process() ..() @@ -162,6 +163,7 @@ if(href_list["power"]) on = !on if(href_list["set_press"]) + var/max_flow_rate = min(air1.volume, air2.volume) var/new_flow_rate = input(usr,"Enter new flow rate limit (0-[max_flow_rate]L/s)","Flow Rate Control",src.set_flow_rate) as num src.set_flow_rate = max(0, min(max_flow_rate, new_flow_rate)) if(href_list["node1_c"]) diff --git a/code/ATMOSPHERICS/components/unary/vent_pump.dm b/code/ATMOSPHERICS/components/unary/vent_pump.dm index 04b8a37977..3948addde6 100644 --- a/code/ATMOSPHERICS/components/unary/vent_pump.dm +++ b/code/ATMOSPHERICS/components/unary/vent_pump.dm @@ -62,6 +62,9 @@ icon_state = "map_vent_in" /obj/machinery/atmospherics/unary/vent_pump/New() + ..() + air_contents.volume = ATMOS_DEFAULT_VOLUME_PUMP + icon = null initial_loc = get_area(loc) if (initial_loc.master) @@ -73,7 +76,6 @@ if(ticker && ticker.current_state == 3)//if the game is running src.initialize() src.broadcast_status() - ..() /obj/machinery/atmospherics/unary/vent_pump/high_volume name = "Large Air Vent" @@ -81,7 +83,7 @@ /obj/machinery/atmospherics/unary/vent_pump/high_volume/New() ..() - air_contents.volume = 1000 + air_contents.volume = ATMOS_DEFAULT_VOLUME_PUMP + 800 /obj/machinery/atmospherics/unary/vent_pump/update_icon(var/safety = 0) if(!check_icon_cache()) diff --git a/code/ATMOSPHERICS/components/unary/vent_scrubber.dm b/code/ATMOSPHERICS/components/unary/vent_scrubber.dm index 166929e042..8c768869eb 100644 --- a/code/ATMOSPHERICS/components/unary/vent_scrubber.dm +++ b/code/ATMOSPHERICS/components/unary/vent_scrubber.dm @@ -26,6 +26,9 @@ var/radio_filter_in /obj/machinery/atmospherics/unary/vent_scrubber/New() + ..() + air_contents.volume = ATMOS_DEFAULT_VOLUME_FILTER + icon = null initial_loc = get_area(loc) if (initial_loc.master) @@ -37,7 +40,6 @@ if(ticker && ticker.current_state == 3)//if the game is running src.initialize() src.broadcast_status() - ..() /obj/machinery/atmospherics/unary/vent_scrubber/update_icon(var/safety = 0) if(!check_icon_cache()) diff --git a/code/ATMOSPHERICS/pipes.dm b/code/ATMOSPHERICS/pipes.dm index c8d76824ab..ea031592da 100644 --- a/code/ATMOSPHERICS/pipes.dm +++ b/code/ATMOSPHERICS/pipes.dm @@ -138,7 +138,7 @@ name = "pipe" desc = "A one meter section of regular pipe" - volume = 70 + volume = ATMOS_DEFAULT_VOLUME_PIPE dir = SOUTH initialize_directions = SOUTH|NORTH @@ -373,7 +373,7 @@ name = "pipe manifold" desc = "A manifold composed of regular pipes" - volume = 105 + volume = ATMOS_DEFAULT_VOLUME_PIPE * 1.5 dir = SOUTH initialize_directions = EAST|NORTH|WEST @@ -583,7 +583,7 @@ name = "4-way pipe manifold" desc = "A manifold composed of regular pipes" - volume = 140 + volume = ATMOS_DEFAULT_VOLUME_PIPE * 2 dir = SOUTH initialize_directions = NORTH|SOUTH|EAST|WEST diff --git a/code/setup.dm b/code/setup.dm index d149f37d8a..e2582f8a9a 100644 --- a/code/setup.dm +++ b/code/setup.dm @@ -836,10 +836,16 @@ var/list/RESTRICTED_CAMERA_NETWORKS = list( //Those networks can only be accesse #define MAX_FILTER_FLOWRATE 200 //L/s //These balance how easy or hard it is to create huge pressure gradients with pumps and filters. Lower values means it takes longer to create large pressures differences. -//If you want to limit the ability of players to create very high pressures then it makes more sense to adjust these instead of artificially limiting the pump settings. //Has no effect on pumping gasses from high pressure to low, only from low to high. Must be between 0 and 1. #define ATMOS_PUMP_EFFICIENCY 0.6 #define ATMOS_FILTER_EFFICIENCY 0.45 -#define MINUMUM_MOLES_TO_PUMP 0.01 //will not bother pumping or filtering if the gas source as fewer than this amount of moles, to help with performance. +//will not bother pumping or filtering if the gas source as fewer than this amount of moles, to help with performance. +#define MINUMUM_MOLES_TO_PUMP 0.01 #define MINUMUM_MOLES_TO_FILTER 0.1 + +//The flow rate/effectiveness of various atmos devices is limited by their internal volume, so these will control maximum flow rates in L/s +#define ATMOS_DEFAULT_VOLUME_PUMP 200 //L +#define ATMOS_DEFAULT_VOLUME_FILTER 200 //L +#define ATMOS_DEFAULT_VOLUME_MIXER 200 //L +#define ATMOS_DEFAULT_VOLUME_PIPE 70 //L \ No newline at end of file