mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-31 07:57:47 +01:00
Removes most hard-coded z level checks
This commit is contained in:
@@ -124,8 +124,7 @@ var/const/GRAV_NEEDS_WRENCH = 3
|
||||
O.main_part = null
|
||||
qdel(O)
|
||||
for(var/area/A in world)
|
||||
// TODO: Tie into space manager
|
||||
if(!(A.z in config.station_levels)) continue
|
||||
if(!is_station_level(A.z)) continue
|
||||
A.gravitychange(0,A)
|
||||
shake_everyone()
|
||||
return ..()
|
||||
@@ -302,8 +301,7 @@ var/const/GRAV_NEEDS_WRENCH = 3
|
||||
investigate_log("was brought online and is now producing gravity for this level.", "gravity")
|
||||
message_admins("The gravity generator was brought online. (<A HREF='?_src_=holder;adminplayerobservecoodjump=1;X=[x];Y=[y];Z=[z]'>[area.name]</a>)")
|
||||
for(var/area/A in world)
|
||||
// TODO: Tie into space manager
|
||||
if(!(A.z in config.station_levels)) continue
|
||||
if(!is_station_level(A.z)) continue
|
||||
A.gravitychange(1,A)
|
||||
else
|
||||
if(gravity_in_level() == 1)
|
||||
@@ -311,8 +309,7 @@ var/const/GRAV_NEEDS_WRENCH = 3
|
||||
investigate_log("was brought offline and there is now no gravity for this level.", "gravity")
|
||||
message_admins("The gravity generator was brought offline with no backup generator. (<A HREF='?_src_=holder;adminplayerobservecoodjump=1;X=[x];Y=[y];Z=[z]'>[area.name]</a>)")
|
||||
for(var/area/A in world)
|
||||
// TODO: Tie into space manager
|
||||
if(!(A.z in config.station_levels)) continue
|
||||
if(!is_station_level(A.z)) continue
|
||||
A.gravitychange(0,A)
|
||||
|
||||
update_icon()
|
||||
@@ -380,7 +377,7 @@ var/const/GRAV_NEEDS_WRENCH = 3
|
||||
shake_camera(M, 15, 1)
|
||||
M.playsound_local(our_turf, 'sound/effects/alert.ogg', 100, 1, 0.5)
|
||||
|
||||
// TODO: Tie into space manager
|
||||
// TODO: Make the gravity generator cooperate with the space manager
|
||||
/obj/machinery/gravity_generator/main/proc/gravity_in_level()
|
||||
var/turf/T = get_turf(src)
|
||||
if(!T)
|
||||
@@ -389,7 +386,6 @@ var/const/GRAV_NEEDS_WRENCH = 3
|
||||
return length(gravity_generators["[T.z]"])
|
||||
return 0
|
||||
|
||||
// TODO: Tie into space manager
|
||||
/obj/machinery/gravity_generator/main/proc/update_list()
|
||||
var/turf/T = get_turf(src.loc)
|
||||
if(T)
|
||||
|
||||
Reference in New Issue
Block a user