From ec18de7d7913e54b9b5e745375fec197889d5f24 Mon Sep 17 00:00:00 2001 From: ShadowLarkens Date: Wed, 23 Oct 2024 05:47:09 -0700 Subject: [PATCH] Replace all air_master nonsense with SSair --- .../components/unary/heat_exchanger.dm | 6 ++--- code/ZAS/Atom.dm | 4 ++-- code/ZAS/Connection.dm | 16 +++++++------- code/ZAS/ConnectionGroup.dm | 20 ++++++++--------- code/ZAS/ConnectionManager.dm | 2 +- code/ZAS/Controller.dm | 4 +--- code/ZAS/Diagnostic.dm | 4 ++-- code/ZAS/Fire.dm | 8 +++---- code/ZAS/Turf.dm | 14 ++++++------ code/ZAS/Zone.dm | 18 +++++++-------- code/ZAS/_docs.dm | 2 +- code/_helpers/unsorted.dm | 2 +- code/controllers/subsystems/air.dm | 7 ++---- code/controllers/verbs.dm | 1 - code/game/machinery/doors/door.dm | 4 ++-- code/game/machinery/doors/firedoor.dm | 6 ++--- code/game/objects/effects/zone_divider.dm | 4 ++-- code/game/objects/items/blueprints.dm | 4 ++-- code/game/objects/items/blueprints_vr.dm | 8 +++---- code/game/turfs/simulated/wall_attacks.dm | 8 +++---- code/game/turfs/turf_changing.dm | 6 ++--- code/game/turfs/unsimulated/planetary.dm | 3 +-- code/modules/admin/verbs/buildmode.dm | 4 ++-- code/modules/admin/verbs/diagnostics.dm | 22 +++++++++---------- code/modules/admin/verbs/mapping.dm | 4 ++-- code/modules/hydroponics/seed.dm | 4 ++-- code/modules/mining/mine_turfs.dm | 4 ++-- code/modules/mob/living/carbon/breathe.dm | 2 +- code/modules/mob/living/carbon/human/life.dm | 2 +- .../silicon/robot/dogborg/dog_sleeper_vr.dm | 2 +- .../subtypes/vore/solargrub_larva.dm | 2 +- code/unit_tests/map_tests.dm | 4 ++-- 32 files changed, 97 insertions(+), 104 deletions(-) diff --git a/code/ATMOSPHERICS/components/unary/heat_exchanger.dm b/code/ATMOSPHERICS/components/unary/heat_exchanger.dm index 7b6a5621eb1..078c97af8a1 100644 --- a/code/ATMOSPHERICS/components/unary/heat_exchanger.dm +++ b/code/ATMOSPHERICS/components/unary/heat_exchanger.dm @@ -36,11 +36,11 @@ if(!partner) return 0 - if(!air_master || air_master.current_cycle <= update_cycle) + if(!SSair || SSair.current_cycle <= update_cycle) return 0 - update_cycle = air_master.current_cycle - partner.update_cycle = air_master.current_cycle + update_cycle = SSair.current_cycle + partner.update_cycle = SSair.current_cycle var/air_heat_capacity = air_contents.heat_capacity() var/other_air_heat_capacity = partner.air_contents.heat_capacity() diff --git a/code/ZAS/Atom.dm b/code/ZAS/Atom.dm index bfe6fa2ad4d..eeb01b42495 100644 --- a/code/ZAS/Atom.dm +++ b/code/ZAS/Atom.dm @@ -36,11 +36,11 @@ //Convenience function for atoms to update turfs they occupy /atom/movable/proc/update_nearby_tiles(need_rebuild) - if(!air_master) + if(!SSair) return 0 for(var/turf/simulated/turf in locs) - air_master.mark_for_update(turf) + SSair.mark_for_update(turf) return 1 diff --git a/code/ZAS/Connection.dm b/code/ZAS/Connection.dm index 21be29d25e1..e0549366cbc 100644 --- a/code/ZAS/Connection.dm +++ b/code/ZAS/Connection.dm @@ -5,7 +5,7 @@ /* Overview: - Connections are made between turfs by air_master.connect(). They represent a single point where two zones converge. + Connections are made between turfs by SSair.connect(). They represent a single point where two zones converge. Class Vars: A - Always a simulated turf. @@ -60,19 +60,19 @@ Class Procs: /connection/New(turf/simulated/A, turf/simulated/B) #ifdef ZASDBG - ASSERT(air_master.has_valid_zone(A)) - //ASSERT(air_master.has_valid_zone(B)) + ASSERT(SSair.has_valid_zone(A)) + //ASSERT(SSair.has_valid_zone(B)) #endif src.A = A src.B = B zoneA = A.zone if(!istype(B)) mark_space() - edge = air_master.get_edge(A.zone,B) + edge = SSair.get_edge(A.zone,B) edge.add_connection(src) else zoneB = B.zone - edge = air_master.get_edge(A.zone,B.zone) + edge = SSair.get_edge(A.zone,B.zone) edge.add_connection(src) /connection/proc/mark_direct() @@ -108,7 +108,7 @@ Class Procs: erase() return - var/block_status = air_master.air_blocked(A,B) + var/block_status = SSair.air_blocked(A,B) if(block_status & AIR_BLOCKED) //to_world("Blocked connection.") erase() @@ -133,7 +133,7 @@ Class Procs: return else edge.remove_connection(src) - edge = air_master.get_edge(A.zone, B) + edge = SSair.get_edge(A.zone, B) edge.add_connection(src) zoneA = A.zone @@ -155,7 +155,7 @@ Class Procs: //to_world("Zones changed, \...") if(A.zone && B.zone) edge.remove_connection(src) - edge = air_master.get_edge(A.zone, B.zone) + edge = SSair.get_edge(A.zone, B.zone) edge.add_connection(src) zoneA = A.zone zoneB = B.zone diff --git a/code/ZAS/ConnectionGroup.dm b/code/ZAS/ConnectionGroup.dm index 0be44bb3584..85b2545d36e 100644 --- a/code/ZAS/ConnectionGroup.dm +++ b/code/ZAS/ConnectionGroup.dm @@ -2,7 +2,7 @@ Overview: These are what handle gas transfers between zones and into space. - They are found in a zone's edges list and in air_master.edges. + They are found in a zone's edges list and in SSair.edges. Each edge updates every air tick due to their role in gas transfer. They come in two flavors, /connection_edge/zone and /connection_edge/unsimulated. As the type names might suggest, they handle inter-zone and spacelike connections respectively. @@ -82,7 +82,7 @@ Class Procs: /connection_edge/proc/contains_zone(zone/Z) /connection_edge/proc/erase() - air_master.remove_edge(src) + SSair.remove_edge(src) //to_world("[type] Erased.") /connection_edge/proc/tick() @@ -169,19 +169,19 @@ Class Procs: if(equiv) if(direct) erase() - air_master.merge(A, B) + SSair.merge(A, B) return else A.air.equalize(B.air) - air_master.mark_edge_sleeping(src) + SSair.mark_edge_sleeping(src) - air_master.mark_zone_update(A) - air_master.mark_zone_update(B) + SSair.mark_zone_update(A) + SSair.mark_zone_update(B) /connection_edge/zone/recheck() // Edges with only one side being vacuum need processing no matter how close. if(!A.air.compare(B.air, vacuum_exception = 1)) - air_master.mark_edge_active(src) + SSair.mark_edge_active(src) //Helper proc to get connections for a zone. /connection_edge/zone/proc/get_connected_zone(zone/from) @@ -233,16 +233,16 @@ Class Procs: if(equiv) A.air.copy_from(air) - air_master.mark_edge_sleeping(src) + SSair.mark_edge_sleeping(src) - air_master.mark_zone_update(A) + SSair.mark_zone_update(A) /connection_edge/unsimulated/recheck() // Edges with only one side being vacuum need processing no matter how close. // Note: This handles the glaring flaw of a room holding pressure while exposed to space, but // does not specially handle the less common case of a simulated room exposed to an unsimulated pressurized turf. if(!A.air.compare(air, vacuum_exception = 1)) - air_master.mark_edge_active(src) + SSair.mark_edge_active(src) /proc/ShareHeat(datum/gas_mixture/A, datum/gas_mixture/B, connecting_tiles) //This implements a simplistic version of the Stefan-Boltzmann law. diff --git a/code/ZAS/ConnectionManager.dm b/code/ZAS/ConnectionManager.dm index 3890cd85f5c..8d7e270cde0 100644 --- a/code/ZAS/ConnectionManager.dm +++ b/code/ZAS/ConnectionManager.dm @@ -16,7 +16,7 @@ Class Procs: Preferable to accessing the connection directly because it checks validity. place(connection/c, d) - Called by air_master.connect(). Sets the connection in the specified direction to c. + Called by SSair.connect(). Sets the connection in the specified direction to c. update_all() Called after turf/update_air_properties(). Updates the validity of all connections on this turf. diff --git a/code/ZAS/Controller.dm b/code/ZAS/Controller.dm index 7f7b5752469..d3ada5e3116 100644 --- a/code/ZAS/Controller.dm +++ b/code/ZAS/Controller.dm @@ -1,5 +1,3 @@ -var/datum/controller/subsystem/air/air_master - var/tick_multiplier = 2 /* @@ -133,7 +131,7 @@ Class Procs: ASSERT(A != B) #endif - var/block = air_master.air_blocked(A,B) + var/block = SSair.air_blocked(A,B) if(block & AIR_BLOCKED) return var/direct = !(block & ZONE_BLOCKED) diff --git a/code/ZAS/Diagnostic.dm b/code/ZAS/Diagnostic.dm index fba24568028..7893ba42624 100644 --- a/code/ZAS/Diagnostic.dm +++ b/code/ZAS/Diagnostic.dm @@ -8,12 +8,12 @@ /* if(!check_rights(R_DEBUG)) return - var/result = air_master.Tick() + var/result = SSair.Tick() if(result) to_chat(src, "Successfully Processed.") else - to_chat(src, "Failed to process! ([air_master.tick_progress])") + to_chat(src, "Failed to process! ([SSair.tick_progress])") */ /client/proc/Zone_Info(turf/T as null|turf) diff --git a/code/ZAS/Fire.dm b/code/ZAS/Fire.dm index 5c3a24d882a..8c1e4afa064 100644 --- a/code/ZAS/Fire.dm +++ b/code/ZAS/Fire.dm @@ -58,7 +58,7 @@ If it gains pressure too slowly, it may leak or just rupture instead of explodin fuel_objs.Cut() if(!fire_tiles.len) - air_master.active_fire_zones.Remove(src) + SSair.active_fire_zones.Remove(src) /zone/proc/remove_liquidfuel(var/used_liquid_fuel, var/remove_fire=0) if(!fuel_objs.len) @@ -94,7 +94,7 @@ If it gains pressure too slowly, it may leak or just rupture instead of explodin return 1 fire = new(src, fl) - air_master.active_fire_zones |= zone + SSair.active_fire_zones |= zone var/obj/effect/decal/cleanable/liquid_fuel/fuel = locate() in src zone.fire_tiles |= src @@ -191,7 +191,7 @@ If it gains pressure too slowly, it may leak or just rupture instead of explodin set_light(3, 1, color) firelevel = fl - air_master.active_hotspots.Add(src) + SSair.active_hotspots.Add(src) /obj/fire/proc/fire_color(var/env_temperature) var/temperature = max(4000*sqrt(firelevel/vsc.fire_firelevel_multiplier), env_temperature) @@ -209,7 +209,7 @@ If it gains pressure too slowly, it may leak or just rupture instead of explodin T.fire = null loc = null - air_master.active_hotspots.Remove(src) + SSair.active_hotspots.Remove(src) /turf/simulated/var/fire_protection = 0 //Protects newly extinguished tiles from being overrun again. diff --git a/code/ZAS/Turf.dm b/code/ZAS/Turf.dm index c05e708036b..f8bfc5ae83c 100644 --- a/code/ZAS/Turf.dm +++ b/code/ZAS/Turf.dm @@ -41,9 +41,9 @@ if(istype(unsim, /turf/simulated)) var/turf/simulated/sim = unsim - if(air_master.has_valid_zone(sim)) + if(SSair.has_valid_zone(sim)) - air_master.connect(sim, src) + SSair.connect(sim, src) /* Simple heuristic for determining if removing the turf from it's zone will not partition the zone (A very bad thing). @@ -162,7 +162,7 @@ var/turf/simulated/sim = unsim sim.open_directions |= reverse_dir[d] - if(air_master.has_valid_zone(sim)) + if(SSair.has_valid_zone(sim)) //Might have assigned a zone, since this happens for each direction. if(!zone) @@ -195,7 +195,7 @@ if(verbose) to_world("Connecting to [sim.zone]") #endif - air_master.connect(src, sim) + SSair.connect(src, sim) #ifdef ZASDBG @@ -210,7 +210,7 @@ if(!postponed) postponed = list() postponed.Add(unsim) - if(!air_master.has_valid_zone(src)) //Still no zone, make a new one. + if(!SSair.has_valid_zone(src)) //Still no zone, make a new one. var/zone/newzone = new/zone() newzone.add(src) @@ -223,7 +223,7 @@ //At this point, a zone should have happened. If it hasn't, don't add more checks, fix the bug. for(var/turf/T in postponed) - air_master.connect(src, T) + SSair.connect(src, T) /turf/proc/post_update_air_properties() if(connections) connections.update_all() @@ -279,7 +279,7 @@ /turf/simulated/return_air() if(zone) if(!zone.invalid) - air_master.mark_zone_update(zone) + SSair.mark_zone_update(zone) return zone.air else if(!air) diff --git a/code/ZAS/Zone.dm b/code/ZAS/Zone.dm index d07a280d040..db686ce8f05 100644 --- a/code/ZAS/Zone.dm +++ b/code/ZAS/Zone.dm @@ -56,7 +56,7 @@ Class Procs: /zone/var/list/graphic_remove = list() /zone/New() - air_master.add_zone(src) + SSair.add_zone(src) air.temperature = TCMB air.group_multiplier = 1 air.volume = CELL_VOLUME @@ -65,7 +65,7 @@ Class Procs: #ifdef ZASDBG ASSERT(!invalid) ASSERT(istype(T)) - ASSERT(!air_master.has_valid_zone(T)) + ASSERT(!SSair.has_valid_zone(T)) #endif var/datum/gas_mixture/turf_air = T.return_air() @@ -75,7 +75,7 @@ Class Procs: if(T.fire) var/obj/effect/decal/cleanable/liquid_fuel/fuel = locate() in T fire_tiles.Add(T) - air_master.active_fire_zones |= src + SSair.active_fire_zones |= src if(fuel) fuel_objs += fuel if(air.graphic) T.update_graphic(air.graphic) @@ -122,11 +122,11 @@ Class Procs: if(E.contains_zone(into)) continue //don't need to rebuild this edge for(var/turf/T in E.connecting_turfs) - air_master.mark_for_update(T) + SSair.mark_for_update(T) /zone/proc/c_invalidate() invalid = 1 - air_master.remove_zone(src) + SSair.remove_zone(src) #ifdef ZASDBG for(var/turf/simulated/T in contents) T.dbg(invalid_zone) @@ -141,7 +141,7 @@ Class Procs: T.update_graphic(graphic_remove = air_graphic) //we need to remove the overlays so they're not doubled when the zone is rebuilt //T.dbg(invalid_zone) T.needs_air_update = 0 //Reset the marker so that it will be added to the list. - air_master.mark_for_update(T) + SSair.mark_for_update(T) /zone/proc/add_tile_air(datum/gas_mixture/tile_air) //air.volume += CELL_VOLUME @@ -152,7 +152,7 @@ Class Procs: air.group_multiplier = contents.len+1 /zone/proc/tick() - if(air.temperature >= PHORON_FLASHPOINT && !(src in air_master.active_fire_zones) && air.check_combustability() && contents.len) + if(air.temperature >= PHORON_FLASHPOINT && !(src in SSair.active_fire_zones) && air.check_combustability() && contents.len) var/turf/T = pick(contents) if(istype(T)) T.create_fire(vsc.fire_firelevel_multiplier) @@ -171,7 +171,7 @@ Class Procs: to_chat(M,name) for(var/g in air.gas) to_chat(M, "[gas_data.name[g]]: [air.gas[g]]") - to_chat(M, "P: [air.return_pressure()] kPa V: [air.volume]L T: [air.temperature]°K ([air.temperature - T0C]°C)") + to_chat(M, "P: [air.return_pressure()] kPa V: [air.volume]L T: [air.temperature]�K ([air.temperature - T0C]�C)") to_chat(M, "O2 per N2: [(air.gas["nitrogen"] ? air.gas["oxygen"]/air.gas["nitrogen"] : "N/A")] Moles: [air.total_moles]") to_chat(M, "Simulated: [contents.len] ([air.group_multiplier])") //to_chat(M, "Unsimulated: [unsimulated_contents.len]") @@ -192,4 +192,4 @@ Class Procs: to_chat(M, "Space Edges: [space_edges] ([space_coefficient] connections)") //for(var/turf/T in unsimulated_contents) - // to_chat(M, "[T] at ([T.x],[T.y])") \ No newline at end of file + // to_chat(M, "[T] at ([T.x],[T.y])") diff --git a/code/ZAS/_docs.dm b/code/ZAS/_docs.dm index 382f1f0abbf..822c8ac7b2a 100644 --- a/code/ZAS/_docs.dm +++ b/code/ZAS/_docs.dm @@ -15,7 +15,7 @@ Every air tick: Important Functions: -air_master.mark_for_update(turf) +SSair.mark_for_update(turf) When stuff happens, call this. It works on everything. You basically don't need to worry about any other functions besides CanPass(). diff --git a/code/_helpers/unsorted.dm b/code/_helpers/unsorted.dm index 057f988dcb9..59be2633d78 100644 --- a/code/_helpers/unsorted.dm +++ b/code/_helpers/unsorted.dm @@ -974,7 +974,7 @@ Turf and target are seperate in case you want to teleport some distance from a t if(toupdate.len) for(var/turf/simulated/T1 in toupdate) - air_master.mark_for_update(T1) + SSair.mark_for_update(T1) return copiedobjs diff --git a/code/controllers/subsystems/air.dm b/code/controllers/subsystems/air.dm index 1e5f1506ec6..d84f591436f 100644 --- a/code/controllers/subsystems/air.dm +++ b/code/controllers/subsystems/air.dm @@ -30,9 +30,6 @@ SUBSYSTEM_DEF(air) // This is used to tell CI WHERE the edges are. var/list/startup_active_edge_log = list() -/datum/controller/subsystem/air/PreInit() - air_master = src - /datum/controller/subsystem/air/Initialize(timeofday) report_progress("Processing Geometry...") @@ -109,7 +106,7 @@ Total Unsimulated Turfs: [world.maxx*world.maxy*world.maxz - simulated_turf_coun log_and_message_admins("SSair: Was told to start a new run, but the previous run wasn't finished! currentrun.len=[currentrun.len], current_step=[current_step]") resumed = TRUE else - current_cycle++ // Begin a new air_master cycle! + current_cycle++ // Begin a new SSair cycle! current_step = SSAIR_TURFS // Start with Step 1 of course INTERNAL_PROCESS_STEP(SSAIR_TURFS, TRUE, process_tiles_to_update, cost_turfs, SSAIR_EDGES) @@ -118,7 +115,7 @@ Total Unsimulated Turfs: [world.maxx*world.maxy*world.maxz - simulated_turf_coun INTERNAL_PROCESS_STEP(SSAIR_HOTSPOTS, FALSE, process_active_hotspots, cost_hotspots, SSAIR_ZONES) INTERNAL_PROCESS_STEP(SSAIR_ZONES, FALSE, process_zones_to_update, cost_zones, SSAIR_DONE) - // Okay, we're done! Woo! Got thru a whole air_master cycle! + // Okay, we're done! Woo! Got thru a whole SSair cycle! if(LAZYLEN(currentrun) || current_step != SSAIR_DONE) log_and_message_admins("SSair: Was not able to complete a full air cycle despite reaching the end of fire(). This shouldn't happen.") else diff --git a/code/controllers/verbs.dm b/code/controllers/verbs.dm index fee7da9b853..150d482360a 100644 --- a/code/controllers/verbs.dm +++ b/code/controllers/verbs.dm @@ -89,7 +89,6 @@ //Goon PS stuff, and other yet-to-be-subsystem things. options["LEGACY: master_controller"] = master_controller - options["LEGACY: air_master"] = air_master options["LEGACY: job_master"] = job_master options["LEGACY: radio_controller"] = radio_controller options["LEGACY: emergency_shuttle"] = emergency_shuttle diff --git a/code/game/machinery/doors/door.dm b/code/game/machinery/doors/door.dm index 2f70e0436e0..8055af222cc 100644 --- a/code/game/machinery/doors/door.dm +++ b/code/game/machinery/doors/door.dm @@ -437,12 +437,12 @@ return ..(M) /obj/machinery/door/update_nearby_tiles(need_rebuild) - if(!air_master) + if(!SSair) return 0 for(var/turf/simulated/turf in locs) update_heat_protection(turf) - air_master.mark_for_update(turf) + SSair.mark_for_update(turf) return 1 diff --git a/code/game/machinery/doors/firedoor.dm b/code/game/machinery/doors/firedoor.dm index d4477eeac00..4502ed93343 100644 --- a/code/game/machinery/doors/firedoor.dm +++ b/code/game/machinery/doors/firedoor.dm @@ -501,15 +501,15 @@ update_nearby_tiles(need_rebuild) - if(!air_master) return 0 + if(!SSair) return 0 var/turf/simulated/source = loc var/turf/simulated/destination = get_step(source,dir) update_heat_protection(loc) - if(istype(source)) air_master.tiles_to_update += source - if(istype(destination)) air_master.tiles_to_update += destination + if(istype(source)) SSair.tiles_to_update += source + if(istype(destination)) SSair.tiles_to_update += destination return 1 */ diff --git a/code/game/objects/effects/zone_divider.dm b/code/game/objects/effects/zone_divider.dm index fa2ea82531c..3638219b20f 100644 --- a/code/game/objects/effects/zone_divider.dm +++ b/code/game/objects/effects/zone_divider.dm @@ -13,8 +13,8 @@ // Special case to prevent us from being part of a zone during the first air master tick. // We must merge ourselves into a zone on next tick. This will cause a bit of lag on // startup, but it can't really be helped you know? - if(air_master && air_master.current_cycle == 0) + if(SSair && SSair.current_cycle == 0) spawn(1) - air_master.mark_for_update(get_turf(src)) + SSair.mark_for_update(get_turf(src)) return FALSE return is_zone ? FALSE : TRUE // Anything except zones can pass diff --git a/code/game/objects/items/blueprints.dm b/code/game/objects/items/blueprints.dm index 84b8d743f6c..c0f82b0b153 100644 --- a/code/game/objects/items/blueprints.dm +++ b/code/game/objects/items/blueprints.dm @@ -251,9 +251,9 @@ if (!isturf(NT) || (NT in found) || (NT in pending)) continue // We ask ZAS to determine if its airtight. Thats what matters anyway right? - if(air_master.air_blocked(T, NT)) + if(SSair.air_blocked(T, NT)) // Okay thats the edge of the room - if(get_area_type(NT.loc) == AREA_SPACE && air_master.air_blocked(NT, NT)) + if(get_area_type(NT.loc) == AREA_SPACE && SSair.air_blocked(NT, NT)) found += NT // So we include walls/doors not already in any area continue if (istype(NT, /turf/space)) diff --git a/code/game/objects/items/blueprints_vr.dm b/code/game/objects/items/blueprints_vr.dm index 336a6219d90..214bbff5185 100644 --- a/code/game/objects/items/blueprints_vr.dm +++ b/code/game/objects/items/blueprints_vr.dm @@ -678,9 +678,9 @@ if(!visual && forbiddenAreas[NT.loc.type]) return ROOM_ERR_FORBIDDEN // We ask ZAS to determine if its airtight. Thats what matters anyway right? - if(air_master.air_blocked(T, NT)) + if(SSair.air_blocked(T, NT)) // Okay thats the edge of the room - if(get_area_type(NT.loc) == AREA_SPACE && air_master.air_blocked(NT, NT)) + if(get_area_type(NT.loc) == AREA_SPACE && SSair.air_blocked(NT, NT)) found += NT // So we include walls/doors not already in any area continue if (istype(NT, /turf/space)) @@ -835,9 +835,9 @@ if(!get_new_area_type(NT.loc) == 1) //The contains somewhere that is NOT a buildable area. return 3 //NOT A BUILDABLE AREA - if(air_master.air_blocked(T, NT)) //Is the room airtight? + if(SSair.air_blocked(T, NT)) //Is the room airtight? // Okay thats the edge of the room - if(get_new_area_type(NT.loc) == 1 && air_master.air_blocked(NT, NT)) + if(get_new_area_type(NT.loc) == 1 && SSair.air_blocked(NT, NT)) found += NT // So we include walls/doors not already in any area continue if (istype(NT, /turf/space)) diff --git a/code/game/turfs/simulated/wall_attacks.dm b/code/game/turfs/simulated/wall_attacks.dm index d7630618e2b..cfc998f72a1 100644 --- a/code/game/turfs/simulated/wall_attacks.dm +++ b/code/game/turfs/simulated/wall_attacks.dm @@ -17,7 +17,7 @@ src.blocks_air = 0 set_opacity(0) for(var/turf/simulated/turf in loc) - air_master.mark_for_update(turf) + SSair.mark_for_update(turf) else can_open = WALL_OPENING //flick("[material.icon_base]fwall_closing", src) @@ -29,18 +29,18 @@ src.blocks_air = 1 set_opacity(1) for(var/turf/simulated/turf in loc) - air_master.mark_for_update(turf) + SSair.mark_for_update(turf) can_open = WALL_CAN_OPEN update_icon() /turf/simulated/wall/proc/update_air() - if(!air_master) + if(!SSair) return for(var/turf/simulated/turf in loc) update_thermal(turf) - air_master.mark_for_update(turf) + SSair.mark_for_update(turf) /turf/simulated/wall/proc/update_thermal(var/turf/simulated/source) diff --git a/code/game/turfs/turf_changing.dm b/code/game/turfs/turf_changing.dm index 72cb432e1bc..11afc9e0420 100644 --- a/code/game/turfs/turf_changing.dm +++ b/code/game/turfs/turf_changing.dm @@ -28,7 +28,7 @@ if(N == /turf/space) var/turf/below = GetBelow(src) - if(istype(below) && (air_master.has_valid_zone(below) || air_master.has_valid_zone(src)) && !(src.z in using_map.below_blocked_levels) && (!istype(below, /turf/unsimulated/wall) && !istype(below, /turf/simulated/sky))) // VOREStation Edit: Weird open space + if(istype(below) && (SSair.has_valid_zone(below) || SSair.has_valid_zone(src)) && !(src.z in using_map.below_blocked_levels) && (!istype(below, /turf/unsimulated/wall) && !istype(below, /turf/simulated/sky))) // VOREStation Edit: Weird open space N = /turf/simulated/open var/obj/fire/old_fire = fire @@ -75,8 +75,8 @@ if(tell_universe) universe.OnTurfChange(W) - if(air_master) - air_master.mark_for_update(W) + if(SSair) + SSair.mark_for_update(W) for(var/turf/space/S in range(W, 1)) S.update_starlight() diff --git a/code/game/turfs/unsimulated/planetary.dm b/code/game/turfs/unsimulated/planetary.dm index c6be94c5ed0..d73201c1661 100644 --- a/code/game/turfs/unsimulated/planetary.dm +++ b/code/game/turfs/unsimulated/planetary.dm @@ -33,7 +33,7 @@ // Force ZAS to reconsider our connections because our temperature has changed if(connections) connections.erase_all() - air_master.mark_for_update(src) + SSair.mark_for_update(src) // Normal station/earth air. /turf/unsimulated/wall/planetary/normal @@ -67,4 +67,3 @@ oxygen = MOLES_O2STANDARD nitrogen = MOLES_N2STANDARD temperature = 310.92 // About 37.7C / 100F - diff --git a/code/modules/admin/verbs/buildmode.dm b/code/modules/admin/verbs/buildmode.dm index 922e3c326ef..aa3efca68dc 100644 --- a/code/modules/admin/verbs/buildmode.dm +++ b/code/modules/admin/verbs/buildmode.dm @@ -830,9 +830,9 @@ if (!isturf(NT) || (NT in found) || (NT in pending)) continue // We ask ZAS to determine if its airtight. Thats what matters anyway right? - if(air_master.air_blocked(T, NT)) + if(SSair.air_blocked(T, NT)) // Okay thats the edge of the room - if(get_area_type_buildmode(NT.loc) == AREA_SPACE && air_master.air_blocked(NT, NT)) + if(get_area_type_buildmode(NT.loc) == AREA_SPACE && SSair.air_blocked(NT, NT)) found += NT // So we include walls/doors not already in any area continue if (istype(NT, /turf/space)) diff --git a/code/modules/admin/verbs/diagnostics.dm b/code/modules/admin/verbs/diagnostics.dm index 1ce73a7f742..3e9a81b3190 100644 --- a/code/modules/admin/verbs/diagnostics.dm +++ b/code/modules/admin/verbs/diagnostics.dm @@ -2,12 +2,12 @@ set category = "Debug" set name = "Show Air Report" - if(!master_controller || !air_master) - tgui_alert_async(usr,"Master_controller or air_master not found.","Air Report") + if(!master_controller || !SSair) + tgui_alert_async(usr,"Master_controller or SSair not found.","Air Report") return - var/active_groups = air_master.active_zones - var/inactive_groups = air_master.zones.len - active_groups + var/active_groups = SSair.active_zones + var/inactive_groups = SSair.zones.len - active_groups var/hotspots = 0 for(var/obj/fire/hotspot in world) @@ -15,7 +15,7 @@ var/active_on_main_station = 0 var/inactive_on_main_station = 0 - for(var/zone/zone in air_master.zones) + for(var/zone/zone in SSair.zones) var/turf/simulated/turf = locate() in zone.contents if(turf?.z in using_map.station_levels) if(zone.needs_update) @@ -25,8 +25,8 @@ var/output = {"AIR SYSTEMS REPORT
General Processing Data
- Cycle: [air_master.current_cycle]
- Groups: [air_master.zones.len]
+ Cycle: [SSair.current_cycle]
+ Groups: [SSair.zones.len]
---- Active: [active_groups]
---- Inactive: [inactive_groups]

