[MIRROR] Fixes security level alerts playing the incorrect sounds [MDB IGNORE] (#15116)

* Fixes security level alerts playing the incorrect sounds

* Fixes the merge conflict

* Slightly improves the code on our end, adds the documentation that we were now missing

Co-authored-by: MrMelbert <51863163+MrMelbert@users.noreply.github.com>
Co-authored-by: GoldenAlpharex <jerego1234@hotmail.com>
This commit is contained in:
SkyratBot
2022-07-23 16:26:40 -04:00
committed by GitHub
co-authored by MrMelbert GoldenAlpharex
parent 282113a198
commit ca20cbb5a1
4 changed files with 49 additions and 18 deletions
+2 -4
View File
@@ -68,11 +68,9 @@ SUBSYSTEM_DEF(security_level)
*/
/datum/controller/subsystem/security_level/proc/announce_security_level(datum/security_level/selected_level)
if(selected_level.number_level > current_security_level.number_level) // We are elevating to this level.
minor_announce(selected_level.elevating_to_announcemnt, "Attention! Security level elevated to [selected_level.name]:")
minor_announce(selected_level.elevating_to_announcemnt, "Attention! Security level elevated to [selected_level.name]:", sound_override = selected_level.sound)
else // Going down
minor_announce(selected_level.lowering_to_announcement, "Attention! Security level lowered to [selected_level.name]:")
if(selected_level.sound)
sound_to_playing_players(selected_level.sound)
minor_announce(selected_level.lowering_to_announcement, "Attention! Security level lowered to [selected_level.name]:", sound_override = selected_level.sound)
/**
* Returns the current security level as a number