From c7aa8c1f3260708175fab2e707fa26b0492b51fd Mon Sep 17 00:00:00 2001 From: Xhuis Date: Tue, 4 Jul 2017 13:46:48 -0400 Subject: [PATCH] Fixes infinite heartbeat sounds --- code/modules/mob/dead/observer/observer.dm | 1 + code/modules/mob/living/carbon/human/death.dm | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/code/modules/mob/dead/observer/observer.dm b/code/modules/mob/dead/observer/observer.dm index b569685196b..befbcae7e4a 100644 --- a/code/modules/mob/dead/observer/observer.dm +++ b/code/modules/mob/dead/observer/observer.dm @@ -249,6 +249,7 @@ Works together with spawning an observer, noted above. /mob/proc/ghostize(can_reenter_corpse = 1) if(key) if(!cmptext(copytext(key,1,2),"@")) // Skip aghosts. + stop_sound_channel(CHANNEL_HEARTBEAT) //Stop heartbeat sounds because You Are A Ghost Now var/mob/dead/observer/ghost = new(src) // Transfer safety to observer spawning proc. SStgui.on_transfer(src, ghost) // Transfer NanoUIs. ghost.can_reenter_corpse = can_reenter_corpse diff --git a/code/modules/mob/living/carbon/human/death.dm b/code/modules/mob/living/carbon/human/death.dm index 04dba44ee5f..4547390f56b 100644 --- a/code/modules/mob/living/carbon/human/death.dm +++ b/code/modules/mob/living/carbon/human/death.dm @@ -19,6 +19,10 @@ /mob/living/carbon/human/death(gibbed) if(stat == DEAD) return + stop_sound_channel(CHANNEL_HEARTBEAT) + var/obj/item/organ/heart/H = getorganslot("heart") + if(H) + H.beat = BEAT_NONE . = ..()