From a512c62637c682ea4462be87d6563a3bdb1edae6 Mon Sep 17 00:00:00 2001 From: Heroman Date: Wed, 25 Sep 2019 19:39:35 +1000 Subject: [PATCH] Makes lightning strikes respect weather sound pref --- code/modules/admin/verbs/lightning_strike.dm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/code/modules/admin/verbs/lightning_strike.dm b/code/modules/admin/verbs/lightning_strike.dm index 6adb122d4a..1981e3f0d8 100644 --- a/code/modules/admin/verbs/lightning_strike.dm +++ b/code/modules/admin/verbs/lightning_strike.dm @@ -65,7 +65,8 @@ var/sound = get_sfx("thunder") for(var/mob/M in player_list) if((P && M.z in P.expected_z_levels) || M.z == T.z) - M.playsound_local(get_turf(M), soundin = sound, vol = 70, vary = FALSE, is_global = TRUE) + if(M.is_preference_enabled(/datum/client_preference/weather_sounds)) + M.playsound_local(get_turf(M), soundin = sound, vol = 70, vary = FALSE, is_global = TRUE) if(cosmetic) // Everything beyond here involves potentially damaging things. If we don't want to do that, stop now. return