This commit is contained in:
Ty-Omaha
2019-03-30 21:22:01 -04:00
parent 250e8ec7b4
commit 5b443dd0ee
+7 -5
View File
@@ -1,16 +1,18 @@
/datum/event/grid_check //NOTE: Times are measured in master controller ticks!
announceWhen = 5
var/power_loss_sound = sound('sound/effects/powerloss.ogg')
/datum/event/grid_check/setup()
endWhen = rand(30,120)
/datum/event/grid_check/start()
power_failure(0)
for(var/mob/M in GLOB.player_list)
if(!M.client)
for(var/mob/living/M in GLOB.player_list)
var/turf/T = get_turf(M)
if(!M.client || !is_station_level(T.z))
continue
SEND_SOUND(M, sound('sound/effects/powerloss.ogg'))
SEND_SOUND(M, power_loss_sound)
/datum/event/grid_check/announce()
event_announcement.Announce("Abnormal activity detected in [station_name()]'s powernet. As a precautionary measure, the station's power will be shut off for an indeterminate duration.", "Automated Grid Check", new_sound = 'sound/AI/poweroff.ogg')