Skip to content

Commit

Permalink
[MIRROR] Fix all types of damage to the head causing brain damage (#2140
Browse files Browse the repository at this point in the history
)

* Fix all types of damage to the head causing brain damage (#82763)

## About The Pull Request

5 months ago when I separated this stuff out to its own proc I forgot a
damagetype check.

## Changelog

:cl: Melbert
fix: Only brute damage causes brain damage when applied to the forehead,
rather than all damage types
/:cl:

* Fix all types of damage to the head causing brain damage

---------

Co-authored-by: MrMelbert <[email protected]>
  • Loading branch information
2 people authored and StealsThePRs committed Apr 23, 2024
1 parent df3285b commit 1172370
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions code/_onclick/item_attack.dm
Original file line number Diff line number Diff line change
Expand Up @@ -387,7 +387,7 @@
glasses.add_mob_blood(src)
update_worn_glasses()

if(!attacking_item.get_sharpness() && !HAS_TRAIT(src, TRAIT_HEAD_INJURY_BLOCKED))
if(!attacking_item.get_sharpness() && !HAS_TRAIT(src, TRAIT_HEAD_INJURY_BLOCKED) && attacking_item.damtype == BRUTE)
if(prob(damage_done))
adjustOrganLoss(ORGAN_SLOT_BRAIN, 20)
if(stat == CONSCIOUS)
Expand Down Expand Up @@ -417,7 +417,7 @@
w_uniform.add_mob_blood(src)
update_worn_undersuit()

if(stat == CONSCIOUS && !attacking_item.get_sharpness() && !HAS_TRAIT(src, TRAIT_BRAWLING_KNOCKDOWN_BLOCKED))
if(stat == CONSCIOUS && !attacking_item.get_sharpness() && !HAS_TRAIT(src, TRAIT_BRAWLING_KNOCKDOWN_BLOCKED) && attacking_item.damtype == BRUTE)
if(prob(damage_done))
visible_message(
span_danger("[src] is knocked down!"),
Expand Down

0 comments on commit 1172370

Please sign in to comment.