Skip to content

Commit

Permalink
Blood loss fix (#8512)
Browse files Browse the repository at this point in the history
* Adds damage for bloodloss

* Fixees bloodloss

* Removes unneeded piece
  • Loading branch information
sgtmind authored Aug 16, 2024
1 parent 6910fda commit f564972
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
2 changes: 2 additions & 0 deletions code/modules/mob/living/carbon/human/life.dm
Original file line number Diff line number Diff line change
Expand Up @@ -813,6 +813,8 @@

//UNCONSCIOUS. NO-ONE IS HOME
if(getOxyLoss() > (species.total_health/2))
if(stat == CONSCIOUS)
to_chat(src, SPAN_DANGER("You feel your consciousness become increasingly distant from the physical world."))
Paralyse(3)

if(hallucination_power)
Expand Down
5 changes: 3 additions & 2 deletions code/modules/organs/internal/_internal.dm
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@

if(GetComponent(/datum/component/internal_wound/organic/parenchyma))
owner.mutation_index++

SEND_SIGNAL(src, COMSIG_ADDVAL)

/obj/item/organ/internal/proc/handle_organ_eff()
Expand Down Expand Up @@ -211,7 +211,8 @@
break
if(BV)
BV.current_blood = max(BV.current_blood - blood_req, 0)
if(!damage && BV?.current_blood == 0) //When all blood from the organ and blood vessel is lost,
var/datum/component/internal_wound/currentcomponent = GetExactComponent(/datum/component/internal_wound/organic/oxy/blood_loss)
if(!(BV?.current_blood) && !(currentcomponent?.name == "blood loss"))
add_wound(/datum/component/internal_wound/organic/oxy/blood_loss)

return
Expand Down
5 changes: 5 additions & 0 deletions code/modules/organs/internal/internal_organ_processes.dm
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,11 @@
adjustOxyLoss(20)
if(prob(15))
to_chat(src, SPAN_WARNING("You feel extremely [pick("dizzy","woosey","faint")]."))
else if(blood_volume < total_blood_req)
eye_blurry = max(eye_blurry,6)
adjustOxyLoss(4.5) // this damage threshold kills people with good airflow
if(prob(15))
to_chat(src, SPAN_WARNING("You feel highly [pick("dizzy","woosey","faint")]."))
else if(blood_volume < blood_bad)
eye_blurry = max(eye_blurry,6)
adjustOxyLoss(2)
Expand Down

0 comments on commit f564972

Please sign in to comment.