Replace explicit z-level checks with defines

This commit is contained in:
Tad Hardesty
2017-12-29 11:40:06 -08:00
committed by CitadelStationBot
parent 48e0c47410
commit 0418ee4df6
96 changed files with 268 additions and 145 deletions
+1 -1
View File
@@ -257,7 +257,7 @@
var/sanity = 0
while(summon_spots.len < SUMMON_POSSIBILITIES && sanity < 100)
var/area/summon = pick(GLOB.sortedAreas - summon_spots)
if(summon && (summon.z in GLOB.station_z_levels) && summon.valid_territory)
if(summon && is_station_level(summon.z) && summon.valid_territory)
summon_spots += summon
sanity++
update_explanation_text()
+1 -1
View File
@@ -232,7 +232,7 @@
/datum/team/nuclear/proc/syndies_escaped()
var/obj/docking_port/mobile/S = SSshuttle.getShuttle("syndicate")
return (S && (S.z == ZLEVEL_CENTCOM || S.z == ZLEVEL_TRANSIT))
return S && (is_centcom_level(S.z) || is_transit_level(S.z))
/datum/team/nuclear/proc/get_result()
var/evacuation = SSshuttle.emergency.mode == SHUTTLE_ENDGAME
+1 -1
View File
@@ -408,7 +408,7 @@
AD.Refresh()
for(var/mob/living/carbon/human/H in shuffle(GLOB.alive_mob_list))
if(!(H.z in GLOB.station_z_levels))
if(!is_station_level(H.z))
continue
if(!H.HasDisease(D))
H.ForceContractDisease(D)
+1 -1
View File
@@ -545,7 +545,7 @@
if(I == src)
continue
var/mob/M = I.current
if(M && (M.z in GLOB.station_z_levels) && !M.stat)
if(M && is_station_level(M.z) && !M.stat)
last_healthy_headrev = FALSE
break
text += "head | not mindshielded | <a href='?src=[REF(src)];revolution=clear'>employee</a> | <b>[last_healthy_headrev ? "<font color='red'>LAST </font> " : ""]HEADREV</b> | <a href='?src=[REF(src)];revolution=rev'>rev</a>"