diff --git a/code/modules/surgery/organs/lungs.dm b/code/modules/surgery/organs/lungs.dm index 1a2496bbb05..57879cd6203 100644 --- a/code/modules/surgery/organs/lungs.dm +++ b/code/modules/surgery/organs/lungs.dm @@ -11,8 +11,10 @@ healing_factor = STANDARD_ORGAN_HEALING decay_factor = STANDARD_ORGAN_DECAY + low_threshold_passed = "You feel short of breath." high_threshold_passed = "You feel some sort of constriction around your chest as your breathing becomes shallow and rapid." now_fixed = "Your lungs seem to once again be able to hold air." + low_threshold_cleared = "You can breathe normally again." high_threshold_cleared = "The constriction around your chest loosens as your breathing calms down." @@ -395,15 +397,17 @@ breath.temperature = H.bodytemperature /obj/item/organ/lungs/on_life() - ..() - if((!failed) && ((organ_flags & ORGAN_FAILING))) - if(owner.stat == CONSCIOUS) - owner.visible_message("[owner] grabs [owner.p_their()] throat, struggling for breath!", \ - "You suddenly feel like you can't breathe!") - failed = TRUE - else if(!(organ_flags & ORGAN_FAILING)) + . = ..() + if(failed && !(organ_flags & ORGAN_FAILING)) failed = FALSE - return + return + if(damage >= low_threshold) + var/do_i_cough = damage < high_threshold ? prob(5) : prob(10) // between : past high + if(do_i_cough) + owner.emote("cough") + if(organ_flags & ORGAN_FAILING && owner.stat == CONSCIOUS) + owner.visible_message("[owner] grabs [owner.p_their()] throat, struggling for breath!", "You suddenly feel like you can't breathe!") + failed = TRUE /obj/item/organ/lungs/plasmaman