From 82194574f563e71d0cf7b3d17b70025f2a356de0 Mon Sep 17 00:00:00 2001 From: Vallidian Date: Mon, 5 Apr 2021 12:49:27 -0400 Subject: [PATCH] SM Delam station wide siren (#15758) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * SM Delam station wide siren Adds some fluff to the SM when it hits 0 integrity. Sounds a global siren signifying a "meltdown" or delam is imminent. 🆑 add: adds a global siren shortly before delam. /🆑 * Adding zlevel check for alarm Thank you hal9000 and kyet for helping :) Co-authored-by: Kyep <16434066+Kyep@users.noreply.github.com> Co-authored-by: Kyep <16434066+Kyep@users.noreply.github.com> --- code/modules/power/supermatter/supermatter.dm | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/code/modules/power/supermatter/supermatter.dm b/code/modules/power/supermatter/supermatter.dm index aa4ae90d380..5d505554c84 100644 --- a/code/modules/power/supermatter/supermatter.dm +++ b/code/modules/power/supermatter/supermatter.dm @@ -280,6 +280,10 @@ add_overlay(causality_field, TRUE) var/speaking = "[emergency_alert] The supermatter has reached critical integrity failure. Emergency causality destabilization field has been activated." + for(var/mob/M in GLOB.player_list) // for all players + var/turf/T = get_turf(M) + if(istype(T) && atoms_share_level(T, src)) // if the player is on the same zlevel as the SM shared + 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(damage < explosion_point) // Cutting it a bit close there engineers