diff --git a/code/modules/research/designs.dm b/code/modules/research/designs.dm
index ab486e299dd..6cd81aee185 100644
--- a/code/modules/research/designs.dm
+++ b/code/modules/research/designs.dm
@@ -40,7 +40,7 @@ other types of metals and chemistry for reagents).
var/construction_time //Amount of time required for building the object
var/build_path = "" //The file path of the object that gets created
var/list/category = null //Primarily used for Mech Fabricators, but can be used for anything
- var/reagents
+ var/list/reagents = list() //List of reagents. Format: "id" = amount.
//A proc to calculate the reliability of a design based on tech levels and innate modifiers.
diff --git a/code/modules/research/designs/weapon_designs.dm b/code/modules/research/designs/weapon_designs.dm
index 371a0d7b01b..ab792260177 100644
--- a/code/modules/research/designs/weapon_designs.dm
+++ b/code/modules/research/designs/weapon_designs.dm
@@ -69,7 +69,8 @@
id = "decloner"
req_tech = list("combat" = 8, "materials" = 7, "biotech" = 5, "powerstorage" = 6)
build_type = PROTOLATHE
- materials = list(MAT_GOLD = 5000,MAT_URANIUM = 10000, "mutagen" = 40)
+ materials = list(MAT_GOLD = 5000,MAT_URANIUM = 10000)
+ reagents = list("mutagen" = 40)
build_path = /obj/item/weapon/gun/energy/decloner
category = list("Weapons")
@@ -110,7 +111,8 @@
id = "flora_gun"
req_tech = list("materials" = 2, "biotech" = 3, "powerstorage" = 3)
build_type = PROTOLATHE
- materials = list(MAT_METAL = 2000, MAT_GLASS = 500, "radium" = 20)
+ materials = list(MAT_METAL = 2000, MAT_GLASS = 500)
+ reagents = list("radium" = 20)
build_path = /obj/item/weapon/gun/energy/floragun
category = list("Weapons")
diff --git a/code/modules/research/protolathe.dm b/code/modules/research/protolathe.dm
index 9e1a31e84db..48157bbf75d 100644
--- a/code/modules/research/protolathe.dm
+++ b/code/modules/research/protolathe.dm
@@ -67,7 +67,9 @@ Note: Must be placed west/left of and R&D console to function.
var/A = materials.amount(M)
if(!A)
A = reagents.get_reagent_amount(M)
- A = A / max(1, (being_built.materials[M]/efficiency_coeff))
+ A = A / max(1, (being_built.reagents[M]/efficiency_coeff))
+ else
+ A = A / max(1, (being_built.materials[M]/efficiency_coeff))
return A
/obj/machinery/r_n_d/protolathe/attackby(obj/item/O, mob/user, params)
diff --git a/code/modules/research/rdconsole.dm b/code/modules/research/rdconsole.dm
index f8f5cbd1c0d..b15c8600c3c 100644
--- a/code/modules/research/rdconsole.dm
+++ b/code/modules/research/rdconsole.dm
@@ -385,9 +385,17 @@ won't update every console in existence) but it's more of a hassle to do. Also,
src.visible_message("The [src.name] beeps, \"Not enough materials to complete prototype.\"")
enough_materials = 0
g2g = 0
+ else
+ for(var/R in being_built.reagents)
+ if(!linked_lathe.reagents.has_reagent(R, being_built.reagents[R]/coeff))
+ src.visible_message("The [src.name] beeps, \"Not enough reagents to complete prototype.\"")
+ enough_materials = 0
+ g2g = 0
if(enough_materials)
linked_lathe.materials.use_amount(efficient_mats, amount)
+ for(var/R in being_built.reagents)
+ linked_lathe.reagents.remove_reagent(R, being_built.reagents[R]/coeff)
var/P = being_built.build_path //lets save these values before the spawn() just in case. Nobody likes runtimes.
var/R = being_built.reliability
@@ -823,6 +831,15 @@ won't update every console in existence) but it's more of a hassle to do. Also,
temp_material += " [D.materials[M]/coeff] [CallMaterialName(M)]"
c = min(c,t)
+ for(var/R in D.reagents)
+ t = linked_lathe.check_mat(D, R)
+ temp_material += " | "
+ if (t < 1)
+ temp_material += "[D.reagents[R]/coeff] [CallMaterialName(R)]"
+ else
+ temp_material += " [D.reagents[R]/coeff] [CallMaterialName(R)]"
+ c = min(c,t)
+
if (c >= 1)
dat += "[D.name]"
if(c >= 5)