From d3e808f0e122e36438a3ea19fcb7df7dbef24922 Mon Sep 17 00:00:00 2001 From: silicons <2003111+silicons@users.noreply.github.com> Date: Sun, 26 Jul 2020 00:18:42 -0700 Subject: [PATCH] fix --- code/_onclick/other_mobs.dm | 4 ++-- code/game/objects/items/stunbaton.dm | 4 +++- code/game/objects/structures.dm | 1 + 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/code/_onclick/other_mobs.dm b/code/_onclick/other_mobs.dm index a4b5b92397..df1f8222b9 100644 --- a/code/_onclick/other_mobs.dm +++ b/code/_onclick/other_mobs.dm @@ -44,14 +44,14 @@ if(attack_hand_speed) if(!user.CheckActionCooldown(attack_hand_speed)) return + if(interaction_flags_atom & INTERACT_ATOM_ATTACK_HAND) + . = _try_interact(user) on_attack_hand(user, act_intent, unarmed_attack_flags) if(attack_hand_unwieldlyness) user.DelayNextAction(attack_hand_unwieldlyness, considered_action = attack_hand_is_action) return attack_hand_is_action /atom/proc/on_attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags) - if(interaction_flags_atom & INTERACT_ATOM_ATTACK_HAND) - . = _try_interact(user) //Return a non FALSE value to cancel whatever called this from propagating, if it respects it. /atom/proc/_try_interact(mob/user) diff --git a/code/game/objects/items/stunbaton.dm b/code/game/objects/items/stunbaton.dm index c9526a5fc9..1a84b85a1a 100644 --- a/code/game/objects/items/stunbaton.dm +++ b/code/game/objects/items/stunbaton.dm @@ -145,6 +145,8 @@ return ..() /obj/item/melee/baton/alt_pre_attack(atom/A, mob/living/user, params) + if(!user.CheckActionCooldown(CLICK_CD_MELEE)) + return . = common_baton_melee(A, user, TRUE) //return true (attackchain interrupt) if this also returns true. no harm-disarming. //return TRUE to interrupt attack chain. @@ -156,13 +158,13 @@ if(IS_STAMCRIT(user)) //CIT CHANGE - makes it impossible to baton in stamina softcrit to_chat(user, "You're too exhausted to use [src] properly.") return TRUE + user.DelayNextAction() if(ishuman(M)) var/mob/living/carbon/human/L = M if(check_martial_counter(L, user)) return TRUE if(turned_on) if(baton_stun(M, user, disarming)) - user.DelayNextAction() user.do_attack_animation(M) user.adjustStaminaLossBuffered(getweight(user, STAM_COST_BATON_MOB_MULT)) else if(user.a_intent != INTENT_HARM) //they'll try to bash in the last proc. diff --git a/code/game/objects/structures.dm b/code/game/objects/structures.dm index 0057bebf99..39f2d276a1 100644 --- a/code/game/objects/structures.dm +++ b/code/game/objects/structures.dm @@ -29,6 +29,7 @@ return ..() /obj/structure/on_attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags) + . = ..() if(structureclimber && structureclimber != user) user.DelayNextAction(CLICK_CD_MELEE) user.do_attack_animation(src)