From 4da823781ecf972c6bee26d85c44de39284e27b1 Mon Sep 17 00:00:00 2001 From: OneOneThreeEight Date: Sat, 8 Dec 2018 10:43:03 -0500 Subject: [PATCH] Firing pin acquisition 2: electric boogaloo (#5684) * Adds a box of firing pins to the RD's locker. Can't permit mass-production of firing pins via R&D, sorry lads, this is the best anyone can do. * This box of pins has a varied assortment of pin types. * Pin removal is based on probability as the screwdriver is the only means of removing pins at the moment. --- .../objects/items/weapons/storage/boxes.dm | 15 ++++++++ .../closets/secure/scientist.dm | 1 + code/modules/projectiles/gun.dm | 4 +- html/changelogs/firingpinboogaloo.yml | 38 +++++++++++++++++++ 4 files changed, 56 insertions(+), 2 deletions(-) create mode 100644 html/changelogs/firingpinboogaloo.yml diff --git a/code/game/objects/items/weapons/storage/boxes.dm b/code/game/objects/items/weapons/storage/boxes.dm index 6378a5d63f0..3b6e54aba46 100644 --- a/code/game/objects/items/weapons/storage/boxes.dm +++ b/code/game/objects/items/weapons/storage/boxes.dm @@ -385,6 +385,21 @@ new /obj/item/device/firing_pin/implant/loyalty(src) new /obj/item/device/firing_pin/implant/loyalty(src) +/obj/item/weapon/storage/box/firingpinsRD + name = "box of assorted firing pins" + desc = "A box of varied assortment of firing pins. Appears to have R&D stickers on all sides of the box. Also seems to have a smiley face sticker on the top of it." + +/obj/item/weapon/storage/box/firingpins/fill() + ..() + new /obj/item/device/firing_pin(src) + new /obj/item/device/firing_pin(src) + new /obj/item/device/firing_pin/access(src) + new /obj/item/device/firing_pin/access(src) + new /obj/item/device/firing_pin/implant/loyalty(src) + new /obj/item/device/firing_pin/implant/loyalty(src) + new /obj/item/device/firing_pin/clown(src) + new /obj/item/device/firing_pin/dna(src) + /obj/item/weapon/storage/box/teargas name = "box of pepperspray grenades" desc = "A box containing 7 tear gas grenades. A gas mask is printed on the label.
WARNING: Exposure carries risk of serious injury or death. Keep away from persons with lung conditions." diff --git a/code/game/objects/structures/crates_lockers/closets/secure/scientist.dm b/code/game/objects/structures/crates_lockers/closets/secure/scientist.dm index d77bca5ccb0..03c27ce148d 100644 --- a/code/game/objects/structures/crates_lockers/closets/secure/scientist.dm +++ b/code/game/objects/structures/crates_lockers/closets/secure/scientist.dm @@ -44,6 +44,7 @@ new /obj/item/weapon/tank/air(src) new /obj/item/clothing/mask/gas(src) new /obj/item/device/flash(src) + new /obj/item/weapon/storage/box/firingpinsRD(src) /obj/structure/closet/secure_closet/RD2 name = "research director's attire" diff --git a/code/modules/projectiles/gun.dm b/code/modules/projectiles/gun.dm index 926ddfb16cb..eaee26ee59c 100644 --- a/code/modules/projectiles/gun.dm +++ b/code/modules/projectiles/gun.dm @@ -725,7 +725,7 @@ obj/item/weapon/gun/Destroy() if(isscrewdriver(I)) visible_message("[user] begins to try and pry out [src]'s firing pin!") if(do_after(user,45 SECONDS,act_target = src)) - if(pin.durable) + if(pin.durable || prob(50)) visible_message("[user] pops the [pin] out of [src]!") pin.forceMove(get_turf(src)) pin = null//clear it out. @@ -736,4 +736,4 @@ obj/item/weapon/gun/Destroy() "You hear a metallic crack.") qdel(pin) pin = null - .=..() \ No newline at end of file + .=..() diff --git a/html/changelogs/firingpinboogaloo.yml b/html/changelogs/firingpinboogaloo.yml new file mode 100644 index 00000000000..654047d08ce --- /dev/null +++ b/html/changelogs/firingpinboogaloo.yml @@ -0,0 +1,38 @@ +################################ +# Example Changelog File +# +# Note: This file, and files beginning with ".", and files that don't end in ".yml" will not be read. If you change this file, you will look really dumb. +# +# Your changelog will be merged with a master changelog. (New stuff added only, and only on the date entry for the day it was merged.) +# When it is, any changes listed below will disappear. +# +# Valid Prefixes: +# bugfix +# wip (For works in progress) +# tweak +# soundadd +# sounddel +# rscadd (general adding of nice things) +# rscdel (general deleting of nice things) +# imageadd +# imagedel +# maptweak +# spellcheck (typo fixes) +# experiment +# balance +################################# + +# Your name. +author: Scheveningen + +# Optional: Remove this file after generating master changelog. Useful for PR changelogs that won't get used again. +delete-after: True + +# Any changes you've made. See valid prefix list above. +# INDENT WITH TWO SPACES. NOT TABS. SPACES. +# SCREW THIS UP AND IT WON'T WORK. +# Also, all entries are changed into a single [] after a master changelog generation. Just remove the brackets when you add new entries. +# Please surround your changes in double quotes ("), as certain characters otherwise screws up compiling. The quotes will not show up in the changelog. +changes: + - rscadd: "In accordance to Directive Four, Research Directors galaxy-wide now have obtained electronic firing pin boxes in their locker storage for facilitating weapons testing." + - tweak: "Pins can be removed from weapons with a 50/50 chance for breaking. Please don't abuse this."