From 0f38fbfdb262de960bdeb562006afce163d01e8d Mon Sep 17 00:00:00 2001 From: Archie Date: Thu, 6 May 2021 05:18:51 -0300 Subject: [PATCH] RBMK Ambient sound --- code/datums/looping_sounds/machinery_sounds.dm | 7 ++++++- hyperstation/code/modules/power/reactor/rbmk.dm | 4 ++++ 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/code/datums/looping_sounds/machinery_sounds.dm b/code/datums/looping_sounds/machinery_sounds.dm index f9a9e07a..882ca4ba 100644 --- a/code/datums/looping_sounds/machinery_sounds.dm +++ b/code/datums/looping_sounds/machinery_sounds.dm @@ -51,4 +51,9 @@ mid_sounds = list('sound/machines/fryer/deep_fryer_1.ogg' = 1, 'sound/machines/fryer/deep_fryer_2.ogg' = 1) volume = 10 -/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// \ No newline at end of file +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/datum/looping_sound/rbmk_reactor + mid_length = 16 + mid_sounds = list('hyperstation/sound/effects/rbmk/reactor_hum.ogg' = 10) + volume = 10 diff --git a/hyperstation/code/modules/power/reactor/rbmk.dm b/hyperstation/code/modules/power/reactor/rbmk.dm index 70ae2d28..b1ae36aa 100644 --- a/hyperstation/code/modules/power/reactor/rbmk.dm +++ b/hyperstation/code/modules/power/reactor/rbmk.dm @@ -68,6 +68,7 @@ The reactor CHEWS through moderator. It does not do this slowly. Be very careful */ //Remember kids. If the reactor itself is not physically powered by an APC, it cannot shove coolant in! +/var/datum/looping_sound/rbmk_reactor/soundloop /obj/machinery/atmospherics/components/trinary/nuclear_reactor name = "Advanced Gas-Cooled Nuclear Reactor" @@ -468,6 +469,7 @@ The reactor CHEWS through moderator. It does not do this slowly. Be very careful T.assume_air(coolant_output) explosion(get_turf(src), 0, 5, 10, 20, TRUE, TRUE) empulse(get_turf(src), 25, 15) + QDEL_NULL(soundloop) //Failure condition 2: Blowout. Achieved by reactor going over-pressured. This is a round-ender because it requires more fuckery to achieve. /obj/machinery/atmospherics/components/trinary/nuclear_reactor/proc/blowout() @@ -507,6 +509,7 @@ The reactor CHEWS through moderator. It does not do this slowly. Be very careful set_light(10) var/startup_sound = pick('hyperstation/sound/effects/ship/reactor/startup.ogg', 'hyperstation/sound/effects/ship/reactor/startup2.ogg') playsound(loc, startup_sound, 100) + soundloop = new(list(src), TRUE) if(!powernet) message_admins("No powernet for the Nuclear Reactor! Trying to add.") connect_to_network() @@ -521,6 +524,7 @@ The reactor CHEWS through moderator. It does not do this slowly. Be very careful desired_k = 0 temperature = 0 update_icon() + QDEL_NULL(soundloop) /obj/item/twohanded/required/fuel_rod name = "Uranium-235 Fuel Rod"