Skip to content

Commit

Permalink
[MIRROR] fixes oxyloss not knocking people out at 50 [MDB IGNORE] (#2…
Browse files Browse the repository at this point in the history
…4442) (#158)

* fixes oxyloss not knocking people out at 50 (#79036)

## About The Pull Request

be it far from me to explain why the args not getting put in directly
broke this, but reinserting them into the check_passout stuff from
#78657 fixes it.

should close #79034 but I have no clue if other similar changes to how
args were being handled might not have problems elsewhere.

## Why It's Good For The Game

atmospheric simulator, breathing mechanics good, also chems and i guess
bleeding and whatnot

## Changelog

:cl:
fix: automatic breathers rejoice. oxyloss now knocks people out again.
/:cl:

* fixes oxyloss not knocking people out at 50

---------

Co-authored-by: SkyratBot <[email protected]>
Co-authored-by: Higgin <[email protected]>
  • Loading branch information
3 people authored Oct 20, 2023
1 parent 56279d2 commit 461575f
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions code/modules/mob/living/carbon/carbon_defense.dm
Original file line number Diff line number Diff line change
Expand Up @@ -778,15 +778,14 @@
check_passout()

/**
* Check to see if we should be passed out from oyxloss
* Check to see if we should be passed out from oxyloss
*/
/mob/living/carbon/proc/check_passout()
if(!isnum(oxyloss))
return
if(oxyloss <= 50)
if(getOxyLoss() > 50)
var/mob_oxyloss = getOxyLoss()
if(mob_oxyloss >= 50)
if(!HAS_TRAIT_FROM(src, TRAIT_KNOCKEDOUT, OXYLOSS_TRAIT))
ADD_TRAIT(src, TRAIT_KNOCKEDOUT, OXYLOSS_TRAIT)
else if(getOxyLoss() <= 50)
else if(mob_oxyloss < 50)
REMOVE_TRAIT(src, TRAIT_KNOCKEDOUT, OXYLOSS_TRAIT)

/mob/living/carbon/get_organic_health()
Expand Down

0 comments on commit 461575f

Please sign in to comment.