From 7b159e204cd231d33173b57d96eea71e173deee8 Mon Sep 17 00:00:00 2001 From: Matt Smith Date: Tue, 26 Dec 2017 06:14:09 +0000 Subject: [PATCH] Cut through handcuffs with power wirecutters (#33822) * Cut through handcuffs with power wirecutters * unbuckle is handled on delete of the handcuffs --- code/game/objects/items/tools/wirecutters.dm | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) diff --git a/code/game/objects/items/tools/wirecutters.dm b/code/game/objects/items/tools/wirecutters.dm index c03469164e..94b10a6a9f 100644 --- a/code/game/objects/items/tools/wirecutters.dm +++ b/code/game/objects/items/tools/wirecutters.dm @@ -14,7 +14,8 @@ materials = list(MAT_METAL=80) attack_verb = list("pinched", "nipped") hitsound = 'sound/items/wirecutter.ogg' - usesound = 'sound/items/wirecutter.ogg' + usesound = 'sound/items/wirecutter.ogg' + tool_behaviour = TOOL_WIRECUTTER toolspeed = 1 armor = list(melee = 0, bullet = 0, laser = 0, energy = 0, bomb = 0, bio = 0, rad = 0, fire = 50, acid = 30) @@ -58,7 +59,8 @@ desc = "Extremely sharp wirecutters, made out of a silvery-green metal." icon = 'icons/obj/abductor.dmi' icon_state = "cutters" - toolspeed = 0.1 + toolspeed = 0.1 + random_color = FALSE /obj/item/wirecutters/cyborg @@ -70,7 +72,8 @@ name = "jaws of life" desc = "A set of jaws of life, compressed through the magic of science. It's fitted with a cutting head." icon_state = "jaws_cutter" - item_state = "jawsoflife" + item_state = "jawsoflife" + materials = list(MAT_METAL=150,MAT_SILVER=50,MAT_TITANIUM=25) usesound = 'sound/items/jaws_cut.ogg' toolspeed = 0.25 @@ -92,4 +95,12 @@ var/obj/item/crowbar/power/pryjaws = new /obj/item/crowbar/power to_chat(user, "You attach the pry jaws to [src].") qdel(src) - user.put_in_active_hand(pryjaws) \ No newline at end of file + user.put_in_active_hand(pryjaws) + +/obj/item/wirecutters/power/attack(mob/living/carbon/C, mob/user) + if(istype(C) && C.handcuffed) + user.visible_message("[user] cuts [C]'s restraints with [src]!") + qdel(C.handcuffed) + return + else + ..()