mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-19 19:13:30 +01:00
Buffs stun absorption to stop disarms. (#18126)
* Disarm is now stopped by stun absorption * update comment
This commit is contained in:
@@ -633,7 +633,11 @@ emp_act
|
||||
add_attack_logs(M, src, "Alien attacked")
|
||||
updatehealth("alien attack")
|
||||
|
||||
if(M.a_intent == INTENT_DISARM) //Always drop item in hand, if no item, get stun instead.
|
||||
if(M.a_intent == INTENT_DISARM) //If not absorbed, always drop item in hand, if no item, get stun instead.
|
||||
if(absorb_stun(0))
|
||||
visible_message("<span class='warning'>[src] is not affected by [M]'s disarm attempt!</span>")
|
||||
playsound(loc, 'sound/weapons/punchmiss.ogg', 25, 1, -1)
|
||||
return FALSE
|
||||
var/obj/item/I = get_active_hand()
|
||||
if(I && unEquip(I))
|
||||
playsound(loc, 'sound/weapons/slash.ogg', 25, TRUE, -1)
|
||||
|
||||
@@ -513,6 +513,11 @@
|
||||
if(target.check_block())
|
||||
target.visible_message("<span class='warning'>[target] blocks [user]'s disarm attempt!</span>")
|
||||
return FALSE
|
||||
if(target.absorb_stun(0))
|
||||
target.visible_message("<span class='warning'>[target] is not affected by [user]'s disarm attempt!</span>")
|
||||
user.do_attack_animation(target, ATTACK_EFFECT_DISARM)
|
||||
playsound(target.loc, 'sound/weapons/punchmiss.ogg', 25, 1, -1)
|
||||
return FALSE
|
||||
if(attacker_style && attacker_style.disarm_act(user, target) == TRUE)
|
||||
return TRUE
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user