From 77c6999f1acbc84c124416e3679d395477aab9c4 Mon Sep 17 00:00:00 2001 From: morrowwolf Date: Tue, 1 Aug 2023 13:28:09 -0400 Subject: [PATCH] Fixes brain surgery so it actually fixes your brain (#4061) # About the pull request Not using the proc to change damage? That's a paddlin'. # Explain why it's good for the game Bug bad # Testing Photographs and Procedure
Screenshots & Videos Put screenshots and videos here with an empty line between the screenshots and the `
` tags.
# Changelog :cl: Morrow fix: Fixes brain damage qol: Jittering from brain damage is now capped /:cl: --- code/modules/organs/organ_internal.dm | 3 ++- code/modules/surgery/brainrepair.dm | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/code/modules/organs/organ_internal.dm b/code/modules/organs/organ_internal.dm index 5325e89910ba..2178e2d53f5c 100644 --- a/code/modules/organs/organ_internal.dm +++ b/code/modules/organs/organ_internal.dm @@ -258,7 +258,8 @@ if(organ_status >= ORGAN_BROKEN && prob(5 * delta_time)) owner.apply_effect(1, PARALYZE) - owner.make_jittery(50) + if(owner.jitteriness < 100) + owner.make_jittery(50) to_chat(owner, SPAN_DANGER("Your body seizes up!")) /datum/internal_organ/brain/prosthetic //used by synthetic species diff --git a/code/modules/surgery/brainrepair.dm b/code/modules/surgery/brainrepair.dm index 6d3060c2a4a6..2b4e51292203 100644 --- a/code/modules/surgery/brainrepair.dm +++ b/code/modules/surgery/brainrepair.dm @@ -55,10 +55,11 @@ var/datum/internal_organ/brain/B = target.internal_organs_by_name["brain"] if(B) - B.damage = 0 + B.heal_damage(B.damage) target.disabilities &= ~NERVOUS target.sdisabilities &= ~DISABILITY_DEAF target.sdisabilities &= ~DISABILITY_MUTE + target.jitteriness = 0 target.pain.recalculate_pain() log_interact(user, target, "[key_name(user)] finished taking bone chips out of [key_name(target)]'s brain with \the [tool], finishing [surgery].")