From 241d779da4cf492c79e026978cc2814de58c48ba Mon Sep 17 00:00:00 2001 From: Matt Date: Tue, 10 May 2016 15:41:25 +0200 Subject: [PATCH 1/3] Snibbidy snab --- code/game/objects/items/weapons/legcuffs.dm | 33 ++++++++++++++++++++- 1 file changed, 32 insertions(+), 1 deletion(-) diff --git a/code/game/objects/items/weapons/legcuffs.dm b/code/game/objects/items/weapons/legcuffs.dm index fa485cbf93b..b50389c3931 100644 --- a/code/game/objects/items/weapons/legcuffs.dm +++ b/code/game/objects/items/weapons/legcuffs.dm @@ -19,11 +19,15 @@ desc = "A trap used to catch bears and other legged creatures." var/armed = 0 var/obj/item/weapon/grenade/iedcasing/IED = null + var/obj/item/device/assembly/signaler/sig = null /obj/item/weapon/restraints/legcuffs/beartrap/Destroy() if(IED) qdel(IED) IED = null + if(sig) + qdel(sig) + sig = null return ..() /obj/item/weapon/restraints/legcuffs/beartrap/suicide_act(mob/user) @@ -43,6 +47,9 @@ if(IED) to_chat(user, "This beartrap already has an IED hooked up to it!") return + if(sig) + to_chat(user, "This beartrap already has a signaller hooked up to it!") + return IED = I switch(IED.assembled) if(0,1) //if it's not fueled/hooked up @@ -60,12 +67,33 @@ to_chat(user, "You shouldn't be reading this message! Contact a coder or someone, something broke!") IED = null return + if(istype(I, /obj/item/device/assembly/signaler)) + if(IED) + to_chat(user, "This beartrap already has an IED hooked up to it!") + return + if(sig) + to_chat(user, "This beartrap already has a signaller hooked up to it!") + return + sig = I + if(sig.secured) + to_chat(user, "The signaller is secured.") + sig = null + return + user.drop_item(src) + I.forceMove(src) + to_chat(user, "You sneak the [sig] underneath the pressure plate and connect the trigger wire.") + desc = "A trap used to catch bears and other legged creatures. There is a remote signaller hooked up to it." if(istype(I, /obj/item/weapon/screwdriver)) if(IED) IED.forceMove(get_turf(src)) IED = null to_chat(user, "You remove the IED from the [src].") return + if(sig) + sig.forceMove(get_turf(src)) + sig = null + to_chat(user, "You remove the signaller from the [src].") + return ..() /obj/item/weapon/restraints/legcuffs/beartrap/Crossed(AM as mob|obj) @@ -88,6 +116,9 @@ spawn(IED.det_time) IED.prime() + if(sig && isturf(src.loc)) + sig.signal() + if(ishuman(AM)) var/mob/living/carbon/H = AM if(H.lying) @@ -192,4 +223,4 @@ /obj/item/weapon/legcuffs/bolas/Bump() ..() - throw_failed() //allows a mech bolas to be destroyed \ No newline at end of file + throw_failed() //allows a mech bolas to be destroyed From ed58122df2bcfb2f1a30de6f08da857909d39b5f Mon Sep 17 00:00:00 2001 From: Matt Date: Tue, 10 May 2016 15:43:46 +0200 Subject: [PATCH 2/3] Grammar --- code/game/objects/items/weapons/legcuffs.dm | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/code/game/objects/items/weapons/legcuffs.dm b/code/game/objects/items/weapons/legcuffs.dm index b50389c3931..6b88d280592 100644 --- a/code/game/objects/items/weapons/legcuffs.dm +++ b/code/game/objects/items/weapons/legcuffs.dm @@ -48,7 +48,7 @@ to_chat(user, "This beartrap already has an IED hooked up to it!") return if(sig) - to_chat(user, "This beartrap already has a signaller hooked up to it!") + to_chat(user, "This beartrap already has a signaler hooked up to it!") return IED = I switch(IED.assembled) @@ -72,17 +72,17 @@ to_chat(user, "This beartrap already has an IED hooked up to it!") return if(sig) - to_chat(user, "This beartrap already has a signaller hooked up to it!") + to_chat(user, "This beartrap already has a signaler hooked up to it!") return sig = I if(sig.secured) - to_chat(user, "The signaller is secured.") + to_chat(user, "The signaler is secured.") sig = null return user.drop_item(src) I.forceMove(src) to_chat(user, "You sneak the [sig] underneath the pressure plate and connect the trigger wire.") - desc = "A trap used to catch bears and other legged creatures. There is a remote signaller hooked up to it." + desc = "A trap used to catch bears and other legged creatures. There is a remote signaler hooked up to it." if(istype(I, /obj/item/weapon/screwdriver)) if(IED) IED.forceMove(get_turf(src)) @@ -92,7 +92,7 @@ if(sig) sig.forceMove(get_turf(src)) sig = null - to_chat(user, "You remove the signaller from the [src].") + to_chat(user, "You remove the signaler from the [src].") return ..() From 085d326b3a30d6fb22129d4cf73cc60ee0c4af84 Mon Sep 17 00:00:00 2001 From: Matt Date: Tue, 17 May 2016 12:37:23 +0200 Subject: [PATCH 3/3] whatamidoingwithmylife --- code/game/objects/items/weapons/legcuffs.dm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/game/objects/items/weapons/legcuffs.dm b/code/game/objects/items/weapons/legcuffs.dm index 6b88d280592..034dfc2ddc2 100644 --- a/code/game/objects/items/weapons/legcuffs.dm +++ b/code/game/objects/items/weapons/legcuffs.dm @@ -57,7 +57,7 @@ IED = null return if(2,3) - user.drop_item(src) + user.drop_item() I.forceMove(src) message_admins("[key_name_admin(user)] has rigged a beartrap with an IED.") log_game("[key_name(user)] has rigged a beartrap with an IED.") @@ -79,7 +79,7 @@ to_chat(user, "The signaler is secured.") sig = null return - user.drop_item(src) + user.drop_item() I.forceMove(src) to_chat(user, "You sneak the [sig] underneath the pressure plate and connect the trigger wire.") desc = "A trap used to catch bears and other legged creatures. There is a remote signaler hooked up to it."