mirror of
https://github.com/PolarisSS13/Polaris.git
synced 2026-01-10 17:32:59 +00:00
Merge pull request #6891 from PsiOmegaDelta/Z
Multi Z-Level Compatibility
This commit is contained in:
@@ -973,7 +973,7 @@ var/global/floorIsLava = 0
|
||||
if(3)
|
||||
var/count = 0
|
||||
for(var/mob/living/carbon/monkey/Monkey in world)
|
||||
if(Monkey.z == 1)
|
||||
if(Monkey.z in station_levels)
|
||||
count++
|
||||
return "Kill all [count] of the monkeys on the station"
|
||||
if(4)
|
||||
|
||||
@@ -2295,7 +2295,7 @@
|
||||
message_admins("[key_name_admin(usr)] made the floor LAVA! It'll last [length] seconds and it will deal [damage] damage to everyone.", 1)
|
||||
|
||||
for(var/turf/simulated/floor/F in world)
|
||||
if(F.z == 1)
|
||||
if(F.z in config.station_levels)
|
||||
F.name = "lava"
|
||||
F.desc = "The floor is LAVA!"
|
||||
F.overlays += "lava"
|
||||
@@ -2320,7 +2320,7 @@
|
||||
sleep(10)
|
||||
|
||||
for(var/turf/simulated/floor/F in world) // Reset everything.
|
||||
if(F.z == 1)
|
||||
if(F.z in config.station_levels)
|
||||
F.name = initial(F.name)
|
||||
F.desc = initial(F.desc)
|
||||
F.overlays.Cut()
|
||||
@@ -2368,7 +2368,7 @@
|
||||
feedback_inc("admin_secrets_fun_used",1)
|
||||
feedback_add_details("admin_secrets_fun_used","EgL")
|
||||
for(var/obj/machinery/door/airlock/W in world)
|
||||
if(W.z == 1 && !istype(get_area(W), /area/bridge) && !istype(get_area(W), /area/crew_quarters) && !istype(get_area(W), /area/security/prison))
|
||||
if(W.z in config.station_levels && !istype(get_area(W), /area/bridge) && !istype(get_area(W), /area/crew_quarters) && !istype(get_area(W), /area/security/prison))
|
||||
W.req_access = list()
|
||||
message_admins("[key_name_admin(usr)] activated Egalitarian Station mode")
|
||||
command_announcement.Announce("Centcomm airlock control override activated. Please take this time to get acquainted with your coworkers.", new_sound = 'sound/AI/commandreport.ogg')
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
var/inactive_on_main_station = 0
|
||||
for(var/zone/zone in air_master.zones)
|
||||
var/turf/simulated/turf = locate() in zone.contents
|
||||
if(turf && turf.z == 1)
|
||||
if(turf && turf.z in config.station_levels)
|
||||
if(zone.needs_update)
|
||||
active_on_main_station++
|
||||
else
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
/datum/event/alien_infestation/start()
|
||||
var/list/vents = list()
|
||||
for(var/obj/machinery/atmospherics/unary/vent_pump/temp_vent in machines)
|
||||
if(temp_vent.loc.z == 1 && !temp_vent.welded && temp_vent.network)
|
||||
if(!temp_vent.welded && temp_vent.network && temp_vent.loc.z in config.station_levels)
|
||||
if(temp_vent.network.normal_members.len > 50) //Stops Aliens getting stuck in small networks. See: Security, Virology
|
||||
vents += temp_vent
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
/datum/event/borer_infestation/start()
|
||||
var/list/vents = list()
|
||||
for(var/obj/machinery/atmospherics/unary/vent_pump/temp_vent in world)
|
||||
if(temp_vent.loc.z == 1 && !temp_vent.welded && temp_vent.network)
|
||||
if(!temp_vent.welded && temp_vent.network && temp_vent.loc.z in config.station_levels)
|
||||
//Stops cortical borers getting stuck in small networks. See: Security, Virology
|
||||
if(temp_vent.network.normal_members.len > 50)
|
||||
vents += temp_vent
|
||||
|
||||
@@ -221,21 +221,21 @@ Would like to add a law like "Law x is _______" where x = a number, and _____ is
|
||||
spawn(0)
|
||||
world << "Started processing APCs"
|
||||
for (var/obj/machinery/power/apc/APC in world)
|
||||
if(APC.z == 1)
|
||||
if(APC.z in station_levels)
|
||||
APC.ion_act()
|
||||
apcnum++
|
||||
world << "Finished processing APCs. Processed: [apcnum]"
|
||||
spawn(0)
|
||||
world << "Started processing SMES"
|
||||
for (var/obj/machinery/power/smes/SMES in world)
|
||||
if(SMES.z == 1)
|
||||
if(SMES.z in station_levels)
|
||||
SMES.ion_act()
|
||||
smesnum++
|
||||
world << "Finished processing SMES. Processed: [smesnum]"
|
||||
spawn(0)
|
||||
world << "Started processing AIRLOCKS"
|
||||
for (var/obj/machinery/door/airlock/D in world)
|
||||
if(D.z == 1)
|
||||
if(D.z in station_levels)
|
||||
//if(length(D.req_access) > 0 && !(12 in D.req_access)) //not counting general access and maintenance airlocks
|
||||
airlocknum++
|
||||
spawn(0)
|
||||
@@ -244,7 +244,7 @@ Would like to add a law like "Law x is _______" where x = a number, and _____ is
|
||||
spawn(0)
|
||||
world << "Started processing FIREDOORS"
|
||||
for (var/obj/machinery/door/firedoor/D in world)
|
||||
if(D.z == 1)
|
||||
if(D.z in station_levels)
|
||||
firedoornum++;
|
||||
spawn(0)
|
||||
D.ion_act()
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
/datum/event/spider_infestation/start()
|
||||
var/list/vents = list()
|
||||
for(var/obj/machinery/atmospherics/unary/vent_pump/temp_vent in world)
|
||||
if(temp_vent.loc.z == 1 && !temp_vent.welded && temp_vent.network)
|
||||
if(!temp_vent.welded && temp_vent.network && temp_vent.loc.z in config.station_levels)
|
||||
if(temp_vent.network.normal_members.len > 50)
|
||||
vents += temp_vent
|
||||
|
||||
|
||||
@@ -153,7 +153,7 @@
|
||||
/obj/machinery/power/apc/Del()
|
||||
if(malfai && operating)
|
||||
if (ticker.mode.config_tag == "malfunction")
|
||||
if (src.z == 1) //if (is_type_in_list(get_area(src), the_station_areas))
|
||||
if (src.z in config.station_levels) //if (is_type_in_list(get_area(src), the_station_areas))
|
||||
ticker.mode:apcs--
|
||||
area.power_light = 0
|
||||
area.power_equip = 0
|
||||
@@ -919,7 +919,7 @@
|
||||
malfai.malfhacking = 0
|
||||
locked = 1
|
||||
if (ticker.mode.config_tag == "malfunction")
|
||||
if (src.z == 1) //if (is_type_in_list(get_area(src), the_station_areas))
|
||||
if (src.z in config.station_levels) //if (is_type_in_list(get_area(src), the_station_areas))
|
||||
ticker.mode:apcs++
|
||||
if(usr:parent)
|
||||
src.malfai = usr:parent
|
||||
@@ -951,7 +951,7 @@
|
||||
|
||||
if(malfai)
|
||||
if (ticker.mode.config_tag == "malfunction")
|
||||
if (src.z == 1) //if (is_type_in_list(get_area(src), the_station_areas))
|
||||
if (src.z in config.station_levels) //if (is_type_in_list(get_area(src), the_station_areas))
|
||||
operating ? ticker.mode:apcs++ : ticker.mode:apcs--
|
||||
|
||||
src.update()
|
||||
@@ -1017,7 +1017,7 @@
|
||||
|
||||
/obj/machinery/power/apc/proc/ion_act()
|
||||
//intended to be exactly the same as an AI malf attack
|
||||
if(!src.malfhack && src.z == 1)
|
||||
if(!src.malfhack && src.z in config.station_levels)
|
||||
if(prob(3))
|
||||
src.locked = 1
|
||||
if (src.cell.charge > 0)
|
||||
@@ -1300,7 +1300,7 @@ obj/machinery/power/apc/proc/autoset(var/val, var/on)
|
||||
/obj/machinery/power/apc/proc/set_broken()
|
||||
if(malfai && operating)
|
||||
if (ticker.mode.config_tag == "malfunction")
|
||||
if (src.z == 1) //if (is_type_in_list(get_area(src), the_station_areas))
|
||||
if (src.z in config.station_levels) //if (is_type_in_list(get_area(src), the_station_areas))
|
||||
ticker.mode:apcs--
|
||||
// Aesthetically much better!
|
||||
src.visible_message("<span class='notice'>[src]'s screen flickers with warnings briefly!</span>")
|
||||
|
||||
@@ -333,7 +333,7 @@
|
||||
|
||||
|
||||
/obj/machinery/power/smes/proc/ion_act()
|
||||
if(src.z == 1)
|
||||
if(src.z in config.station_levels)
|
||||
if(prob(1)) //explosion
|
||||
for(var/mob/M in viewers(src))
|
||||
M.show_message("\red The [src.name] is making strange noises!", 3, "\red You hear sizzling electronics.", 2)
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
security_announcement_down.Announce("[config.alert_desc_green]", "Attention! Security level lowered to green")
|
||||
security_level = SEC_LEVEL_GREEN
|
||||
for(var/obj/machinery/firealarm/FA in machines)
|
||||
if(FA.z == 1 || FA.z == 5)
|
||||
if(FA.z in config.contact_levels)
|
||||
FA.overlays = list()
|
||||
FA.overlays += image('icons/obj/monitors.dmi', "overlay_green")
|
||||
if(SEC_LEVEL_BLUE)
|
||||
@@ -36,7 +36,7 @@
|
||||
security_announcement_down.Announce("[config.alert_desc_blue_downto]", "Attention! Security level lowered to blue")
|
||||
security_level = SEC_LEVEL_BLUE
|
||||
for(var/obj/machinery/firealarm/FA in machines)
|
||||
if(FA.z == 1 || FA.z == 5)
|
||||
if(FA.z in config.contact_levels)
|
||||
FA.overlays = list()
|
||||
FA.overlays += image('icons/obj/monitors.dmi', "overlay_blue")
|
||||
if(SEC_LEVEL_RED)
|
||||
@@ -52,7 +52,7 @@
|
||||
CC.post_status("alert", "redalert")*/
|
||||
|
||||
for(var/obj/machinery/firealarm/FA in machines)
|
||||
if(FA.z == 1 || FA.z == 5)
|
||||
if(FA.z in config.contact_levels)
|
||||
FA.overlays = list()
|
||||
FA.overlays += image('icons/obj/monitors.dmi', "overlay_red")
|
||||
|
||||
@@ -60,7 +60,7 @@
|
||||
security_announcement_up.Announce("[config.alert_desc_delta]", "Attention! Delta security level reached!")
|
||||
security_level = SEC_LEVEL_DELTA
|
||||
for(var/obj/machinery/firealarm/FA in machines)
|
||||
if(FA.z == 1 || FA.z == 5)
|
||||
if(FA.z in config.contact_levels)
|
||||
FA.overlays = list()
|
||||
FA.overlays += image('icons/obj/monitors.dmi', "overlay_delta")
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user