[MIRROR] Proper MaxHealth checks and Crit Point (#10881)

Co-authored-by: Cameron Lennox <killer65311@gmail.com>
This commit is contained in:
CHOMPStation2StaffMirrorBot
2025-05-16 00:25:21 -07:00
committed by GitHub
parent 901dc552fc
commit 4ce45f8cc4
46 changed files with 92 additions and 94 deletions

View File

@@ -37,7 +37,7 @@
C.does_not_breathe = 0 //This means they don't autoheal the oxy damage from the next step
if(C.stat != DEAD)
C.adjustOxyLoss(C.maxHealth * 2)
C.adjustOxyLoss(C.getMaxHealth() * 2)
C.forbid_seeing_deadchat = TRUE

View File

@@ -23,7 +23,7 @@
var/mob/living/carbon/human/C = src
var/healing_amount = 40
if(src.mind.changeling.recursive_enhancement)
healing_amount = C.maxHealth
healing_amount = C.getMaxHealth()
to_chat(src, span_notice("We completely heal ourselves."))
spawn(0)
C.adjustBruteLoss(-healing_amount)

View File

@@ -109,7 +109,7 @@
if(src.imprinted != "empty")
to_chat(U, span_danger("Capture failed!") + ": The soul stone has already been imprinted with [src.imprinted]'s mind!")
return
if ((T.health + T.halloss) > CONFIG_GET(number/health_threshold_crit) && T.stat != DEAD)
if ((T.health + T.halloss) > T.get_crit_point() && T.stat != DEAD)
to_chat(U, span_danger("Capture failed!") + ": Kill or maim the victim first!")
return
if(T.client == null)

View File

@@ -50,7 +50,7 @@
/obj/item/inserted_spell/asphyxiation/on_expire()
..()
// if((getOxyLoss() > (species.total_health/2)) || (health <= config.health_threshold_crit))
// if((getOxyLoss() > (species.total_health/2)) || (health <= get_crit_point())
/obj/item/inserted_spell/asphyxiation/proc/predict_crit(var/pulses_remaining, var/mob/living/carbon/human/victim, var/previous_damage = 0)
if(pulses_remaining <= 0) // Infinite loop protection