From e37a7142416ba2acbe009bb7f3163f209a4af64f Mon Sep 17 00:00:00 2001 From: emmanuelbassil <6874235+emmanuelbassil@users.noreply.github.com> Date: Sun, 7 Jan 2024 22:22:46 +0300 Subject: [PATCH] [MIRROR] Fixes hardsuit flash and pipe placing --- code/game/machinery/pipe/construction.dm | 2 +- code/modules/atmospherics/pipes.dm | 4 ++++ code/modules/clothing/spacesuits/rig/modules/combat.dm | 2 +- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/code/game/machinery/pipe/construction.dm b/code/game/machinery/pipe/construction.dm index ea2fc0229a1aa..fbe78ad8fd111 100644 --- a/code/game/machinery/pipe/construction.dm +++ b/code/game/machinery/pipe/construction.dm @@ -41,7 +41,7 @@ Buildable meters //called when a turf is attacked with a pipe item /obj/item/pipe/use_after(atom/target, mob/living/user, click_parameters) - if (istype(target)) + if (istype(target, /turf/simulated/floor)) user.unEquip(src, target) return TRUE diff --git a/code/modules/atmospherics/pipes.dm b/code/modules/atmospherics/pipes.dm index a3d9bbe7c94b6..f68adf3deaa56 100644 --- a/code/modules/atmospherics/pipes.dm +++ b/code/modules/atmospherics/pipes.dm @@ -102,6 +102,10 @@ . = ..() /obj/machinery/atmospherics/pipe/use_tool(obj/item/W, mob/living/user, list/click_params) + if (istype(W, /obj/item/pipe)) + user.unEquip(W, loc) + return TRUE + if (!isWrench(W)) return ..() diff --git a/code/modules/clothing/spacesuits/rig/modules/combat.dm b/code/modules/clothing/spacesuits/rig/modules/combat.dm index c9fdf21ae571b..518a31834227d 100644 --- a/code/modules/clothing/spacesuits/rig/modules/combat.dm +++ b/code/modules/clothing/spacesuits/rig/modules/combat.dm @@ -67,7 +67,7 @@ if(!target.Adjacent(holder.wearer) || !ismob(target)) return 0 - var/resolved = target.attackby(device,holder.wearer) + var/resolved = device.resolve_attackby(target,holder.wearer) if(resolved) holder.cell.use(use_power_cost * CELLRATE) return resolved