Adds craftable extended mags

This commit is contained in:
Thalpy
2019-10-15 12:37:35 +01:00
parent e71a70f406
commit acc0ff8a17
6 changed files with 68 additions and 24 deletions
+18 -6
View File
@@ -899,16 +899,29 @@
/datum/crafting_recipe/smartdartgun
name = "Smart dartgun"
result = /obj/item/gun/syringe/dart
reqs = list(/obj/item/stack/sheet/metal = 15,
/obj/item/stack/sheet/glass = 10,
reqs = list(/obj/item/stack/sheet/metal = 10,
/obj/item/stack/sheet/glass = 5,
/obj/item/tank/internals = 1,
/obj/item/reagent_containers/glass/beaker = 1,
/obj/item/stack/sheet/plastic = 10,
/obj/item/stack/cable_coil = 2)
/obj/item/stack/sheet/plastic = 5,
/obj/item/stack/cable_coil = 1)
time = 150 //It's a gun
category = CAT_WEAPONRY
subcategory = CAT_WEAPON
/datum/crafting_recipe/rapiddartgun
name = "Rapid Smart dartgun - larger size beaker = larger mag."
result = /obj/item/gun/syringe/dart/rapiddart
reqs = list(
/obj/item/gun/syringe/dart = 1,
/obj/item/stack/sheet/plastic = 5,
/obj/item/stack/cable_coil = 1
)
parts = list(/obj/item/reagent_containers/glass/beaker = 1)
time = 120 //Modifying your gun
category = CAT_WEAPONRY
subcategory = CAT_WEAPON
/datum/crafting_recipe/durathread_duffelbag
name = "Durathread Dufflebag"
result = /obj/item/storage/backpack/duffelbag/durathread
@@ -932,7 +945,7 @@
/obj/item/stack/sheet/leather = 2)
time = 50
category = CAT_CLOTHING
/datum/crafting_recipe/durathread_helmet
name = "Makeshift Durathread Helmet"
result = /obj/item/clothing/head/helmet/durathread
@@ -948,4 +961,3 @@
/obj/item/stack/sheet/leather = 3)
time = 50
category = CAT_CLOTHING
@@ -122,3 +122,36 @@
else
to_chat(user, "<span class='notice'>You can't put the [A] into \the [src]!</span>")
return FALSE
/obj/item/gun/syringe/dart/rapiddart
name = "Repeating dart gun"
icon_state = "rapiddartgun"
item_state = "rapiddartgun"
max_syringes = 1
/obj/item/gun/syringe/dart/rapiddart/Initialize()
.=..()
update_capacity()
/obj/item/gun/syringe/dart/rapiddart/proc/update_capacity()
var/obj/item/reagent_containers/glass/beaker/B = locate(/obj/item/reagent_containers/glass/beaker) in src
if(istype(B, /obj/item/reagent_containers/glass/beaker/large))
desc = "[initial(desc)] A modification of the dart gun's pressure chamber has been perfomed using a [B], extending it's holding size to [max_syringes]."
max_syringes = 2
return
else if(istype(B, /obj/item/reagent_containers/glass/beaker/plastic))
desc = "[initial(desc)] A modification of the dart gun's pressure chamber has been perfomed using a [B], extending it's holding size to [max_syringes]."
max_syringes = 3
return
else if(istype(B, /obj/item/reagent_containers/glass/beaker/meta))
desc = "[initial(desc)] A modification of the dart gun's pressure chamber has been perfomed using a [B], extending it's holding size to [max_syringes]."
max_syringes = 4
return
else if(istype(B, /obj/item/reagent_containers/glass/beaker/bluespace))
desc = "[initial(desc)] A modification of the dart gun's pressure chamber has been perfomed using a [B], extending it's holding size to [max_syringes]."
max_syringes = 6
return
else
max_syringes = 1
desc = "[initial(desc)] It has a [B] strapped to it, but it doesn't seem to be doing anything."
@@ -404,22 +404,22 @@
if(!name || !reagents.total_volume || !src || QDELETED(src) || !usr.canUseTopic(src, !issilicon(usr)))
return
var/obj/item/reagent_containers/glass/bottle/vial/small/P
var/obj/item/reagent_containers/syringe/dart/D
for(var/i = 0; i < amount_full; i++)
P = new /obj/item/reagent_containers/syringe/dart(drop_location())
P.name = trim("[name] SmartDart")
adjust_item_drop_location(P)
reagents.trans_to(P, 20)
P.mode=!mode
P.update_icon()
D = new /obj/item/reagent_containers/syringe/dart(drop_location())
D.name = trim("[name] SmartDart")
adjust_item_drop_location(D)
reagents.trans_to(D, 20)
D.mode=!mode
D.update_icon()
if(vol_part)
P = new /obj/item/reagent_containers/syringe/dart(drop_location())
P.name = trim("[name] SmartDart")
adjust_item_drop_location(P)
reagents.trans_to(P, vol_part)
P.mode=!mode
P.update_icon()
D = new /obj/item/reagent_containers/syringe/dart(drop_location())
D.name = trim("[name] SmartDart")
adjust_item_drop_location(D)
reagents.trans_to(D, vol_part)
D.mode=!mode
D.update_icon()
. = TRUE
//END CITADEL ADDITIONS
@@ -323,8 +323,9 @@
rounded_vol = "empty"
if(reagents && reagents.total_volume)
if(volume/reagents.total_volume == 1)
if(round(volume,1)/reagents.total_volume == 1)
rounded_vol="full"
mode = SYRINGE_INJECT
icon_state = "[rounded_vol]"
item_state = "syringe_[rounded_vol]"