mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-23 05:00:55 +01:00
Lung cleanup ft. minor suffocation tweak (#96659)
## About The Pull Request ### Notable changes Before: When taking suffocation damage, 3 oxyloss damage is dealt, or 0.66 damage if below 0 health (soft crit threshold). If below 0 hp, and you have `NOCRITDAMAGE`, gets nullified. After: When taking suffocation damage, 3 oxyloss damage is dealt, reduced if you had a partially successful breath (i.e. 75% of a breath = 0.25x damage) or are in soft crit or hard crit (0.22x less damage). If in crit, and you have `NOCRITDAMAGE`, gets nullified. Before: You skip 1 in every 4 breaths when your health is below 0 (soft crit threshold), and skip every breath when your health is below -30 (hard crit threshold) After: You skip 1 in every 4 breaths when in soft crit, and skip every breath when in hard crit Before: You don't heal from successful breaths when below 0 health (soft crit threshold) After: You don't heal from successful breaths when in soft or hard crit ### Other changes - Removed `gasp` from losebreath processing, ie removed chance to gasp twice in one tick when choking. - Deletes `respiration_type`s - Deletes `crit_stabilizing_reagent` - Deletes species `breathid`, replaces it with `get_breath_type` that checks the species' lungs ## Why It's Good For The Game - There was a strange inconsistency where being in crit would drastically reduce the amount of suffocation damage you were dealt, but only if you were not breathing. If you were somehow breathing, you took the full damage. I thought this was a little obtuse, so I wanted to change it to be consistent: Being in crit is just a multiplier. - Making them check for `stat` instead of `health` means they affect people with `NO_SOFTCRIT` or `NO_HARDCRIT` nicer. - See above. - Really just to be cleaner, handle gasping in one place. - I'm not sure why we have `respiration_type`. The only time they're (practically) referred to is in reagent handling, but there are no reagents that set it anything but `ALL`. All it does is make our oxyloss handling made more complicated and harder to read for no purpose. So I decided to axe it - I think anything special handing that should arise should just have some bespoke checks instead. - Nothing set this value to anything else. And guess what, if you changed it, epinephrine still worked because it applies `NO_CRITDAMAGE`. - Species de-hardcoding. Makes it easier to add new breath types. ## Changelog 🆑 Melbert balance: Suffocation damage is slightly more consistent now: You take 3 oxyloss per suffocation tick, reduced for partially successful breaths and or if you are in crit. Alternatively, if you are in crit and you have epinephrine/atropine in your system, it gets nullified entirely. code: Cleaned up lungs a bit, particularly relating to abnormal lungs like plasmamen or fish, report any oddities with them. del: You no longer have a chance to gasp twice in one suffocation tick. /🆑 --------- Co-authored-by: Ghom <42542238+Ghommie@users.noreply.github.com> Co-authored-by: san7890 <the@san7890.com>
This commit is contained in:
co-authored by
Ghom
san7890
parent
94ecd1d5a6
commit
cb87e54d93
@@ -39,8 +39,8 @@
|
||||
else if(damage_coeff[BURN])
|
||||
. = adjust_health(amount * damage_coeff[BURN] * CONFIG_GET(number/damage_multiplier), updating_health, forced)
|
||||
|
||||
/mob/living/basic/adjust_oxy_loss(amount, updating_health = TRUE, forced = FALSE, required_biotype, required_respiration_type)
|
||||
if(!can_adjust_oxy_loss(amount, forced, required_biotype, required_respiration_type))
|
||||
/mob/living/basic/adjust_oxy_loss(amount, updating_health = TRUE, forced = FALSE, required_biotype)
|
||||
if(!can_adjust_oxy_loss(amount, forced, required_biotype))
|
||||
return 0
|
||||
if(forced)
|
||||
. = adjust_health(amount * CONFIG_GET(number/damage_multiplier), updating_health, forced)
|
||||
|
||||
Reference in New Issue
Block a user