Allows admins to freeze the SM (#20616)

* allows admins to freeze the SM

* Hal9000 Review

* now works better than deleting frozen mobs!
This commit is contained in:
Coolrune206
2023-04-14 00:37:18 +10:00
committed by GitHub
parent ddbae79e7a
commit 7293b7ecbd
2 changed files with 22 additions and 0 deletions
@@ -212,6 +212,8 @@
SSair.atmos_machinery -= src
QDEL_NULL(radio)
GLOB.poi_list -= src
if(!processes)
GLOB.frozen_atom_list -= src
QDEL_NULL(countdown)
QDEL_NULL(soundloop)
return ..()
@@ -290,6 +292,11 @@
SEND_SOUND(M, sound('sound/machines/engine_alert2.ogg')) // then send them the sound file
radio.autosay(speaking, name, null, list(z))
for(var/i in SUPERMATTER_COUNTDOWN_TIME to 0 step -10)
if(!processes) // Stop exploding if you're frozen by an admin, damn you
cut_overlay(causality_field, TRUE)
final_countdown = FALSE
damage = explosion_point - 1 // One point below exploding, so it will re-start the countdown once unfrozen
return
if(damage < explosion_point) // Cutting it a bit close there engineers
radio.autosay("[safe_alert] Failsafe has been disengaged.", name, null, list(z))
cut_overlay(causality_field, TRUE)