Skip to content

Commit

Permalink
Fixes brain surgery so it actually fixes your brain (#4061)
Browse files Browse the repository at this point in the history
# 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
<details>
<summary>Screenshots & Videos</summary>

Put screenshots and videos here with an empty line between the
screenshots and the `<details>` tags.

</details>


# Changelog

:cl: Morrow
fix: Fixes brain damage
qol: Jittering from brain damage is now capped
/:cl:
  • Loading branch information
morrowwolf authored Aug 1, 2023
1 parent 239786c commit 77c6999
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion code/modules/organs/organ_internal.dm
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
3 changes: 2 additions & 1 deletion code/modules/surgery/brainrepair.dm
Original file line number Diff line number Diff line change
Expand Up @@ -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].")
Expand Down

0 comments on commit 77c6999

Please sign in to comment.