From ee88c5bcd5c678a87c9488d7338da1fcee279dc8 Mon Sep 17 00:00:00 2001 From: SkyratBot <59378654+SkyratBot@users.noreply.github.com> Date: Mon, 28 Aug 2023 23:31:53 +0200 Subject: [PATCH] [MIRROR] [No GBP] fixes railing deconstruction giving free iron [MDB IGNORE] (#23387) * [No GBP] fixes railing deconstruction giving free iron (#77953) whoops ## About The Pull Request i forgot to set the deconstruction values in https://github.com/tgstation/tgstation/pull/77894 this fixes my mistake closes https://github.com/tgstation/tgstation/issues/77952 ## Changelog :cl: fix: Railings no longer give more metal than they take /:cl: * [No GBP] fixes railing deconstruction giving free iron --------- Co-authored-by: iwishforducks <65363339+iwishforducks@users.noreply.github.com> --- code/game/objects/structures/railings.dm | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/code/game/objects/structures/railings.dm b/code/game/objects/structures/railings.dm index 1d7109fefae..7f9dab59a46 100644 --- a/code/game/objects/structures/railings.dm +++ b/code/game/objects/structures/railings.dm @@ -90,8 +90,12 @@ /obj/structure/railing/deconstruct(disassembled) if(!(flags_1 & NODECONSTRUCT_1)) - var/obj/item/stack/rods/rod = new /obj/item/stack/rods(drop_location(), 6) - transfer_fingerprints_to(rod) + if (istype(src,/obj/structure/railing/corner)) // Corner railings only cost 1 rod + var/obj/item/stack/rods/rod = new /obj/item/stack/rods(drop_location(), 1) + transfer_fingerprints_to(rod) + else + var/obj/item/stack/rods/rod = new /obj/item/stack/rods(drop_location(), 2) + transfer_fingerprints_to(rod) return ..() ///Implements behaviour that makes it possible to unanchor the railing.