From ae2e30ac29f95dffd6d8e7eb09a5c2961e5add6b Mon Sep 17 00:00:00 2001 From: MrMelbert <51863163+MrMelbert@users.noreply.github.com> Date: Thu, 22 May 2025 02:03:19 -0500 Subject: [PATCH] Adds an `isliving` check to baton afterattack (#91254) ## About The Pull Request Very simple fix, afterattack is called for atom attacks - I forgot to isliving here Fixes #91253 ## Changelog :cl: Melbert fix: You (can't) baton furniture /:cl: --- code/game/objects/items/melee/baton.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/game/objects/items/melee/baton.dm b/code/game/objects/items/melee/baton.dm index 50268c1199d..157ef363339 100644 --- a/code/game/objects/items/melee/baton.dm +++ b/code/game/objects/items/melee/baton.dm @@ -153,7 +153,7 @@ // This is where stun gets applied /obj/item/melee/baton/afterattack(atom/target, mob/user, list/modifiers, list/attack_modifiers) - if(!active || !COOLDOWN_FINISHED(src, cooldown_check) || HAS_TRAIT_FROM(target, TRAIT_IWASBATONED, REF(user))) + if(!isliving(target) || !active || !COOLDOWN_FINISHED(src, cooldown_check) || HAS_TRAIT_FROM(target, TRAIT_IWASBATONED, REF(user))) return // worst check in the chain but - right click = harmbaton if(LAZYACCESS(modifiers, RIGHT_CLICK) && !stun_on_harmbaton)