---- Active on station: [active_on_main_station]
@@ -36,7 +36,7 @@ Hotspot Processing: [hotspots]

Geometry Processing Data
- Tile Update: [air_master.tiles_to_update.len]
+ Tile Update: [SSair.tiles_to_update.len]
"} usr << browse(output,"window=airreport") @@ -127,11 +127,11 @@ to_chat(src, "Only administrators may use this command.") return - if(!air_master) + if(!SSair) to_chat(usr, "Cannot find air_system") return var/datum/air_group/dead_groups = list() - for(var/datum/air_group/group in air_master.air_groups) + for(var/datum/air_group/group in SSair.air_groups) if (!group.group_processing) dead_groups += group var/datum/air_group/dest_group = pick(dead_groups) @@ -149,7 +149,7 @@ to_chat(src, "Only administrators may use this command.") return - if(!air_master) + if(!SSair) to_chat(usr, "Cannot find air_system") return diff --git a/code/modules/admin/verbs/mapping.dm b/code/modules/admin/verbs/mapping.dm index c51b131b8e2..9b43a08bf4c 100644 --- a/code/modules/admin/verbs/mapping.dm +++ b/code/modules/admin/verbs/mapping.dm @@ -354,7 +354,7 @@ var/global/prevent_airgroup_regroup = 0 set name = "Break All Airgroups" /*prevent_airgroup_regroup = 1 - for(var/datum/air_group/AG in air_master.air_groups) + for(var/datum/air_group/AG in SSair.air_groups) AG.suspend_group_processing() message_admins("[src.ckey] used 'Break All Airgroups'")*/ @@ -365,7 +365,7 @@ var/global/prevent_airgroup_regroup = 0 to_chat(usr, span_red("Proc disabled.")) //Why not.. Delete the procs instead? /*prevent_airgroup_regroup = 0 - for(var/datum/air_group/AG in air_master.air_groups) + for(var/datum/air_group/AG in SSair.air_groups) AG.check_regroup() message_admins("[src.ckey] used 'Regroup All Airgroups Attempt'")*/ diff --git a/code/modules/hydroponics/seed.dm b/code/modules/hydroponics/seed.dm index 61b2ae4df5b..150e345db6c 100644 --- a/code/modules/hydroponics/seed.dm +++ b/code/modules/hydroponics/seed.dm @@ -254,11 +254,11 @@ var/no_los var/turf/last_turf = origin_turf for(var/turf/target_turf in getline(origin_turf,neighbor)) - if(air_master.air_blocked(last_turf, target_turf)) + if(SSair.air_blocked(last_turf, target_turf)) no_los = 1 break last_turf = target_turf - if(!no_los && air_master.air_blocked(origin_turf, neighbor)) + if(!no_los && SSair.air_blocked(origin_turf, neighbor)) no_los = 1 if(no_los) closed_turfs |= neighbor diff --git a/code/modules/mining/mine_turfs.dm b/code/modules/mining/mine_turfs.dm index 3bab28eae20..f679591e2d6 100644 --- a/code/modules/mining/mine_turfs.dm +++ b/code/modules/mining/mine_turfs.dm @@ -173,8 +173,8 @@ var/list/mining_overlay_cache = list() recalculate_directional_opacity() if(ticker && ticker.current_state == GAME_STATE_PLAYING) reconsider_lights() - if(air_master) - air_master.mark_for_update(src) + if(SSair) + SSair.mark_for_update(src) /turf/simulated/mineral/proc/get_cached_border(var/cache_id, var/direction, var/icon_file, var/icon_state, var/offset = 32) //Cache miss diff --git a/code/modules/mob/living/carbon/breathe.dm b/code/modules/mob/living/carbon/breathe.dm index f4d90e97120..009667dbf4b 100644 --- a/code/modules/mob/living/carbon/breathe.dm +++ b/code/modules/mob/living/carbon/breathe.dm @@ -2,7 +2,7 @@ //Start of a breath chain, calls breathe() /mob/living/carbon/handle_breathing() - if(air_master.current_cycle%4==2 || failed_last_breath || (health < CONFIG_GET(number/health_threshold_crit))) //First, resolve location and get a breath + if(SSair.current_cycle%4==2 || failed_last_breath || (health < CONFIG_GET(number/health_threshold_crit))) //First, resolve location and get a breath breathe() /mob/living/carbon/proc/breathe() diff --git a/code/modules/mob/living/carbon/human/life.dm b/code/modules/mob/living/carbon/human/life.dm index 7d64ac51cfe..7463a72cb94 100644 --- a/code/modules/mob/living/carbon/human/life.dm +++ b/code/modules/mob/living/carbon/human/life.dm @@ -1777,7 +1777,7 @@ stomach_contents.Remove(M) qdel(M) continue - if(air_master.current_cycle%3==1) + if(SSair.current_cycle%3==1) if(!(M.status_flags & GODMODE)) M.adjustBruteLoss(5) adjust_nutrition(10) diff --git a/code/modules/mob/living/silicon/robot/dogborg/dog_sleeper_vr.dm b/code/modules/mob/living/silicon/robot/dogborg/dog_sleeper_vr.dm index 6c573330d47..0baa98d422b 100644 --- a/code/modules/mob/living/silicon/robot/dogborg/dog_sleeper_vr.dm +++ b/code/modules/mob/living/silicon/robot/dogborg/dog_sleeper_vr.dm @@ -579,7 +579,7 @@ 'sound/vore/digest12.ogg') playsound(src, churnsound, vol = 100, vary = 1, falloff = 0.1, ignore_walls = TRUE, preference = /datum/preference/toggle/digestion_noises) //If the timing is right, and there are items to be touched - if(air_master.current_cycle%3==1 && length(touchable_items)) + if(SSair.current_cycle%3==1 && length(touchable_items)) //Burn all the mobs or add them to the exclusion list for(var/mob/living/T in (touchable_items)) diff --git a/code/modules/mob/living/simple_mob/subtypes/vore/solargrub_larva.dm b/code/modules/mob/living/simple_mob/subtypes/vore/solargrub_larva.dm index 763e7386ab5..f1c2ef76417 100644 --- a/code/modules/mob/living/simple_mob/subtypes/vore/solargrub_larva.dm +++ b/code/modules/mob/living/simple_mob/subtypes/vore/solargrub_larva.dm @@ -88,7 +88,7 @@ var/global/list/grub_machine_overlays = list() return if(istype(loc, /obj/machinery)) - if(machine_effect && air_master.current_cycle%30) + if(machine_effect && SSair.current_cycle%30) for(var/mob/M in player_list) M << machine_effect if(prob(10)) diff --git a/code/unit_tests/map_tests.dm b/code/unit_tests/map_tests.dm index e988835fc4d..d6a93477845 100644 --- a/code/unit_tests/map_tests.dm +++ b/code/unit_tests/map_tests.dm @@ -124,10 +124,10 @@ /datum/unit_test/active_edges/start_test() - var/active_edges = air_master.active_edges.len + var/active_edges = SSair.active_edges.len var/list/edge_log = list() if(active_edges) - for(var/connection_edge/E in air_master.active_edges) + for(var/connection_edge/E in SSair.active_edges) var/a_temp = E.A.air.temperature var/a_moles = E.A.air.total_moles var/a_vol = E.A.air.volume