Fixes the shield check not defaulting to hit (#22806)

The result was meant to default to hit, it instead was just null.

Tested on shield-less people this time.


https://github.com/user-attachments/assets/bd0f9db5-1a29-46cd-9421-1c232cae0c9d
This commit is contained in:
FenodyreeAv
2026-07-11 15:47:28 +00:00
committed by GitHub
parent 5d59e4aabc
commit a4da3a8885
6 changed files with 65 additions and 19 deletions
@@ -152,6 +152,7 @@ emp_act
return null
/mob/living/carbon/human/check_shields(damage, atom/damage_source, mob/attacker, def_zone, attack_text = "the attack")
var/result = BULLET_ACT_HIT
for(var/obj/item/shield in list(l_hand, r_hand, wear_suit, back))
if(!shield)
continue
@@ -160,9 +161,10 @@ emp_act
if(!shield.can_shield_back())
continue
is_on_back = TRUE
return shield.handle_shield(src, is_on_back, damage, damage_source, attacker, def_zone, attack_text)
return BULLET_ACT_HIT
result = shield.handle_shield(src, is_on_back, damage, damage_source, attacker, def_zone, attack_text)
if (result == BULLET_ACT_FORCE_PIERCE || result == BULLET_ACT_BLOCK) //Necessary to handle multiple shields.
return result
return result
/mob/living/carbon/human/emp_act(severity)
/*