mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-25 14:00:18 +01:00
Refactor Get Pain (#22847)
This PR refactors get_pain() to be essentially performance free. Previously it was a member of the top 5 most expensive procs. I had to touch a metric shitton of files to make this happen. Notably get_pain() was also 1/3rd of the entire processing cost for Mobs - Life
This commit is contained in:
@@ -405,7 +405,7 @@
|
||||
if(ishuman(G.affecting))
|
||||
var/mob/living/carbon/human/human_shield = G.affecting
|
||||
var/obj/item/organ/external/organ = human_shield.get_organ(def_zone)
|
||||
if(organ.burn_dam + organ.brute_dam > organ.max_damage) //If the hit zone is above the max damage threshold, the shot hits both.
|
||||
if(LIMB_GET_BURN_DAMAGE(organ) + LIMB_GET_BRUTE_DAMAGE(organ) > organ.max_damage) //If the hit zone is above the max damage threshold, the shot hits both.
|
||||
penetrating += 1
|
||||
projectile_piercing = PASSMOB
|
||||
pierce_chance = 100
|
||||
|
||||
Reference in New Issue
Block a user