From 3e95b617ac4a0286481a84df4631b449a59ee2f8 Mon Sep 17 00:00:00 2001 From: ghostsheet Date: Thu, 20 Jul 2023 16:50:35 +1000 Subject: [PATCH] Synth Hammer delay and warning --- code/game/objects/items/weapons/twohanded.dm | 26 +++++++++++--------- 1 file changed, 15 insertions(+), 11 deletions(-) diff --git a/code/game/objects/items/weapons/twohanded.dm b/code/game/objects/items/weapons/twohanded.dm index 0c88b61fafbe..2dd31507c0d3 100644 --- a/code/game/objects/items/weapons/twohanded.dm +++ b/code/game/objects/items/weapons/twohanded.dm @@ -323,25 +323,29 @@ item_state = "syn_breacher" force_wielded = MELEE_FORCE_VERY_STRONG really_heavy = TRUE + var/move_delay_addition = 1.5 /obj/item/weapon/twohanded/breacher/synth/pickup(mob/user) if(!(HAS_TRAIT(user, TRAIT_SUPER_STRONG))) - to_chat(user, SPAN_WARNING("You barely manage to lift \the [src] above your knees. This thing will probably be useless to you.")) - user.apply_effect(1.1, SLOW) - START_PROCESSING(SSobj, src) + to_chat(user, SPAN_HIGHDANGER("You barely manage to lift \the [src] above your knees. This thing will probably be useless to you.")) + user.apply_effect(6, EYE_BLUR) + user.apply_effect(3, DAZE) + user.emote("pain") + RegisterSignal(user, COMSIG_HUMAN_POST_MOVE_DELAY, PROC_REF(handle_movedelay)) + return ..() +/obj/item/weapon/twohanded/breacher/synth/proc/handle_movedelay(mob/living/M, list/movedata) + SIGNAL_HANDLER + movedata["move_delay"] += move_delay_addition + +/obj/item/weapon/twohanded/breacher/synth/dropped(mob/user, silent) + . = ..() + UnregisterSignal(user, COMSIG_HUMAN_POST_MOVE_DELAY) + /obj/item/weapon/twohanded/breacher/synth/attack(target as mob, mob/living/user as mob) if(!HAS_TRAIT(user, TRAIT_SUPER_STRONG)) to_chat(user, SPAN_WARNING("\The [src] is too heavy for you to use as a weapon!")) return ..() - -/obj/item/weapon/twohanded/breacher/synth/process() - var/mob/user = src.loc - if(istype(user) && !(HAS_TRAIT(user, TRAIT_SUPER_STRONG))) - user.apply_effect(1.1, SLOW) - return - - STOP_PROCESSING(SSobj, src)