From 68a67c703c267ea5e0fa303c2843eb54ee04f5b3 Mon Sep 17 00:00:00 2001 From: CitadelStationBot Date: Tue, 18 Apr 2017 18:09:51 -0500 Subject: [PATCH] Stethoscope fixes --- code/modules/clothing/neck/ties.dm | 43 ++++++++++++------------------ 1 file changed, 17 insertions(+), 26 deletions(-) diff --git a/code/modules/clothing/neck/ties.dm b/code/modules/clothing/neck/ties.dm index 7c5086a999..59dc504098 100644 --- a/code/modules/clothing/neck/ties.dm +++ b/code/modules/clothing/neck/ties.dm @@ -38,35 +38,26 @@ if(ishuman(M) && isliving(user)) if(user.a_intent == INTENT_HELP) var/body_part = parse_zone(user.zone_selected) - if(body_part) - var/their = "their" - switch(M.gender) - if(MALE) - their = "his" - if(FEMALE) - their = "her" - var/sound = "pulse" - var/sound_strength + var/heart_strength = "no" + var/lung_strength = "no" - if(M.stat == DEAD || (M.status_flags&FAKEDEATH)) - sound_strength = "cannot hear" - sound = "anything" - else - sound_strength = "hear a weak" - switch(body_part) - if("chest") - if(M.oxyloss < 50) - sound_strength = "hear a healthy" - sound = "pulse and respiration" - if("eyes","mouth") - sound_strength = "cannot hear" - sound = "anything" - else - sound_strength = "hear a weak" + var/obj/item/organ/heart/heart = M.getorganslot("heart") + var/obj/item/organ/lungs/lungs = M.getorganslot("lungs") - user.visible_message("[user] places [src] against [M]'s [body_part] and listens attentively.", "You place [src] against [their] [body_part]. You [sound_strength] [sound].") - return + if(!(M.stat == DEAD || (M.status_flags&FAKEDEATH))) + if(heart && istype(heart)) + heart_strength = "an unstable" + if(heart.beating) + heart_strength = "a healthy" + if(lungs && istype(lungs)) + lung_strength = "strained" + if(!(M.failed_last_breath || M.losebreath)) + lung_strength = "healthy" + + var/diagnosis = (body_part == "chest" ? "You hear [heart_strength] pulse and [lung_strength] respiration." : "You faintly hear [heart_strength] pulse.") + user.visible_message("[user] places [src] against [M]'s [body_part] and listens attentively.", "You place [src] against [M]'s [body_part]. [diagnosis]") + return return ..(M,user) ///////////