Skip to content

Commit

Permalink
qol: Metal Foam platings can be replaced with normal one by using met…
Browse files Browse the repository at this point in the history
…al sheet (ss220-space#3574)
  • Loading branch information
Vladisvell authored Oct 4, 2023
1 parent 41a281c commit e6ebf88
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions code/game/turfs/simulated/floor/plating.dm
Original file line number Diff line number Diff line change
Expand Up @@ -369,6 +369,21 @@
if(..())
return TRUE

if(istype(C, /obj/item/stack/sheet/metal))
var/obj/item/stack/sheet/metal/metal = C
if(metal.get_amount() < 2)
to_chat(user, span_warning("You need at least 2 [metal] to make a plating!"))
return TRUE
else
to_chat(user, span_notice("You begin swapping the plating for [metal]..."))
if(do_after(user, 3 SECONDS * metal.toolspeed * gettoolspeedmod(user), target = src))
if(metal.get_amount() >= 2)
ChangeTurf(/turf/simulated/floor/plating, FALSE, FALSE)
playsound(src, metal.usesound, 80, TRUE)
metal.use(2)
to_chat(user, span_notice("You swap the plating for [metal]."))
return TRUE

if(istype(C) && C.force)
user.changeNext_move(CLICK_CD_MELEE)
user.do_attack_animation(src)
Expand Down

0 comments on commit e6ebf88

Please sign in to comment.