diff --git a/code/__DEFINES/construction.dm b/code/__DEFINES/construction.dm index 2ed25088cb50..09459cf90039 100644 --- a/code/__DEFINES/construction.dm +++ b/code/__DEFINES/construction.dm @@ -67,19 +67,6 @@ //let's just pretend fulltile windows being children of border windows is fine #define FULLTILE_WINDOW_DIR NORTHEAST -//Material defines, for determining how much of a given material an item contains -#define MAT_METAL "$metal" -#define MAT_GLASS "$glass" -#define MAT_SILVER "$silver" -#define MAT_GOLD "$gold" -#define MAT_DIAMOND "$diamond" -#define MAT_URANIUM "$uranium" -#define MAT_PLASMA "$plasma" -#define MAT_BLUESPACE "$bluespace" -#define MAT_BANANIUM "$bananium" -#define MAT_TITANIUM "$titanium" -#define MAT_BIOMASS "$biomass" -#define MAT_PLASTIC "$plastic" //The amount of materials you get from a sheet of mineral like iron/diamond/glass etc #define MINERAL_MATERIAL_AMOUNT 2000 //The maximum size of a stack object. diff --git a/code/__DEFINES/exosuit_fab.dm b/code/__DEFINES/exosuit_fab.dm new file mode 100644 index 000000000000..2be3280c75fe --- /dev/null +++ b/code/__DEFINES/exosuit_fab.dm @@ -0,0 +1,32 @@ +/// Module is compatible with Security Cyborg models +#define BORG_MODULE_SECURITY (1<<0) +/// Module is compatible with Miner Cyborg models +#define BORG_MODULE_MINER (1<<1) +/// Module is compatible with Janitor Cyborg models +#define BORG_MODULE_JANITOR (1<<2) +/// Module is compatible with Medical Cyborg models +#define BORG_MODULE_MEDICAL (1<<3) +/// Module is compatible with Engineering Cyborg models +#define BORG_MODULE_ENGINEERING (1<<4) + +/// Module is compatible with Ripley Exosuit models +#define EXOSUIT_MODULE_RIPLEY (1<<0) +/// Module is compatible with Odyseeus Exosuit models +#define EXOSUIT_MODULE_ODYSSEUS (1<<1) +/// Module is compatible with Clarke Exosuit models +#define EXOSUIT_MODULE_CLARKE (1<<2) +/// Module is compatible with Gygax Exosuit models +#define EXOSUIT_MODULE_GYGAX (1<<3) +/// Module is compatible with Durand Exosuit models +#define EXOSUIT_MODULE_DURAND (1<<4) +/// Module is compatible with H.O.N.K Exosuit models +#define EXOSUIT_MODULE_HONK (1<<5) +/// Module is compatible with Phazon Exosuit models +#define EXOSUIT_MODULE_PHAZON (1<<6) + +/// Module is compatible with "Working" Exosuit models - Ripley and Clarke +#define EXOSUIT_MODULE_WORKING EXOSUIT_MODULE_RIPLEY | EXOSUIT_MODULE_CLARKE +/// Module is compatible with "Combat" Exosuit models - Gygax, H.O.N.K, Durand and Phazon +#define EXOSUIT_MODULE_COMBAT EXOSUIT_MODULE_GYGAX | EXOSUIT_MODULE_HONK | EXOSUIT_MODULE_DURAND | EXOSUIT_MODULE_PHAZON +/// Module is compatible with "Medical" Exosuit modelsm - Odysseus +#define EXOSUIT_MODULE_MEDICAL EXOSUIT_MODULE_ODYSSEUS \ No newline at end of file diff --git a/code/__DEFINES/materials.dm b/code/__DEFINES/materials.dm new file mode 100644 index 000000000000..2d48786b76bb --- /dev/null +++ b/code/__DEFINES/materials.dm @@ -0,0 +1,12 @@ +/// Is the material from an ore? currently unused but exists atm for categorizations sake +#define MAT_CATEGORY_ORE "ore capable" + +/// Hard materials, such as iron or metal +#define MAT_CATEGORY_RIGID "rigid material" + + +/// Gets the reference for the material type that was given +#define getmaterialref(A) (SSmaterials.materials[A]) + +/// Flag for atoms, this flag ensures it isn't re-colored by materials. Useful for snowflake icons such as default toolboxes. +#define MATERIAL_NO_COLOR (1<<0) \ No newline at end of file diff --git a/code/__DEFINES/subsystems.dm b/code/__DEFINES/subsystems.dm index 4e1fc890cc52..a7501e6956f9 100644 --- a/code/__DEFINES/subsystems.dm +++ b/code/__DEFINES/subsystems.dm @@ -1,12 +1,12 @@ //! Defines for subsystems and overlays -//! +//! //! Lots of important stuff in here, make sure you have your brain switched on //! when editing this file //! ## DB defines /** * DB major schema version - * + * * Update this whenever the db schema changes * * make sure you add an update to the schema_version stable in the db changelog @@ -15,7 +15,7 @@ /** * DB minor schema version - * + * * Update this whenever the db schema changes * * make sure you add an update to the schema_version stable in the db changelog @@ -108,6 +108,7 @@ #define INIT_ORDER_SOUNDS 83 #define INIT_ORDER_INSTRUMENTS 82 #define INIT_ORDER_VIS 80 +#define INIT_ORDER_MATERIALS 76 #define INIT_ORDER_RESEARCH 75 #define INIT_ORDER_EVENTS 70 #define INIT_ORDER_MAPPING 65 diff --git a/code/__HELPERS/global_lists.dm b/code/__HELPERS/global_lists.dm index 163447bfe0db..67f2d720cd18 100644 --- a/code/__HELPERS/global_lists.dm +++ b/code/__HELPERS/global_lists.dm @@ -47,11 +47,6 @@ for(var/path in subtypesof(/datum/surgery)) GLOB.surgeries_list += new path() - //Materials - for(var/path in subtypesof(/datum/material)) - var/datum/material/D = new path() - GLOB.materials_list[D.id] = D - GLOB.emote_list = init_emote_list() //Skillcapes for(var/path in subtypesof(/datum/skillcape)) diff --git a/code/_globalvars/lists/objects.dm b/code/_globalvars/lists/objects.dm index c49e27bb5611..6bf6a0110b73 100644 --- a/code/_globalvars/lists/objects.dm +++ b/code/_globalvars/lists/objects.dm @@ -16,7 +16,6 @@ GLOBAL_LIST_EMPTY(singularities) //list of all singularities on the stati GLOBAL_LIST(chemical_reactions_list) //list of all /datum/chemical_reaction datums. Used during chemical reactions GLOBAL_LIST(chemical_reagents_list) //list of all /datum/reagent datums indexed by reagent id. Used by chemistry stuff -GLOBAL_LIST_EMPTY(materials_list) //list of all /datum/material datums indexed by material id. GLOBAL_LIST_EMPTY(tech_list) //list of all /datum/tech datums indexed by id. GLOBAL_LIST_EMPTY(surgeries_list) //list of all surgeries by name, associated with their path. GLOBAL_LIST_EMPTY(crafting_recipes) //list of all table craft recipes diff --git a/code/controllers/subsystem/materials.dm b/code/controllers/subsystem/materials.dm new file mode 100644 index 000000000000..56d7e48f8d92 --- /dev/null +++ b/code/controllers/subsystem/materials.dm @@ -0,0 +1,25 @@ +/*! How material datums work +Materials are now instanced datums, with an associative list of them being kept in SSmaterials. We only instance the materials once and then re-use these instances for everything. +These materials call on_applied() on whatever item they are applied to, common effects are adding components, changing color and changing description. This allows us to differentiate items based on the material they are made out of.area +*/ + +SUBSYSTEM_DEF(materials) + name = "Materials" + flags = SS_NO_FIRE + init_order = INIT_ORDER_MATERIALS + ///Dictionary of material.type || material ref + var/list/materials = list() + ///Dictionary of category || list of material refs + var/list/materials_by_category = list() + +/datum/controller/subsystem/materials/Initialize(timeofday) + InitializeMaterials() + return ..() + +///Ran on initialize, populated the materials and materials_by_category dictionaries with their appropiate vars (See these variables for more info) +/datum/controller/subsystem/materials/proc/InitializeMaterials(timeofday) + for(var/type in subtypesof(/datum/material)) + var/datum/material/ref = new type + materials[type] = ref + for(var/c in ref.categories) + materials_by_category[c] += list(ref) \ No newline at end of file diff --git a/code/controllers/subsystem/research.dm b/code/controllers/subsystem/research.dm index af50d4c47830..d2a6ba7fe4c7 100644 --- a/code/controllers/subsystem/research.dm +++ b/code/controllers/subsystem/research.dm @@ -157,6 +157,7 @@ SUBSYSTEM_DEF(research) stack_trace("WARNING: Design ID clash with ID [initial(DN.id)] detected! Path: [path]") errored_datums[DN] = initial(DN.id) continue + DN.InitializeMaterials() //Initialize the materials in the design returned[initial(DN.id)] = DN techweb_designs = returned verify_techweb_designs() diff --git a/code/datums/components/explodable.dm b/code/datums/components/explodable.dm new file mode 100644 index 000000000000..084395d16e63 --- /dev/null +++ b/code/datums/components/explodable.dm @@ -0,0 +1,106 @@ +///Component specifically for explosion sensetive things, currently only applies to heat based explosions but can later perhaps be used for things that are dangerous to handle carelessly like nitroglycerin. +/datum/component/explodable + var/devastation_range = 0 + var/heavy_impact_range = 0 + var/light_impact_range = 2 + var/flash_range = 3 + var/equipped_slot //For items, lets us determine where things should be hit. + +/datum/component/explodable/Initialize(devastation_range_override, heavy_impact_range_override, light_impact_range_override, flash_range_override) + if(!isatom(parent)) + return COMPONENT_INCOMPATIBLE + + RegisterSignal(parent, COMSIG_PARENT_ATTACKBY, .proc/explodable_attack) + RegisterSignal(parent, COMSIG_TRY_STORAGE_INSERT, .proc/explodable_insert_item) + RegisterSignal(parent, COMSIG_ATOM_EX_ACT, .proc/detonate) + if(ismovable(parent)) + RegisterSignal(parent, COMSIG_MOVABLE_IMPACT, .proc/explodable_impact) + RegisterSignal(parent, COMSIG_MOVABLE_BUMP, .proc/explodable_bump) + if(isitem(parent)) + RegisterSignal(parent, list(COMSIG_ITEM_ATTACK, COMSIG_ITEM_ATTACK_OBJ, COMSIG_ITEM_HIT_REACT), .proc/explodable_attack) + RegisterSignal(parent, COMSIG_ITEM_EQUIPPED, .proc/on_equip) + RegisterSignal(parent, COMSIG_ITEM_DROPPED, .proc/on_drop) + + + + if(devastation_range_override) + devastation_range = devastation_range_override + if(heavy_impact_range_override) + heavy_impact_range = heavy_impact_range_override + if(light_impact_range_override) + light_impact_range = light_impact_range_override + if(flash_range_override) + flash_range = flash_range_override + +/datum/component/explodable/proc/explodable_insert_item(datum/source, obj/item/I, mob/M, silent = FALSE, force = FALSE) + check_if_detonate(I) + +/datum/component/explodable/proc/explodable_impact(datum/source, atom/hit_atom, datum/thrownthing/throwingdatum) + check_if_detonate(hit_atom) + +/datum/component/explodable/proc/explodable_bump(datum/source, atom/A) + check_if_detonate(A) + +///Called when you use this object to attack sopmething +/datum/component/explodable/proc/explodable_attack(datum/source, atom/movable/target, mob/living/user) + check_if_detonate(target) + +///Called when you attack a specific body part of the thing this is equipped on. Useful for exploding pants. +/datum/component/explodable/proc/explodable_attack_zone(datum/source, damage, damagetype, def_zone) + if(!def_zone) + return + if(damagetype != BURN) //Don't bother if it's not fire. + return + if(!is_hitting_zone(def_zone)) //You didn't hit us! ha! + return + detonate() + +/datum/component/explodable/proc/on_equip(datum/source, mob/equipper, slot) + RegisterSignal(equipper, COMSIG_MOB_APPLY_DAMAGE, .proc/explodable_attack_zone, TRUE) + +/datum/component/explodable/proc/on_drop(datum/source, mob/user) + UnregisterSignal(user, COMSIG_MOB_APPLY_DAMAGE) + +/// Checks if we're hitting the zone this component is covering +/datum/component/explodable/proc/is_hitting_zone(def_zone) + var/obj/item/item = parent + var/mob/living/L = item.loc //Get whoever is equipping the item currently + + if(!istype(L)) + return + + var/obj/item/bodypart/bodypart = L.get_bodypart(check_zone(def_zone)) + + var/list/equipment_items = list() + if(iscarbon(L)) + var/mob/living/carbon/C = L + equipment_items += list(C.head, C.wear_mask, C.back, C.gloves, C.shoes, C.glasses, C.ears) + if(ishuman(C)) + var/mob/living/carbon/human/H = C + equipment_items += list(H.wear_suit, H.w_uniform, H.belt, H.s_store, H.wear_id) + + for(var/bp in equipment_items) + if(!bp) + continue + + var/obj/item/I = bp + if(I.body_parts_covered & bodypart.body_part) + return TRUE + return FALSE + + +/datum/component/explodable/proc/check_if_detonate(target) + if(!isitem(target)) + return + var/obj/item/I = target + if(!I.is_hot()) + return + detonate() //If we're touching a hot item we go boom + + +/// Expldoe and remove the object +/datum/component/explodable/proc/detonate() + var/atom/A = parent + explosion(A, devastation_range, heavy_impact_range, light_impact_range, flash_range) //epic explosion time + qdel(A) + diff --git a/code/datums/components/material_container.dm b/code/datums/components/material_container.dm index 48fa758db149..9c27f24905cc 100644 --- a/code/datums/components/material_container.dm +++ b/code/datums/components/material_container.dm @@ -1,4 +1,4 @@ -/* +/*! This datum should be used for handling mineral contents of machines and whatever else is supposed to hold minerals and make use of them. Variables: @@ -13,7 +13,7 @@ var/total_amount = 0 var/max_amount var/sheet_type - var/list/materials + var/list/materials //Map of key = material ref | Value = amount var/show_on_examine var/disable_attackby var/list/allowed_typecache @@ -22,6 +22,7 @@ var/datum/callback/precondition var/datum/callback/after_insert +/// Sets up the proper signals and fills the list of materials with the appropriate references. /datum/component/material_container/Initialize(list/mat_list, max_amt = 0, _show_on_examine = FALSE, list/allowed_types, datum/callback/_precondition, datum/callback/_after_insert, _disable_attackby) materials = list() max_amount = max(0, max_amt) @@ -40,23 +41,19 @@ RegisterSignal(parent, COMSIG_PARENT_ATTACKBY, .proc/OnAttackBy) RegisterSignal(parent, COMSIG_PARENT_EXAMINE, .proc/OnExamine) - var/list/possible_mats = list() - for(var/mat_type in subtypesof(/datum/material)) - var/datum/material/MT = mat_type - possible_mats[initial(MT.id)] = mat_type - for(var/id in mat_list) - if(possible_mats[id]) - var/mat_path = possible_mats[id] - materials[id] = new mat_path() + for(var/mat in mat_list) //Make the assoc list ref | amount + var/datum/material/M = getmaterialref(mat) || mat + materials[M] = 0 /datum/component/material_container/proc/OnExamine(datum/source, mob/user) if(show_on_examine) for(var/I in materials) - var/datum/material/M = materials[I] - var/amt = amount(M.id) + var/datum/material/M = I + var/amt = materials[I] if(amt) to_chat(user, "It has [amt] units of [lowertext(M.name)] stored.") +/// Proc that allows players to fill the parent with mats /datum/component/material_container/proc/OnAttackBy(datum/source, obj/item/I, mob/living/user) var/list/tc = allowed_typecache if(disable_attackby) @@ -81,6 +78,7 @@ return user_insert(I, user) +/// Proc used for when player inserts materials /datum/component/material_container/proc/user_insert(obj/item/I, mob/living/user) set waitfor = FALSE var/requested_amount @@ -112,23 +110,33 @@ else if(I == active_held) user.put_in_active_hand(I) -//For inserting an amount of material -/datum/component/material_container/proc/insert_amount(amt, id = null) - if(amt > 0 && has_space(amt)) - var/total_amount_saved = total_amount - if(id) - var/datum/material/M = materials[id] - if(M) - M.amount += amt - total_amount += amt - else - for(var/i in materials) - var/datum/material/M = materials[i] - M.amount += amt - total_amount += amt - return (total_amount - total_amount_saved) - return FALSE +/// Proc specifically for inserting items, returns the amount of materials entered. +/datum/component/material_container/proc/insert_item(obj/item/I, var/multiplier = 1, stack_amt) + if(!I) + return FALSE + if(istype(I, /obj/item/stack)) + return insert_stack(I, stack_amt, multiplier) + multiplier = CEILING(multiplier, 0.01) + + var/material_amount = get_item_material_amount(I) + if(!material_amount || !has_space(material_amount)) + return FALSE + + last_inserted_id = insert_item_materials(I, multiplier) + return material_amount + +/datum/component/material_container/proc/insert_item_materials(obj/item/I, multiplier = 1) + var/primary_mat + var/max_mat_value = 0 + for(var/MAT in materials) + materials[MAT] += I.materials[MAT] * multiplier + total_amount += I.materials[MAT] * multiplier + if(I.materials[MAT] > max_mat_value) + primary_mat = MAT + return primary_mat + +/// Proc for putting a stack inside of the container /datum/component/material_container/proc/insert_stack(obj/item/stack/S, amt, multiplier = 1) if(isnull(amt)) amt = S.amount @@ -147,250 +155,198 @@ if(!amt) return FALSE - last_inserted_id = insert_materials(S,amt * multiplier) + last_inserted_id = insert_item_materials(S,amt * multiplier) S.use(amt) return amt -/datum/component/material_container/proc/insert_item(obj/item/I, multiplier = 1, stack_amt) - if(!I) - return FALSE - if(istype(I, /obj/item/stack)) - return insert_stack(I, stack_amt, multiplier) +/// For inserting an amount of material +/datum/component/material_container/proc/insert_amount_mat(amt, var/datum/material/mat) + if(!istype(mat)) + mat = getmaterialref(mat) + if(amt > 0 && has_space(amt)) + var/total_amount_saved = total_amount + if(mat) + materials[mat] += amt + else + for(var/i in materials) + materials[i] += amt + total_amount += amt + return (total_amount - total_amount_saved) + return FALSE - var/material_amount = get_item_material_amount(I) - if(!material_amount || !has_space(material_amount)) - return FALSE - - last_inserted_id = insert_materials(I, multiplier) - return material_amount - -/datum/component/material_container/proc/insert_materials(obj/item/I, multiplier = 1) //for internal usage only - var/datum/material/M - var/primary_mat - var/max_mat_value = 0 - for(var/MAT in materials) - M = materials[MAT] - M.amount += I.materials[MAT] * multiplier - total_amount += I.materials[MAT] * multiplier - if(I.materials[MAT] > max_mat_value) - primary_mat = MAT - return primary_mat - -//For consuming material -//mats is a list of types of material to use and the corresponding amounts, example: list(MAT_METAL=100, MAT_GLASS=200) -/datum/component/material_container/proc/use_amount(list/mats, multiplier=1) - if(!mats || !mats.len) - return FALSE - - var/datum/material/M - for(var/MAT in materials) - M = materials[MAT] - if(M.amount < (mats[MAT] * multiplier)) - return FALSE - - var/total_amount_save = total_amount - for(var/MAT in materials) - M = materials[MAT] - M.amount -= mats[MAT] * multiplier - total_amount -= mats[MAT] * multiplier - - return total_amount_save - total_amount - - -/datum/component/material_container/proc/use_amount_type(amt, id) - var/datum/material/M = materials[id] - if(M) - if(M.amount >= amt) - M.amount -= amt +/// Uses an amount of a specific material, effectively removing it. +/datum/component/material_container/proc/use_amount_mat(amt, var/datum/material/mat) + if(!istype(mat)) + mat = getmaterialref(mat) + var/amount = materials[mat] + if(mat) + if(amount >= amt) + materials[mat] -= amt total_amount -= amt return amt return FALSE -/datum/component/material_container/proc/transer_amt_to(var/datum/component/material_container/T, amt, id) - if((amt==0)||(!T)||(!id)) +/// Proc for transfering materials to another container. +/datum/component/material_container/proc/transer_amt_to(var/datum/component/material_container/T, amt, var/datum/material/mat) + if(!istype(mat)) + mat = getmaterialref(mat) + if((amt==0)||(!T)||(!mat)) return FALSE if(amt<0) - return T.transer_amt_to(src, -amt, id) - var/datum/material/M = materials[id] - - if(M) - var/tr = min(amt, M.amount,T.can_insert_amount(amt, id)) - if(tr) - use_amount_type(tr, id) - T.insert_amount(tr, id) - return tr + return T.transer_amt_to(src, -amt, mat) + var/tr = min(amt, materials[mat],T.can_insert_amount_mat(amt, mat)) + if(tr) + use_amount_mat(tr, mat) + T.insert_amount_mat(tr, mat) + return tr return FALSE -/datum/component/material_container/proc/can_insert_amount(amt, id) - if(amt && id) - var/datum/material/M = materials[id] +/// Proc for checking if there is room in the component, returning the amount or else the amount lacking. +/datum/component/material_container/proc/can_insert_amount_mat(amt, mat) + if(amt && mat) + var/datum/material/M = mat if(M) if((total_amount + amt) <= max_amount) return amt else return (max_amount-total_amount) -/datum/component/material_container/proc/can_use_amount(amt, id, list/mats) - if(amt && id) - var/datum/material/M = materials[id] - if(M && M.amount >= amt) - return TRUE - else if(istype(mats)) - for(var/M in mats) - if(materials[M] && (mats[M] <= materials[M])) - continue - else - return FALSE - return TRUE - return FALSE -//For spawning mineral sheets; internal use only -/datum/component/material_container/proc/retrieve(sheet_amt, datum/material/M, target = null) +/// For consuming a dictionary of materials. mats is the map of materials to use and the corresponding amounts, example: list(M/datum/material/glass =100, datum/material/iron=200) +/datum/component/material_container/proc/use_materials(list/mats, multiplier=1) + if(!mats || !length(mats)) + return FALSE + + var/list/mats_to_remove = list() //Assoc list MAT | AMOUNT + + for(var/x in mats) //Loop through all required materials + var/datum/material/req_mat = x + if(!istype(req_mat)) + req_mat = getmaterialref(req_mat) //Get the ref if necesary + if(!materials[req_mat]) //Do we have the resource? + return FALSE //Can't afford it + var/amount_required = mats[x] * multiplier + if(!(materials[req_mat] >= amount_required)) // do we have enough of the resource? + return FALSE //Can't afford it + mats_to_remove[req_mat] += amount_required //Add it to the assoc list of things to remove + continue + + var/total_amount_save = total_amount + + for(var/i in mats_to_remove) + total_amount_save -= use_amount_mat(mats_to_remove[i], i) + + return total_amount_save - total_amount + +/// For spawning mineral sheets at a specific location. Used by machines to output sheets. +/datum/component/material_container/proc/retrieve_sheets(sheet_amt, var/datum/material/M, target = null) if(!M.sheet_type) - return 0 + return 0 //Add greyscale sheet handling here later if(sheet_amt <= 0) return 0 if(!target) target = get_turf(parent) - if(M.amount < (sheet_amt * MINERAL_MATERIAL_AMOUNT)) - sheet_amt = round(M.amount / MINERAL_MATERIAL_AMOUNT) + if(materials[M] < (sheet_amt * MINERAL_MATERIAL_AMOUNT)) + sheet_amt = round(materials[M] / MINERAL_MATERIAL_AMOUNT) var/count = 0 while(sheet_amt > MAX_STACK_SIZE) new M.sheet_type(target, MAX_STACK_SIZE) count += MAX_STACK_SIZE - use_amount_type(sheet_amt * MINERAL_MATERIAL_AMOUNT, M.id) + use_amount_mat(sheet_amt * MINERAL_MATERIAL_AMOUNT, M) sheet_amt -= MAX_STACK_SIZE if(sheet_amt >= 1) new M.sheet_type(target, sheet_amt) count += sheet_amt - use_amount_type(sheet_amt * MINERAL_MATERIAL_AMOUNT, M.id) + use_amount_mat(sheet_amt * MINERAL_MATERIAL_AMOUNT, M) return count -/datum/component/material_container/proc/retrieve_sheets(sheet_amt, id, target = null) - if(materials[id]) - return retrieve(sheet_amt, materials[id], target) - return FALSE - -/datum/component/material_container/proc/retrieve_amount(amt, id, target) - return retrieve_sheets(amount2sheet(amt), id, target) +/// Proc to get all the materials and dump them as sheets /datum/component/material_container/proc/retrieve_all(target = null) var/result = 0 - var/datum/material/M for(var/MAT in materials) - M = materials[MAT] - result += retrieve_sheets(amount2sheet(M.amount), MAT, target) + var/amount = materials[MAT] + result += retrieve_sheets(amount2sheet(amount), MAT, target) return result +/// Proc that returns TRUE if the container has space /datum/component/material_container/proc/has_space(amt = 0) return (total_amount + amt) <= max_amount +/// Checks if its possible to afford a certain amount of materials. Takes a dictionary of materials. /datum/component/material_container/proc/has_materials(list/mats, multiplier=1) if(!mats || !mats.len) return FALSE - var/datum/material/M - for(var/MAT in mats) - M = materials[MAT] - if(M.amount < (mats[MAT] * multiplier)) + for(var/x in mats) //Loop through all required materials + var/datum/material/req_mat = x + if(!istype(req_mat)) + if(ispath(req_mat)) //Is this an actual material, or is it a category? + req_mat = getmaterialref(req_mat) //Get the ref + + else // Its a category. (For example MAT_CATEGORY_RIGID) + if(!has_enough_of_category(req_mat, mats[req_mat], multiplier)) //Do we have enough of this category? + return FALSE + else + continue + + if(!has_enough_of_material(req_mat, mats[req_mat], multiplier))//Not a category, so just check the normal way return FALSE + return TRUE +/// Returns all the categories in a recipe. +/datum/component/material_container/proc/get_categories(list/mats) + var/list/categories = list() + for(var/x in mats) //Loop through all required materials + if(!istext(x)) //This means its not a category + continue + categories += x + return categories + + +/// Returns TRUE if you have enough of the specified material. +/datum/component/material_container/proc/has_enough_of_material(var/datum/material/req_mat, amount, multiplier=1) + if(!materials[req_mat]) //Do we have the resource? + return FALSE //Can't afford it + var/amount_required = amount * multiplier + if(materials[req_mat] >= amount_required) // do we have enough of the resource? + return TRUE + return FALSE //Can't afford it + +/// Returns TRUE if you have enough of a specified material category (Which could be multiple materials) +/datum/component/material_container/proc/has_enough_of_category(category, amount, multiplier=1) + for(var/i in SSmaterials.materials_by_category[category]) + var/datum/material/mat = i + if(materials[mat] >= amount) //we have enough + return TRUE + return FALSE + +/// Turns a material amount into the amount of sheets it should output /datum/component/material_container/proc/amount2sheet(amt) if(amt >= MINERAL_MATERIAL_AMOUNT) return round(amt / MINERAL_MATERIAL_AMOUNT) return FALSE +/// Turns an amount of sheets into the amount of material amount it should output /datum/component/material_container/proc/sheet2amount(sheet_amt) if(sheet_amt > 0) return sheet_amt * MINERAL_MATERIAL_AMOUNT return FALSE -/datum/component/material_container/proc/amount(id) - var/datum/material/M = materials[id] - return M ? M.amount : 0 -//returns the amount of material relevant to this container; -//if this container does not support glass, any glass in 'I' will not be taken into account +///returns the amount of material relevant to this container; if this container does not support glass, any glass in 'I' will not be taken into account /datum/component/material_container/proc/get_item_material_amount(obj/item/I) if(!istype(I)) return FALSE var/material_amount = 0 - for(var/MAT in materials) + for(var/MAT in I.materials) material_amount += I.materials[MAT] return material_amount - -/datum/material - var/name - var/amount = 0 - var/id = null - var/sheet_type = null - var/coin_type = null - -/datum/material/metal - name = "Metal" - id = MAT_METAL - sheet_type = /obj/item/stack/sheet/metal - coin_type = /obj/item/coin/iron - -/datum/material/glass - name = "Glass" - id = MAT_GLASS - sheet_type = /obj/item/stack/sheet/glass - -/datum/material/silver - name = "Silver" - id = MAT_SILVER - sheet_type = /obj/item/stack/sheet/mineral/silver - coin_type = /obj/item/coin/silver - -/datum/material/gold - name = "Gold" - id = MAT_GOLD - sheet_type = /obj/item/stack/sheet/mineral/gold - coin_type = /obj/item/coin/gold - -/datum/material/diamond - name = "Diamond" - id = MAT_DIAMOND - sheet_type = /obj/item/stack/sheet/mineral/diamond - coin_type = /obj/item/coin/diamond - -/datum/material/uranium - name = "Uranium" - id = MAT_URANIUM - sheet_type = /obj/item/stack/sheet/mineral/uranium - coin_type = /obj/item/coin/uranium - -/datum/material/plasma - name = "Solid Plasma" - id = MAT_PLASMA - sheet_type = /obj/item/stack/sheet/mineral/plasma - coin_type = /obj/item/coin/plasma - -/datum/material/bluespace - name = "Bluespace Mesh" - id = MAT_BLUESPACE - sheet_type = /obj/item/stack/sheet/bluespace_crystal - -/datum/material/bananium - name = "Bananium" - id = MAT_BANANIUM - sheet_type = /obj/item/stack/sheet/mineral/bananium - coin_type = /obj/item/coin/bananium - -/datum/material/titanium - name = "Titanium" - id = MAT_TITANIUM - sheet_type = /obj/item/stack/sheet/mineral/titanium - -/datum/material/biomass - name = "Biomass" - id = MAT_BIOMASS - -/datum/material/plastic - name = "Plastic" - id = MAT_PLASTIC - sheet_type = /obj/item/stack/sheet/plastic +/// Returns the amount of a specific material in this container. +/datum/component/material_container/proc/get_material_amount(var/datum/material/mat) + if(!istype(mat)) + mat = getmaterialref(mat) + return(materials[mat]) \ No newline at end of file diff --git a/code/datums/components/radioactive.dm b/code/datums/components/radioactive.dm index 4554b643731c..697cb19088e1 100644 --- a/code/datums/components/radioactive.dm +++ b/code/datums/components/radioactive.dm @@ -18,7 +18,7 @@ hl3_release_date = _half_life can_contaminate = _can_contaminate - if(istype(parent, /atom)) + if(istype(parent, /atom)) RegisterSignal(parent, COMSIG_PARENT_EXAMINE, .proc/rad_examine) if(istype(parent, /obj/item)) RegisterSignal(parent, COMSIG_ITEM_ATTACK, .proc/rad_attack) @@ -89,6 +89,8 @@ /datum/component/radioactive/proc/rad_attack(datum/source, atom/movable/target, mob/living/user) radiation_pulse(parent, strength/20) target.rad_act(strength/2) + if(!hl3_release_date) + return strength -= strength / hl3_release_date #undef RAD_AMOUNT_LOW diff --git a/code/datums/components/remote_materials.dm b/code/datums/components/remote_materials.dm index 897e810fe62b..08d452017412 100644 --- a/code/datums/components/remote_materials.dm +++ b/code/datums/components/remote_materials.dm @@ -54,7 +54,7 @@ handles linking back and forth. /datum/component/remote_materials/proc/_MakeLocal() silo = null mat_container = parent.AddComponent(/datum/component/material_container, - list(MAT_METAL, MAT_GLASS, MAT_SILVER, MAT_GOLD, MAT_DIAMOND, MAT_PLASMA, MAT_URANIUM, MAT_BANANIUM, MAT_TITANIUM, MAT_BLUESPACE, MAT_PLASTIC), + list(/datum/material/iron, /datum/material/glass, /datum/material/silver, /datum/material/gold, /datum/material/diamond, /datum/material/plasma, /datum/material/uranium, /datum/material/bananium, /datum/material/titanium, /datum/material/bluespace, /datum/material/plastic), local_size, FALSE, /obj/item/stack) diff --git a/code/datums/materials/_material.dm b/code/datums/materials/_material.dm new file mode 100644 index 000000000000..7ef566dadb28 --- /dev/null +++ b/code/datums/materials/_material.dm @@ -0,0 +1,67 @@ +/*! Material datum + +Simple datum which is instanced once per type and is used for every object of said material. It has a variety of variables that define behavior. Subtyping from this makes it easier to create your own materials. + +*/ + + +/datum/material + var/name = "material" + var/desc = "its..stuff." + ///Var that's mostly used by science machines to identify specific materials, should most likely be phased out at some point + var/id = "mat" + ///Base color of the material, is used for greyscale. Item isn't changed in color if this is null. + var/color + ///Base alpha of the material, is used for greyscale icons. + var/alpha + ///Materials "Traits". its a map of key = category | Value = Bool. Used to define what it can be used for.gold + var/list/categories = list() + ///The type of sheet this material creates. This should be replaced as soon as possible by greyscale sheets. + var/sheet_type + ///The type of coin this material spawns. This should be replaced as soon as possible by greyscale coins. + var/coin_type + ///This is a modifier for force, and resembles the strength of the material + var/strength_modifier = 1 + ///This is a modifier for integrity, and resembles the strength of the material + var/integrity_modifier = 1 + +///This proc is called when the material is added to an object. +/datum/material/proc/on_applied(atom/source, amount, material_flags) + if(!(material_flags & MATERIAL_NO_COLOR)) //Prevent changing things with pre-set colors, to keep colored toolboxes their looks for example + if(color) //Do we have a custom color? + source.add_atom_colour(color, FIXED_COLOUR_PRIORITY) + if(alpha) + source.alpha = alpha + + if(istype(source, /obj)) //objs + on_applied_obj(source, amount, material_flags) + +///This proc is called when the material is added to an object specifically. +/datum/material/proc/on_applied_obj(var/obj/o, amount, material_flags) + var/new_max_integrity = CEILING(o.max_integrity * integrity_modifier, 1) + // This is to keep the same damage relative to the max integrity of the object + o.obj_integrity = (o.obj_integrity / o.max_integrity) * new_max_integrity + o.max_integrity = new_max_integrity + o.force *= strength_modifier + o.throwforce *= strength_modifier + + +///This proc is called when the material is removed from an object. +/datum/material/proc/on_removed(atom/source, material_flags) + if(!(material_flags & MATERIAL_NO_COLOR)) //Prevent changing things with pre-set colors, to keep colored toolboxes their looks for example + if(color) + source.remove_atom_colour(FIXED_COLOUR_PRIORITY, color) + source.alpha = initial(source.alpha) + + if(istype(source, /obj)) //objs + on_removed_obj(source, material_flags) + +///This proc is called when the material is removed from an object specifically. +/datum/material/proc/on_removed_obj(var/obj/o, amount, material_flags) + var/new_max_integrity = initial(o.max_integrity) + // This is to keep the same damage relative to the max integrity of the object + o.obj_integrity = (o.obj_integrity / o.max_integrity) * new_max_integrity + + o.max_integrity = new_max_integrity + o.force = initial(o.force) + o.throwforce = initial(o.throwforce) \ No newline at end of file diff --git a/code/datums/materials/basemats.dm b/code/datums/materials/basemats.dm new file mode 100644 index 000000000000..71b02a51e1c0 --- /dev/null +++ b/code/datums/materials/basemats.dm @@ -0,0 +1,147 @@ +///Has no special properties. +/datum/material/iron + name = "iron" + id = "iron" + desc = "Common iron ore often found in sedimentary and igneous layers of the crust." + color = "#878687" + categories = list(MAT_CATEGORY_ORE = TRUE, MAT_CATEGORY_RIGID = TRUE) + sheet_type = /obj/item/stack/sheet/metal + coin_type = /obj/item/coin/iron + +///Breaks extremely easily but is transparent. +/datum/material/glass + name = "glass" + id = "glass" + desc = "Glass forged by melting sand." + color = "#dae6f0" + alpha = 210 + categories = list(MAT_CATEGORY_RIGID = TRUE) + integrity_modifier = 0.1 + sheet_type = /obj/item/stack/sheet/glass + + +///Has no special properties. Could be good against vampires in the future perhaps. +/datum/material/silver + name = "silver" + id = "silver" + desc = "Silver" + color = "#bdbebf" + categories = list(MAT_CATEGORY_ORE = TRUE, MAT_CATEGORY_RIGID = TRUE) + sheet_type = /obj/item/stack/sheet/mineral/silver + coin_type = /obj/item/coin/silver + +///Slight force increase +/datum/material/gold + name = "gold" + id = "gold" + desc = "Gold" + color = "#f0972b" + strength_modifier = 1.2 + categories = list(MAT_CATEGORY_ORE = TRUE, MAT_CATEGORY_RIGID = TRUE) + sheet_type = /obj/item/stack/sheet/mineral/gold + coin_type = /obj/item/coin/gold + +///Has no special properties +/datum/material/diamond + name = "diamond" + id = "diamond" + desc = "Highly pressurized carbon" + color = "#22c2d4" + categories = list(MAT_CATEGORY_ORE = TRUE, MAT_CATEGORY_RIGID = TRUE) + sheet_type = /obj/item/stack/sheet/mineral/diamond + coin_type = /obj/item/coin/diamond + +///Is slightly radioactive +/datum/material/uranium + name = "uranium" + id = "uranium" + desc = "Uranium" + color = "#1fb83b" + categories = list(MAT_CATEGORY_ORE = TRUE, MAT_CATEGORY_RIGID = TRUE) + sheet_type = /obj/item/stack/sheet/mineral/uranium + coin_type = /obj/item/coin/uranium + +/datum/material/uranium/on_applied(atom/source, amount, material_flags) + . = ..() + source.AddComponent(/datum/component/radioactive, amount / 10, source, 0) //half-life of 0 because we keep on going. + +/datum/material/uranium/on_removed(atom/source, material_flags) + . = ..() + qdel(source.GetComponent(/datum/component/radioactive)) + + +///Adds firestacks on hit (Still needs support to turn into gas on destruction) +/datum/material/plasma + name = "plasma" + id = "plasma" + desc = "Isn't plasma a state of matter? Oh whatever." + color = "#c716b8" + categories = list(MAT_CATEGORY_ORE = TRUE, MAT_CATEGORY_RIGID = TRUE) + sheet_type = /obj/item/stack/sheet/mineral/plasma + coin_type = /obj/item/coin/plasma + +/datum/material/plasma/on_applied(atom/source, amount, material_flags) + . = ..() + if(ismovable(source)) + source.AddComponent(/datum/component/explodable, 0, 0, amount / 1000, amount / 500) + +/datum/material/plasma/on_removed(atom/source, material_flags) + . = ..() + qdel(source.GetComponent(/datum/component/explodable)) + +///Can cause bluespace effects on use. (Teleportation) (Not yet implemented) +/datum/material/bluespace + name = "bluespace crystal" + id = "bluespace_crystal" + desc = "Crystals with bluespace properties" + color = "#506bc7" + categories = list(MAT_CATEGORY_ORE = TRUE) + sheet_type = /obj/item/stack/sheet/bluespace_crystal + +///Honks and slips +/datum/material/bananium + name = "bananium" + id = "bananium" + desc = "Material with hilarious properties" + color = "#fff263" + categories = list(MAT_CATEGORY_ORE = TRUE, MAT_CATEGORY_RIGID = TRUE) + sheet_type = /obj/item/stack/sheet/mineral/bananium + coin_type = /obj/item/coin/bananium + +/datum/material/bananium/on_applied(atom/source, amount, material_flags) + . = ..() + source.AddComponent(/datum/component/squeak, list('sound/items/bikehorn.ogg'=1), 50) + source.AddComponent(/datum/component/slippery, min(amount / 10, 80)) + +/datum/material/bananium/on_removed(atom/source, amount, material_flags) + . = ..() + qdel(source.GetComponent(/datum/component/slippery)) + qdel(source.GetComponent(/datum/component/squeak)) + + +///Mediocre force increase +/datum/material/titanium + name = "titanium" + id = "titanium" + desc = "Titanium" + color = "#b3c0c7" + strength_modifier = 1.3 + categories = list(MAT_CATEGORY_ORE = TRUE, MAT_CATEGORY_RIGID = TRUE) + sheet_type = /obj/item/stack/sheet/mineral/titanium + +///Force decrease +/datum/material/plastic + name = "plastic" + id = "plastic" + desc = "plastic" + color = "#caccd9" + strength_modifier = 0.85 + sheet_type = /obj/item/stack/sheet/plastic + +///Force decrease and mushy sound effect. (Not yet implemented) +/datum/material/biomass + name = "biomass" + id = "biomass" + desc = "Organic matter" + color = "#735b4d" + strength_modifier = 0.8 \ No newline at end of file diff --git a/code/game/atoms.dm b/code/game/atoms.dm index 4232e98aa5ac..0088f21f4939 100644 --- a/code/game/atoms.dm +++ b/code/game/atoms.dm @@ -69,6 +69,11 @@ /// Radiation insulation types var/rad_insulation = RAD_NO_INSULATION + ///The custom materials this atom is made of, used by a lot of things like furniture, walls, and floors (if I finish the functionality, that is.) + var/list/custom_materials + ///Bitfield for how the atom handles materials. + var/material_flags = NONE + var/chat_color_name // Last name used to calculate a color for the chatmessage overlays var/chat_color // Last color calculated for the the chatmessage overlays @@ -156,6 +161,15 @@ if (canSmoothWith) canSmoothWith = typelist("canSmoothWith", canSmoothWith) + if(custom_materials && custom_materials.len) + var/temp_list = list() + for(var/i in custom_materials) + var/datum/material/material = getmaterialref(i) || i + temp_list[material] = custom_materials[material] //Get the proper instanced version + + custom_materials = null //Null the list to prepare for applying the materials properly + set_custom_materials(temp_list) + ComponentInitialize() return INITIALIZE_HINT_NORMAL @@ -448,6 +462,11 @@ if(desc) . += desc + if(custom_materials) + for(var/i in custom_materials) + var/datum/material/M = i + . += "It is made out of [M.name]." + if(reagents) if(reagents.flags & TRANSPARENT) . += "It contains:" @@ -1111,7 +1130,7 @@ /** * Recursive getter method to return a list of all ghosts orbitting this atom - * + * * This will work fine without manually passing arguments. */ /atom/proc/get_all_orbiters(list/processed, source = TRUE) @@ -1127,3 +1146,18 @@ var/atom/atom_orbiter = o output += atom_orbiter.get_all_orbiters(processed, source = FALSE) return output + +///Sets the custom materials for an item. +/atom/proc/set_custom_materials(var/list/materials, multiplier = 1) + if(custom_materials) //Only runs if custom materials existed at first. Should usually be the case but check anyways + for(var/i in custom_materials) + var/datum/material/custom_material = i + custom_material.on_removed(src, material_flags) //Remove the current materials + + custom_materials = list() //Reset the list + + for(var/x in materials) + var/datum/material/custom_material = x + + custom_material.on_applied(src, materials[custom_material] * multiplier, material_flags) + custom_materials[custom_material] += materials[x] * multiplier \ No newline at end of file diff --git a/code/game/gamemodes/clown_ops/clown_weapons.dm b/code/game/gamemodes/clown_ops/clown_weapons.dm index b2a698e409ca..2a2a2a19140c 100644 --- a/code/game/gamemodes/clown_ops/clown_weapons.dm +++ b/code/game/gamemodes/clown_ops/clown_weapons.dm @@ -40,14 +40,14 @@ /obj/item/clothing/shoes/clown_shoes/banana_shoes/combat/Initialize() . = ..() var/datum/component/material_container/bananium = GetComponent(/datum/component/material_container) - bananium.insert_amount(max_recharge, MAT_BANANIUM) + bananium.insert_amount_mat(max_recharge, /datum/material/bananium) START_PROCESSING(SSobj, src) /obj/item/clothing/shoes/clown_shoes/banana_shoes/combat/process() var/datum/component/material_container/bananium = GetComponent(/datum/component/material_container) - var/bananium_amount = bananium.amount(MAT_BANANIUM) + var/bananium_amount = bananium.get_material_amount(/datum/material/bananium) if(bananium_amount < max_recharge) - bananium.insert_amount(min(recharge_rate, max_recharge - bananium_amount), MAT_BANANIUM) + bananium.insert_amount_mat(min(recharge_rate, max_recharge - bananium_amount), /datum/material/bananium) /obj/item/clothing/shoes/clown_shoes/banana_shoes/combat/attack_self(mob/user) ui_action_click(user) diff --git a/code/game/machinery/autolathe.dm b/code/game/machinery/autolathe.dm index 4bd655fae919..6f4158d60fdd 100644 --- a/code/game/machinery/autolathe.dm +++ b/code/game/machinery/autolathe.dm @@ -41,7 +41,7 @@ var/list/categories = list("Tools","Electronics","Construction","T-Comm","Security","Machinery","Medical","Misc","Dinnerware","Imported", "Search") /obj/machinery/autolathe/Initialize() - AddComponent(/datum/component/material_container, list(MAT_METAL, MAT_GLASS), 0, TRUE, null, null, CALLBACK(src, .proc/AfterMaterialInsert)) + AddComponent(/datum/component/material_container, list(/datum/material/iron, /datum/material/glass), 0, TRUE, null, null, CALLBACK(src, .proc/AfterMaterialInsert)) . = ..() wires = new /datum/wires/autolathe(src) @@ -74,8 +74,8 @@ var/datum/component/material_container/materials = GetComponent(/datum/component/material_container) data["total_amount"] = materials.total_amount data["max_amount"] = materials.max_amount - data["metal_amount"] = materials.amount(MAT_METAL) - data["glass_amount"] = materials.amount(MAT_GLASS) + data["metal_amount"] = materials.get_material_amount(/datum/material/iron) + data["glass_amount"] = materials.get_material_amount(/datum/material/glass) data["rightwall"] = wallcheck(4) // Wall data for ui data["leftwall"] = wallcheck(8) data["abovewall"] = wallcheck(1) @@ -95,7 +95,9 @@ design["category"] = D.category var/max_multiplier_list = list() if(ispath(D.build_path, /obj/item/stack)) - var/max_multiplier = min(D.maxstack, D.materials[MAT_METAL] ? round(materials.amount(MAT_METAL)/D.materials[MAT_METAL]):INFINITY,D.materials[MAT_GLASS]?round(materials.amount(MAT_GLASS)/D.materials[MAT_GLASS]):INFINITY) + var/max_multiplier + for(var/datum/material/mat in D.materials) + max_multiplier = min(D.maxstack, round(materials.get_material_amount(mat)/D.materials[mat])) if (max_multiplier > 10 && !disabled) max_multiplier_list += "10" if (max_multiplier > 25 && !disabled) @@ -222,9 +224,9 @@ use_power(MINERAL_MATERIAL_AMOUNT / 10) else switch(id_inserted) - if (MAT_METAL) + if (/datum/material/iron) flick("autolathe_o",src)//plays metal insertion animation - if (MAT_GLASS) + else flick("autolathe_r",src)//plays glass insertion animation use_power(min(1000, amount_inserted / 100)) updateUsrDialog() @@ -250,29 +252,33 @@ var/datum/component/material_container/materials = GetComponent(/datum/component/material_container) var/dat = "Total amount: [materials.total_amount] / [materials.max_amount] cm3
" for(var/mat_id in materials.materials) - var/datum/material/M = materials.materials[mat_id] - dat += "[M.name] amount: [M.amount] cm3
" + var/datum/material/M = mat_id + var/mineral_amount = materials.materials[mat_id] + if(mineral_amount > 0) + dat += "[M.name] amount: [mineral_amount] cm3
" return dat /obj/machinery/autolathe/proc/can_build(datum/design/D, amount = 1) if(D.make_reagents.len) return FALSE var/coeff = (ispath(D.build_path, /obj/item/stack) ? 1 : prod_coeff) + + var/list/required_materials = list() + + for(var/i in D.materials) + required_materials[i] = D.materials[i] * coeff * amount + var/datum/component/material_container/materials = GetComponent(/datum/component/material_container) - if(D.materials[MAT_METAL] && (materials.amount(MAT_METAL) < (D.materials[MAT_METAL] * coeff * amount))) - return FALSE - if(D.materials[MAT_GLASS] && (materials.amount(MAT_GLASS) < (D.materials[MAT_GLASS] * coeff * amount))) - return FALSE if(wallcheck(printdirection)) say("Output blocked, please remove obstruction.") return FALSE - return TRUE + return materials.has_materials(required_materials) /obj/machinery/autolathe/proc/get_design_cost_metal(datum/design/D) var/coeff = (ispath(D.build_path, /obj/item/stack) ? 1 : prod_coeff) var/dat - if(D.materials[MAT_METAL]) - dat = D.materials[MAT_METAL] * coeff + if(D.materials[/datum/material/iron]) + dat = D.materials[/datum/material/iron] * coeff else dat = 0 return dat @@ -280,8 +286,8 @@ /obj/machinery/autolathe/proc/get_design_cost_glass(datum/design/D) var/coeff = (ispath(D.build_path, /obj/item/stack) ? 1 : prod_coeff) var/dat - if(D.materials[MAT_GLASS]) - dat = D.materials[MAT_GLASS] * coeff + if(D.materials[/datum/material/glass]) + dat = D.materials[/datum/material/glass] * coeff else dat = 0 return dat @@ -333,18 +339,37 @@ /obj/machinery/autolathe/proc/make_item(datum/design/D, multiplier) var/is_stack = ispath(request.build_path, /obj/item/stack) var/coeff = (is_stack ? 1 : prod_coeff) //stacks are unaffected by production coefficient - var/metal_cost = request.materials[MAT_METAL] - var/glass_cost = request.materials[MAT_GLASS] - var/power = max(2000, (metal_cost + glass_cost) * multiplier / 5) + var/total_amount = 0 + for(var/MAT in request.materials) + total_amount += request.materials[MAT] + var/power = max(2000, (total_amount)*multiplier/5) //Change this to use all materials var/datum/component/material_container/materials = GetComponent(/datum/component/material_container) if (!materials) say("No access to material storage, please contact the quartermaster.") return FALSE if(can_build(D, multiplier)) // Check if we can build if not, return - if((materials.amount(MAT_METAL) >= metal_cost * multiplier * coeff) && (materials.amount(MAT_GLASS) >= glass_cost * multiplier * coeff)) + var/list/materials_used = list() + var/list/picked_materials + var/list/custom_materials = list() //These will apply their material effect, This should usually only be one. + for(var/MAT in request.materials) + var/datum/material/used_material = MAT + var/amount_needed = request.materials[MAT] * coeff * multiplier + if(istext(used_material)) //This means its a category + var/list/list_to_show = list() + for(var/i in SSmaterials.materials_by_category[used_material]) + if(materials.materials[i]) + list_to_show += i + + used_material = input("Choose [used_material]", "Custom Material") as null|anything in list_to_show + if(!used_material) + return //Didn't pick any material, so you can't build shit either. + custom_materials[used_material] += amount_needed + + materials_used[used_material] = amount_needed + + if(materials.has_materials(materials_used)) use_power(power) - var/list/materials_used = list(MAT_METAL=metal_cost * coeff * multiplier, MAT_GLASS=glass_cost * coeff*multiplier) - materials.use_amount(materials_used) + materials.use_materials(materials_used) being_built = list(D, multiplier) desc = "It's building \a [initial(D.name)]." icon_state = "autolathe_n" @@ -367,6 +392,9 @@ for(var/mat in materials_used) new_item.materials[mat] = materials_used[mat] / multiplier new_item.autolathe_crafted(src) + if(picked_materials.len) + new_item.set_custom_materials(picked_materials, 1 / multiplier) //Ensure we get the non multiplied amount + item_beingbuilt = null icon_state = "autolathe" updateUsrDialog() diff --git a/code/game/machinery/bounty_board.dm b/code/game/machinery/bounty_board.dm index 488e31bfab65..bbd745ef41d0 100644 --- a/code/game/machinery/bounty_board.dm +++ b/code/game/machinery/bounty_board.dm @@ -164,7 +164,7 @@ GLOBAL_LIST_EMPTY(request_list) name = "disassembled bounty board" desc = "Used to build a new bounty board, just secure to the wall." icon_state = "request_kiosk" - materials = list(MAT_METAL = 14000, MAT_GLASS = 8000) + materials = list(/datum/material/iron = 14000, /datum/material/glass = 8000) result_path = /obj/machinery/bounty_board /** diff --git a/code/game/machinery/buttons.dm b/code/game/machinery/buttons.dm index a07fea86f9a7..73e2226c4d5a 100644 --- a/code/game/machinery/buttons.dm +++ b/code/game/machinery/buttons.dm @@ -287,4 +287,4 @@ desc = "Used for building buttons." icon_state = "button" result_path = /obj/machinery/button - materials = list(MAT_METAL=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/iron=MINERAL_MATERIAL_AMOUNT) diff --git a/code/game/machinery/camera/camera_assembly.dm b/code/game/machinery/camera/camera_assembly.dm index d3066739ca89..a20facc7a5b7 100644 --- a/code/game/machinery/camera/camera_assembly.dm +++ b/code/game/machinery/camera/camera_assembly.dm @@ -8,7 +8,7 @@ desc = "The basic construction for Nanotrasen-Always-Watching-You cameras." icon = 'icons/obj/machines/camera.dmi' icon_state = "cameracase" - materials = list(MAT_METAL=400, MAT_GLASS=250) + materials = list(/datum/material/iron=400, /datum/material/glass=250) result_path = /obj/structure/camera_assembly /obj/structure/camera_assembly diff --git a/code/game/machinery/defibrillator_mount.dm b/code/game/machinery/defibrillator_mount.dm index 3f44c9a72ec8..46cec39392a6 100644 --- a/code/game/machinery/defibrillator_mount.dm +++ b/code/game/machinery/defibrillator_mount.dm @@ -138,7 +138,7 @@ desc = "A frame for a defibrillator mount. It can't be removed once it's placed." icon = 'icons/obj/machines/defib_mount.dmi' icon_state = "defibrillator_mount" - materials = list(MAT_METAL = 300, MAT_GLASS = 100) + materials = list(/datum/material/iron = 300, /datum/material/glass = 100) w_class = WEIGHT_CLASS_BULKY result_path = /obj/machinery/defibrillator_mount pixel_shift = -28 diff --git a/code/game/machinery/deployable.dm b/code/game/machinery/deployable.dm index 904941092efb..5aa2b132a32c 100644 --- a/code/game/machinery/deployable.dm +++ b/code/game/machinery/deployable.dm @@ -15,7 +15,7 @@ density = TRUE max_integrity = 100 var/proj_pass_rate = 50 //How many projectiles will pass the cover. Lower means stronger cover - var/material = METAL + var/bar_material = METAL /obj/structure/barricade/deconstruct(disassembled = TRUE) if(!(flags_1 & NODECONSTRUCT_1)) @@ -26,7 +26,7 @@ return /obj/structure/barricade/attackby(obj/item/I, mob/user, params) - if(I.tool_behaviour == TOOL_WELDER && user.a_intent != INTENT_HARM && material == METAL) + if(I.tool_behaviour == TOOL_WELDER && user.a_intent != INTENT_HARM && bar_material == METAL) if(obj_integrity < max_integrity) if(!I.tool_start_check(user, amount=0)) return @@ -60,7 +60,7 @@ desc = "This space is blocked off by a wooden barricade." icon = 'icons/obj/structures.dmi' icon_state = "woodenbarricade" - material = WOOD + bar_material = WOOD var/drop_amount = 3 /obj/structure/barricade/wooden/attackby(obj/item/I, mob/user) @@ -112,7 +112,7 @@ max_integrity = 280 proj_pass_rate = 20 pass_flags = LETPASSTHROW - material = SAND + bar_material = SAND climbable = TRUE smooth = SMOOTH_TRUE canSmoothWith = list(/obj/structure/barricade/sandbags, /turf/closed/wall, /turf/closed/wall/r_wall, /obj/structure/falsewall, /obj/structure/falsewall/reinforced, /turf/closed/wall/rust, /turf/closed/wall/r_wall/rust, /obj/structure/barricade/security) diff --git a/code/game/machinery/droneDispenser.dm b/code/game/machinery/droneDispenser.dm index 1484a998342b..f31b8fc73104 100644 --- a/code/game/machinery/droneDispenser.dm +++ b/code/game/machinery/droneDispenser.dm @@ -50,10 +50,10 @@ /obj/machinery/droneDispenser/Initialize() . = ..() - var/datum/component/material_container/materials = AddComponent(/datum/component/material_container, list(MAT_METAL, MAT_GLASS), MINERAL_MATERIAL_AMOUNT * MAX_STACK_SIZE * 2, TRUE, /obj/item/stack) - materials.insert_amount(starting_amount) + var/datum/component/material_container/materials = AddComponent(/datum/component/material_container, list(/datum/material/iron, /datum/material/glass), MINERAL_MATERIAL_AMOUNT * MAX_STACK_SIZE * 2, TRUE, /obj/item/stack) + materials.insert_amount_mat(starting_amount) materials.precise_insertion = TRUE - using_materials = list(MAT_METAL=metal_cost, MAT_GLASS=glass_cost) + using_materials = list(/datum/material/iron=metal_cost, /datum/material/glass=glass_cost) /obj/machinery/droneDispenser/preloaded starting_amount = 5000 @@ -138,7 +138,7 @@ update_icon() if(DRONE_PRODUCTION) - materials.use_amount(using_materials) + materials.use_materials(using_materials) if(power_used) use_power(power_used) diff --git a/code/game/machinery/newscaster.dm b/code/game/machinery/newscaster.dm index e7907a8623e4..1cbe6afae445 100644 --- a/code/game/machinery/newscaster.dm +++ b/code/game/machinery/newscaster.dm @@ -174,7 +174,7 @@ GLOBAL_LIST_EMPTY(allCasters) name = "newscaster frame" desc = "Used to build newscasters, just secure to the wall." icon_state = "newscaster" - materials = list(MAT_METAL=14000, MAT_GLASS=8000) + materials = list(/datum/material/iron=14000, /datum/material/glass=8000) result_path = /obj/machinery/newscaster diff --git a/code/game/machinery/porta_turret/portable_turret.dm b/code/game/machinery/porta_turret/portable_turret.dm index 580269fbeb76..89b19680230e 100644 --- a/code/game/machinery/porta_turret/portable_turret.dm +++ b/code/game/machinery/porta_turret/portable_turret.dm @@ -954,7 +954,7 @@ desc = "Used for building turret control panels." icon_state = "apc" result_path = /obj/machinery/turretid - materials = list(MAT_METAL=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/iron=MINERAL_MATERIAL_AMOUNT) /obj/item/gun/proc/get_turret_properties() . = list() diff --git a/code/game/machinery/recycler.dm b/code/game/machinery/recycler.dm index 06c4d8306473..5a3ff5c06e28 100644 --- a/code/game/machinery/recycler.dm +++ b/code/game/machinery/recycler.dm @@ -18,7 +18,7 @@ var/item_recycle_sound = 'sound/items/welder.ogg' /obj/machinery/recycler/Initialize() - AddComponent(/datum/component/material_container, list(MAT_METAL, MAT_GLASS, MAT_PLASMA, MAT_SILVER, MAT_GOLD, MAT_DIAMOND, MAT_URANIUM, MAT_BANANIUM, MAT_TITANIUM, MAT_BLUESPACE, MAT_PLASTIC), INFINITY, FALSE, null, null, null, TRUE) + AddComponent(/datum/component/material_container, list(/datum/material/iron, /datum/material/glass, /datum/material/plasma, /datum/material/silver, /datum/material/gold, /datum/material/diamond, /datum/material/uranium, /datum/material/bananium, /datum/material/titanium, /datum/material/bluespace, /datum/material/plastic), INFINITY, FALSE, null, null, null, TRUE) AddComponent(/datum/component/butchering, 1, amount_produced,amount_produced/5) . = ..() update_icon() diff --git a/code/game/mecha/equipment/mecha_equipment.dm b/code/game/mecha/equipment/mecha_equipment.dm index 97a5378a5bd0..9559c9e9da69 100644 --- a/code/game/mecha/equipment/mecha_equipment.dm +++ b/code/game/mecha/equipment/mecha_equipment.dm @@ -16,6 +16,8 @@ var/selectable = 1 // Set to 0 for passive equipment such as mining scanner or armor plates var/harmful = FALSE //Controls if equipment can be used to attack by a pacifist. var/destroy_sound = 'sound/mecha/critdestr.ogg' + /// Bitflag. Used by exosuit fabricator to assign sub-categories based on which exosuits can equip this. + var/mech_flags = NONE /obj/item/mecha_parts/mecha_equipment/proc/update_chassis_page() if(chassis) diff --git a/code/game/mecha/equipment/tools/medical_tools.dm b/code/game/mecha/equipment/tools/medical_tools.dm index c569edde353c..02f2b51c9b79 100644 --- a/code/game/mecha/equipment/tools/medical_tools.dm +++ b/code/game/mecha/equipment/tools/medical_tools.dm @@ -1,7 +1,7 @@ // Sleeper, Medical Beam, and Syringe gun /obj/item/mecha_parts/mecha_equipment/medical - + mech_flags = EXOSUIT_MODULE_MEDICAL /obj/item/mecha_parts/mecha_equipment/medical/Initialize() . = ..() START_PROCESSING(SSobj, src) @@ -529,7 +529,7 @@ range = MELEE|RANGED equip_cooldown = 0 var/obj/item/gun/medbeam/mech/medigun - materials = list(MAT_METAL = 15000, MAT_GLASS = 8000, MAT_PLASMA = 3000, MAT_GOLD = 8000, MAT_DIAMOND = 2000) + materials = list(/datum/material/iron = 15000, /datum/material/glass = 8000, /datum/material/plasma = 3000, /datum/material/gold = 8000, /datum/material/diamond = 2000) /obj/item/mecha_parts/mecha_equipment/medical/mechmedbeam/Initialize() . = ..() diff --git a/code/game/mecha/equipment/tools/mining_tools.dm b/code/game/mecha/equipment/tools/mining_tools.dm index 9a33a596a072..bae8f5046cfb 100644 --- a/code/game/mecha/equipment/tools/mining_tools.dm +++ b/code/game/mecha/equipment/tools/mining_tools.dm @@ -167,4 +167,4 @@ mineral_scan_pulse(get_turf(src)) #undef DRILL_BASIC -#undef DRILL_HARDENED +#undef DRILL_HARDENED \ No newline at end of file diff --git a/code/game/mecha/equipment/tools/other_tools.dm b/code/game/mecha/equipment/tools/other_tools.dm index 392b3ebdbefa..60c8627d4480 100644 --- a/code/game/mecha/equipment/tools/other_tools.dm +++ b/code/game/mecha/equipment/tools/other_tools.dm @@ -400,7 +400,8 @@ /obj/item/mecha_parts/mecha_equipment/generator/get_equip_info() var/output = ..() if(output) - return "[output] \[[fuel]: [round(fuel.amount*fuel.perunit,0.1)] cm3\] - [equip_ready?"A":"Dea"]ctivate" + return "[output] \[[fuel]: [round(fuel.amount*fuel.mats_per_stack,0.1)] cm3\] - [equip_ready?"A":"Dea"]ctivate" + /obj/item/mecha_parts/mecha_equipment/generator/action(target) if(chassis) @@ -410,9 +411,9 @@ /obj/item/mecha_parts/mecha_equipment/generator/proc/load_fuel(var/obj/item/stack/sheet/P) if(P.type == fuel.type && P.amount > 0) - var/to_load = max(max_fuel - fuel.amount*fuel.perunit,0) + var/to_load = max(max_fuel - fuel.amount*fuel.mats_per_stack,0) if(to_load) - var/units = min(max(round(to_load / P.perunit),1),P.amount) + var/units = min(max(round(to_load / P.mats_per_stack),1),P.amount) fuel.amount += units P.use(units) occupant_message("[units] unit\s of [fuel] successfully loaded.") @@ -448,7 +449,7 @@ if(cur_charge < chassis.cell.maxcharge) use_fuel = fuel_per_cycle_active chassis.give_power(power_per_cycle) - fuel.amount -= min(use_fuel/fuel.perunit,fuel.amount) + fuel.amount -= min(use_fuel/fuel.mats_per_stack,fuel.amount) update_equip_info() return 1 diff --git a/code/game/mecha/equipment/weapons/weapons.dm b/code/game/mecha/equipment/weapons/weapons.dm index b7e4a357097e..24370da065e4 100644 --- a/code/game/mecha/equipment/weapons/weapons.dm +++ b/code/game/mecha/equipment/weapons/weapons.dm @@ -10,6 +10,7 @@ var/projectile_delay = 0 var/firing_effect_type = /obj/effect/temp_visual/dir_setting/firing_effect //the visual effect appearing when the weapon is fired. var/kickback = TRUE //Will using this weapon in no grav push mecha back. + mech_flags = EXOSUIT_MODULE_COMBAT /obj/item/mecha_parts/mecha_equipment/weapon/can_attach(obj/mecha/M) if(!..()) @@ -153,7 +154,7 @@ fire_sound = 'sound/weapons/plasma_cutter.ogg' harmful = TRUE -/obj/item/mecha_parts/mecha_equipment/weapon/energy/plasma/can_attach(obj/mecha/working/M) +/obj/item/mecha_parts/mecha_equipment/weapon/energy/plasma/can_attach(obj/mecha/M) if(..()) //combat mech return 1 else if(M.equipment.len < M.max_equip && istype(M)) @@ -178,6 +179,7 @@ equip_cooldown = 150 range = MELEE|RANGED kickback = FALSE + mech_flags = EXOSUIT_MODULE_HONK /obj/item/mecha_parts/mecha_equipment/weapon/honker/can_attach(obj/mecha/combat/honker/M) if(..()) @@ -428,6 +430,7 @@ missile_speed = 1.5 projectile_energy_cost = 100 equip_cooldown = 20 + mech_flags = EXOSUIT_MODULE_HONK /obj/item/mecha_parts/mecha_equipment/weapon/ballistic/launcher/banana_mortar/can_attach(obj/mecha/combat/honker/M) if(..()) @@ -445,6 +448,7 @@ missile_speed = 1.5 projectile_energy_cost = 100 equip_cooldown = 10 + mech_flags = EXOSUIT_MODULE_HONK /obj/item/mecha_parts/mecha_equipment/weapon/ballistic/launcher/mousetrap_mortar/can_attach(obj/mecha/combat/honker/M) if(..()) @@ -470,6 +474,7 @@ projectiles = 10 projectile_energy_cost = 500 diags_first = TRUE + mech_flags = EXOSUIT_MODULE_HONK /obj/item/mecha_parts/mecha_equipment/weapon/ballistic/launcher/punching_glove/can_attach(obj/mecha/combat/honker/M) if(..()) @@ -499,4 +504,4 @@ if(ismovable(hit_atom)) var/atom/movable/AM = hit_atom AM.safe_throw_at(get_edge_target_turf(AM,get_dir(src, AM)), 7, 2) - qdel(src) + qdel(src) \ No newline at end of file diff --git a/code/game/mecha/mech_fabricator.dm b/code/game/mecha/mech_fabricator.dm index 11ed0661c8cf..611db41db56e 100644 --- a/code/game/mecha/mech_fabricator.dm +++ b/code/game/mecha/mech_fabricator.dm @@ -9,22 +9,44 @@ active_power_usage = 5000 req_access = list(ACCESS_ROBOTICS) circuit = /obj/item/circuitboard/machine/mechfab - var/time_coeff = 1 - var/component_coeff = 1 - var/datum/techweb/specialized/autounlocking/exofab/stored_research - var/sync = 0 - var/part_set - var/datum/design/being_built + subsystem_type = /datum/controller/subsystem/processing/fastprocess + + /// Current items in the build queue. var/list/queue = list() - var/processing_queue = 0 - var/screen = "main" - var/temp + /// Whether or not the machine is building the entire queue automagically. + var/process_queue = FALSE + + /// The current design datum that the machine is building. + var/datum/design/being_built + /// World time when the build will finish. + var/build_finish = 0 + /// World time when the build started. + var/build_start = 0 + /// Reference to all materials used in the creation of the item being_built. + var/list/build_materials + /// Part currently stored in the Exofab. + var/obj/item/stored_part + + /// Coefficient for the speed of item building. Based on the installed parts. + var/time_coeff = 1 + /// Coefficient for the efficiency of material usage in item building. Based on the installed parts. + var/component_coeff = 1 + + /// Reference to the techweb. + var/datum/techweb/stored_research + + /// Whether the Exofab links to the ore silo on init. Special derelict or maintanance variants should set this to FALSE. + var/link_on_init = TRUE + + /// Reference to a remote material inventory, such as an ore silo. var/datum/component/remote_materials/rmat + + /// A list of categories that valid MECHFAB design datums will broadly categorise themselves under. var/list/part_sets = list( "Cyborg", "Ripley", - "Firefighter", "Odysseus", + "Clarke", "Gygax", "Durand", "H.O.N.K", @@ -32,12 +54,16 @@ "Exosuit Equipment", "Exosuit Ammunition", "Cyborg Upgrade Modules", + "Cybernetics", + "Implants", + "Control Interfaces", "Misc" ) /obj/machinery/mecha_part_fabricator/Initialize(mapload) - stored_research = new - rmat = AddComponent(/datum/component/remote_materials, "mechfab", mapload) + stored_research = SSresearch.science_tech + rmat = AddComponent(/datum/component/remote_materials, "mechfab", mapload && link_on_init) + RefreshParts() //Recalculating local material sizes if the fab isn't linked return ..() /obj/machinery/mecha_part_fabricator/RefreshParts() @@ -60,347 +86,520 @@ T += Ml.rating time_coeff = round(initial(time_coeff) - (initial(time_coeff)*(T))/5,0.01) + // Adjust the build time of any item currently being built. + if(being_built) + var/last_const_time = build_finish - build_start + var/new_const_time = get_construction_time_w_coeff(initial(being_built.construction_time)) + var/const_time_left = build_finish - world.time + var/new_build_time = (new_const_time / last_const_time) * const_time_left + build_finish = world.time + new_build_time + + update_static_data(usr) + /obj/machinery/mecha_part_fabricator/examine(mob/user) . = ..() if(in_range(user, src) || isobserver(user)) - . += "The status display reads: Storing up to [rmat.local_size] material units.
Material consumption at [component_coeff*100]%.
Build time reduced by [100-time_coeff*100]%." + . += "The status display reads: Storing up to [rmat.local_size] material units.
Material consumption at [component_coeff*100]%.
Build time reduced by [100-time_coeff*100]%.
" -/obj/machinery/mecha_part_fabricator/emag_act() - if(obj_flags & EMAGGED) - return - obj_flags |= EMAGGED - req_access = list() - say("DB error \[Code 0x00F1\]") - sleep(10) - say("Attempting auto-repair...") - sleep(15) - say("User DB corrupted \[Code 0x00FA\]. Truncating data structure...") - sleep(30) - say("User DB truncated. Please contact your Nanotrasen system operator for future assistance.") - - -/obj/machinery/mecha_part_fabricator/proc/output_parts_list(set_name) - var/output = "" - for(var/v in stored_research.researched_designs) - var/datum/design/D = SSresearch.techweb_design_by_id(v) - if(D.build_type & MECHFAB) - if(!(set_name in D.category)) - continue - output += "
[output_part_info(D)]
\[" - if(check_resources(D)) - output += "Build | " - output += "Add to queue\]\[?\]
" - return output - -/obj/machinery/mecha_part_fabricator/proc/output_part_info(datum/design/D) - var/output = "[initial(D.name)] (Cost: [output_part_cost(D)]) [get_construction_time_w_coeff(D)/10]sec" - return output - -/obj/machinery/mecha_part_fabricator/proc/output_part_cost(datum/design/D) - var/i = 0 - var/output +/** + * Generates an info list for a given part. + * + * Returns a list of part information. + * * D - Design datum to get information on. + * * categories - Boolean, whether or not to parse snowflake categories into the part information list. + */ +/obj/machinery/mecha_part_fabricator/proc/output_part_info(datum/design/D, categories = FALSE) + var/cost = list() for(var/c in D.materials) - output += "[i?" | ":null][get_resource_cost_w_coeff(D, c)] [material2name(c)]" - i++ - return output + var/datum/material/M = c + cost[M.name] = get_resource_cost_w_coeff(D, M) + var/obj/built_item = D.build_path + + var/list/category_override = null + var/list/sub_category = null + + if(categories) + // Handle some special cases to build up sub-categories for the fab interface. + // Start with checking if this design builds a cyborg module. + if(built_item in typesof(/obj/item/borg/upgrade)) + var/obj/item/borg/upgrade/U = built_item + var/module_types = initial(U.module_flags) + sub_category = list() + if(module_types) + if(module_types & BORG_MODULE_SECURITY) + sub_category += "Security" + if(module_types & BORG_MODULE_MINER) + sub_category += "Mining" + if(module_types & BORG_MODULE_JANITOR) + sub_category += "Janitor" + if(module_types & BORG_MODULE_MEDICAL) + sub_category += "Medical" + if(module_types & BORG_MODULE_ENGINEERING) + sub_category += "Engineering" + else + sub_category += "All Cyborgs" + // Else check if this design builds a piece of exosuit equipment. + else if(built_item in typesof(/obj/item/mecha_parts/mecha_equipment)) + var/obj/item/mecha_parts/mecha_equipment/E = built_item + var/mech_types = initial(E.mech_flags) + sub_category = "Equipment" + if(mech_types) + category_override = list() + if(mech_types & EXOSUIT_MODULE_RIPLEY) + category_override += "Ripley" + if(mech_types & EXOSUIT_MODULE_ODYSSEUS) + category_override += "Odysseus" + if(mech_types & EXOSUIT_MODULE_CLARKE) + category_override += "Clarke" + if(mech_types & EXOSUIT_MODULE_GYGAX) + category_override += "Gygax" + if(mech_types & EXOSUIT_MODULE_DURAND) + category_override += "Durand" + if(mech_types & EXOSUIT_MODULE_HONK) + category_override += "H.O.N.K" + if(mech_types & EXOSUIT_MODULE_PHAZON) + category_override += "Phazon" + + + var/list/part = list( + "name" = D.name, + "desc" = initial(built_item.desc), + "printTime" = get_construction_time_w_coeff(initial(D.construction_time))/10, + "cost" = cost, + "id" = D.id, + "subCategory" = sub_category, + "categoryOverride" = category_override, + "searchMeta" = D.search_metadata + ) + + return part + +/** + * Generates a list of resources / materials available to this Exosuit Fab + * + * Returns null if there is no material container available. + * List format is list(material_name = list(amount = ..., ref = ..., etc.)) + */ /obj/machinery/mecha_part_fabricator/proc/output_available_resources() - var/output var/datum/component/material_container/materials = rmat.mat_container + var/list/material_data = list() + if(materials) for(var/mat_id in materials.materials) - var/datum/material/M = materials.materials[mat_id] - output += "[M.name]: [M.amount] cm³" - if(M.amount >= MINERAL_MATERIAL_AMOUNT) - output += "- Remove \[1\]" - if(M.amount >= (MINERAL_MATERIAL_AMOUNT * 10)) - output += " | \[10\]" - output += " | \[All\]" - output += "
" - else - output += "No material storage connected, please contact the quartermaster.
" - return output + var/datum/material/M = mat_id + var/list/material_info = list() + var/amount = materials.materials[mat_id] + material_info = list( + "name" = M.name, + "ref" = REF(M), + "amount" = amount, + "sheets" = round(amount / MINERAL_MATERIAL_AMOUNT), + "removable" = amount >= MINERAL_MATERIAL_AMOUNT + ) + + material_data += list(material_info) + + return material_data + + return null + +/** + * Intended to be called when an item starts printing. + * + * Adds the overlay to show the fab working and sets active power usage settings. + */ +/obj/machinery/mecha_part_fabricator/proc/on_start_printing() + add_overlay("fab-active") + use_power = ACTIVE_POWER_USE + +/** + * Intended to be called when the exofab has stopped working and is no longer printing items. + * + * Removes the overlay to show the fab working and sets idle power usage settings. Additionally resets the description and turns off queue processing. + */ +/obj/machinery/mecha_part_fabricator/proc/on_finish_printing() + cut_overlay("fab-active") + use_power = IDLE_POWER_USE + desc = initial(desc) + process_queue = FALSE + +/** + * Calculates resource/material costs for printing an item based on the machine's resource coefficient. + * + * Returns a list of k,v resources with their amounts. + * * D - Design datum to calculate the modified resource cost of. + */ /obj/machinery/mecha_part_fabricator/proc/get_resources_w_coeff(datum/design/D) var/list/resources = list() for(var/R in D.materials) - resources[R] = get_resource_cost_w_coeff(D, R) + var/datum/material/M = R + resources[M] = get_resource_cost_w_coeff(D, M) return resources +/** + * Checks if the Exofab has enough resources to print a given item. + * + * Returns FALSE if the design has no reagents used in its construction (?) or if there are insufficient resources. + * Returns TRUE if there are sufficient resources to print the item. + * * D - Design datum to calculate the modified resource cost of. + */ /obj/machinery/mecha_part_fabricator/proc/check_resources(datum/design/D) - if(D.reagents_list.len) // No reagents storage - no reagent designs. + if(length(D.reagents_list)) // No reagents storage - no reagent designs. return FALSE var/datum/component/material_container/materials = rmat.mat_container if(materials.has_materials(get_resources_w_coeff(D))) return TRUE return FALSE -/obj/machinery/mecha_part_fabricator/proc/build_part(datum/design/D) - var/list/res_coef = get_resources_w_coeff(D) +/** + * Attempts to build the next item in the build queue. + * + * Returns FALSE if either there are no more parts to build or the next part is not buildable. + * Returns TRUE if the next part has started building. + * * verbose - Whether the machine should use say() procs. Set to FALSE to disable the machine saying reasons for failure to build. + */ +/obj/machinery/mecha_part_fabricator/proc/build_next_in_queue(verbose = TRUE) + if(!length(queue)) + return FALSE + + var/datum/design/D = queue[1] + if(build_part(D, verbose)) + remove_from_queue(1) + return TRUE + + return FALSE + +/** + * Starts the build process for a given design datum. + * + * Returns FALSE if the procedure fails. Returns TRUE when being_built is set. + * Uses materials. + * * D - Design datum to attempt to print. + * * verbose - Whether the machine should use say() procs. Set to FALSE to disable the machine saying reasons for failure to build. + */ +/obj/machinery/mecha_part_fabricator/proc/build_part(datum/design/D, verbose = TRUE) + if(!D) + return FALSE var/datum/component/material_container/materials = rmat.mat_container if (!materials) - say("No access to material storage, please contact the quartermaster.") - return 0 + if(verbose) + say("No access to material storage, please contact the quartermaster.") + return FALSE if (rmat.on_hold()) - say("Mineral access is on hold, please contact the quartermaster.") - return 0 + if(verbose) + say("Mineral access is on hold, please contact the quartermaster.") + return FALSE if(!check_resources(D)) - say("Not enough resources. Queue processing stopped.") - temp = {"Not enough resources to build next part.
- Try again | Return"} + if(verbose) + say("Not enough resources. Processing stopped.") return FALSE + build_materials = get_resources_w_coeff(D) + + materials.use_materials(build_materials) being_built = D - desc = "It's building \a [initial(D.name)]." - materials.use_amount(res_coef) - rmat.silo_log(src, "built", -1, "[D.name]", res_coef) + build_finish = world.time + get_construction_time_w_coeff(initial(D.construction_time)) + build_start = world.time + desc = "It's building \a [D.name]." - add_overlay("fab-active") - use_power = ACTIVE_POWER_USE - updateUsrDialog() - sleep(get_construction_time_w_coeff(D)) - use_power = IDLE_POWER_USE - cut_overlay("fab-active") - desc = initial(desc) + rmat.silo_log(src, "built", -1, "[D.name]", build_materials) - var/location = get_step(src,(dir)) - var/obj/item/I = new D.build_path(location) - I.materials = res_coef - say("\The [I] is complete.") - being_built = null - - updateUsrDialog() return TRUE -/obj/machinery/mecha_part_fabricator/proc/update_queue_on_page() - send_byjax(usr,"mecha_fabricator.browser","queue",list_queue()) - return +/obj/machinery/mecha_part_fabricator/process() + // If there's a stored part to dispense due to an obstruction, try to dispense it. + if(stored_part) + var/turf/exit = get_step(src,(dir)) + if(exit.density) + return TRUE -/obj/machinery/mecha_part_fabricator/proc/add_part_set_to_queue(set_name) - if(set_name in part_sets) - for(var/v in stored_research.researched_designs) - var/datum/design/D = SSresearch.techweb_design_by_id(v) - if(D.build_type & MECHFAB) - if(set_name in D.category) - add_to_queue(D) + say("Obstruction cleared. \The [stored_part] is complete.") + stored_part.forceMove(exit) + stored_part = null -/obj/machinery/mecha_part_fabricator/proc/add_to_queue(D) + // If there's nothing being built, try to build something + if(!being_built) + // If we're not processing the queue anymore or there's nothing to build, end processing. + if(!process_queue || !build_next_in_queue()) + on_finish_printing() + end_processing() + return TRUE + on_start_printing() + + // If there's an item being built, check if it is complete. + if(being_built && (build_finish < world.time)) + // Then attempt to dispense it and if appropriate build the next item. + dispense_built_part(being_built) + if(process_queue) + build_next_in_queue(FALSE) + return TRUE + +/** + * Dispenses a part to the tile infront of the Exosuit Fab. + * + * Returns FALSE is the machine cannot dispense the part on the appropriate turf. + * Return TRUE if the part was successfully dispensed. + * * D - Design datum to attempt to dispense. + */ +/obj/machinery/mecha_part_fabricator/proc/dispense_built_part(datum/design/D) + var/obj/item/I = new D.build_path(src) + //I.set_custom_materials(build_materials) + being_built = null + + var/turf/exit = get_step(src,(dir)) + if(exit.density) + say("Error! Part outlet is obstructed.") + desc = "It's trying to dispense \a [D.name], but the part outlet is obstructed." + stored_part = I + return FALSE + + say("\The [I] is complete.") + I.forceMove(exit) + return TRUE + +/** + * Adds a list of datum designs to the build queue. + * + * Will only add designs that are in this machine's stored techweb. + * Does final checks for datum IDs and makes sure this machine can build the designs. + * * part_list - List of datum design ids for designs to add to the queue. + */ +/obj/machinery/mecha_part_fabricator/proc/add_part_set_to_queue(list/part_list) + for(var/v in stored_research.researched_designs) + var/datum/design/D = SSresearch.techweb_design_by_id(v) + if((D.build_type & MECHFAB) && (D.id in part_list)) + add_to_queue(D) + +/** + * Adds a datum design to the build queue. + * + * Returns TRUE if successful and FALSE if the design was not added to the queue. + * * D - Datum design to add to the queue. + */ +/obj/machinery/mecha_part_fabricator/proc/add_to_queue(datum/design/D) if(!istype(queue)) queue = list() if(D) queue[++queue.len] = D - return queue.len + return TRUE + return FALSE +/** + * Removes datum design from the build queue based on index. + * + * Returns TRUE if successful and FALSE if a design was not removed from the queue. + * * index - Index in the build queue of the element to remove. + */ /obj/machinery/mecha_part_fabricator/proc/remove_from_queue(index) - if(!isnum(index) || !ISINTEGER(index) || !istype(queue) || (index<1 || index>queue.len)) + if(!isnum(index) || !ISINTEGER(index) || !istype(queue) || (index<1 || index>length(queue))) return FALSE queue.Cut(index,++index) return TRUE -/obj/machinery/mecha_part_fabricator/proc/process_queue() - var/datum/design/D = queue[1] - if(!D) - remove_from_queue(1) - if(queue.len) - return process_queue() - else - return - temp = null - while(D) - if(stat&(NOPOWER|BROKEN)) - return FALSE - if(build_part(D)) - remove_from_queue(1) - else - return FALSE - D = listgetindex(queue, 1) - say("Queue processing finished successfully.") - +/** + * Generates a list of parts formatted for tgui based on the current build queue. + * + * Returns a formatted list of lists containing formatted part information for every part in the build queue. + */ /obj/machinery/mecha_part_fabricator/proc/list_queue() - var/output = "Queue contains:" - if(!istype(queue) || !queue.len) - output += "
Nothing" - else - output += "
    " - var/i = 0 - for(var/datum/design/D in queue) - i++ - var/obj/part = D.build_path - output += "" - output += initial(part.name) + " - " - output += "[i>1?"":null] " - output += "[i↓":null] " - output += "Remove" + if(!istype(queue) || !length(queue)) + return null - output += "
" - output += "\[Process queue | Clear queue\]" - return output + var/list/queued_parts = list() + for(var/datum/design/D in queue) + var/list/part = output_part_info(D) + queued_parts += list(part) + return queued_parts -/obj/machinery/mecha_part_fabricator/proc/sync() - temp = "Updating local R&D database..." - updateUsrDialog() - sleep(30) //only sleep if called by user - - for(var/obj/machinery/computer/rdconsole/RDC in oview(7,src)) - RDC.stored_research.copy_research_to(stored_research) - temp = "Processed equipment designs.
" - //check if the tech coefficients have changed - temp += "Return" - - updateUsrDialog() - say("Successfully synchronized with R&D server.") - return - - temp = "Unable to connect to local R&D Database.
Please check your connections and try again.
Return" - updateUsrDialog() - return - -/obj/machinery/mecha_part_fabricator/proc/get_resource_cost_w_coeff(datum/design/D, resource, roundto = 1) +/** + * Calculates the coefficient-modified resource cost of a single material component of a design's recipe. + * + * Returns coefficient-modified resource cost for the given material component. + * * D - Design datum to pull the resource cost from. + * * resource - Material datum reference to the resource to calculate the cost of. + * * roundto - Rounding value for round() proc + */ +/obj/machinery/mecha_part_fabricator/proc/get_resource_cost_w_coeff(datum/design/D, datum/material/resource, roundto = 1) return round(D.materials[resource]*component_coeff, roundto) -/obj/machinery/mecha_part_fabricator/proc/get_construction_time_w_coeff(datum/design/D, roundto = 1) //aran - return round(initial(D.construction_time)*time_coeff, roundto) +/** + * Calculates the coefficient-modified build time of a design. + * + * Returns coefficient-modified build time of a given design. + * * D - Design datum to calculate the modified build time of. + * * roundto - Rounding value for round() proc + */ +/obj/machinery/mecha_part_fabricator/proc/get_construction_time_w_coeff(construction_time, roundto = 1) //aran + return round(construction_time*time_coeff, roundto) -/obj/machinery/mecha_part_fabricator/ui_interact(mob/user) - . = ..() - var/dat, left_part - user.set_machine(src) - var/turf/exit = get_step(src,(dir)) - if(exit.density) - say("Error! Part outlet is obstructed.") - return - if(temp) - left_part = temp - else if(being_built) - var/obj/I = being_built.build_path - left_part = {"Building [initial(I.name)].
- Please wait until completion...
"} +/obj/machinery/mecha_part_fabricator/ui_assets(mob/user) + return list( + get_asset_datum(/datum/asset/spritesheet/sheetmaterials) + ) + +/obj/machinery/mecha_part_fabricator/ui_interact(mob/user, datum/tgui/ui) + ui = SStgui.try_update_ui(user, src, ui) + if(!ui) + ui = new(user, src, "ExosuitFabricator") + ui.open() + +/obj/machinery/mecha_part_fabricator/ui_static_data(mob/user) + var/list/data = list() + + var/list/final_sets = list() + var/list/buildable_parts = list() + + for(var/part_set in part_sets) + final_sets += part_set + + for(var/v in stored_research.researched_designs) + var/datum/design/D = SSresearch.techweb_design_by_id(v) + if(D.build_type & MECHFAB) + // This is for us. + var/list/part = output_part_info(D, TRUE) + + if(part["category_override"]) + for(var/cat in part["category_override"]) + buildable_parts[cat] += list(part) + if(!(cat in part_sets)) + final_sets += cat + continue + + for(var/cat in part_sets) + // Find all matching categories. + if(!(cat in D.category)) + continue + + buildable_parts[cat] += list(part) + + data["partSets"] = final_sets + data["buildableParts"] = buildable_parts + + return data + +/obj/machinery/mecha_part_fabricator/ui_data(mob/user) + var/list/data = list() + + data["materials"] = output_available_resources() + + if(being_built) + var/list/part = list( + "name" = being_built.name, + "duration" = build_finish - world.time, + "printTime" = get_construction_time_w_coeff(initial(being_built.construction_time)) + ) + data["buildingPart"] = part else - switch(screen) - if("main") - left_part = output_available_resources()+"
" - left_part += "Sync with R&D servers
" - for(var/part_set in part_sets) - left_part += "[part_set] - \[Add all parts to queue\]
" - if("parts") - left_part += output_parts_list(part_set) - left_part += "
Return" - dat = {" - - - [name] - - - - - - - - - -
- [left_part] - - [list_queue()] -
- - "} - user << browse(dat, "window=mecha_fabricator;size=1000x430") - onclose(user, "mecha_fabricator") - return + data["buildingPart"] = null -/obj/machinery/mecha_part_fabricator/Topic(href, href_list) - if(..()) + data["queue"] = list_queue() + + if(stored_part) + data["storedPart"] = stored_part.name + else + data["storedPart"] = null + + data["isProcessingQueue"] = process_queue + + return data + +/obj/machinery/mecha_part_fabricator/ui_act(action, list/params) + . = ..() + if(.) return - if(href_list["part_set"]) - var/tpart_set = href_list["part_set"] - if(tpart_set) - if(tpart_set=="clear") - part_set = null - else - part_set = tpart_set - screen = "parts" - if(href_list["part"]) - var/T = href_list["part"] - for(var/v in stored_research.researched_designs) - var/datum/design/D = SSresearch.techweb_design_by_id(v) - if(D.build_type & MECHFAB) - if(D.id == T) - if(!processing_queue) - build_part(D) - else - add_to_queue(D) - break - if(href_list["add_to_queue"]) - var/T = href_list["add_to_queue"] - for(var/v in stored_research.researched_designs) - var/datum/design/D = SSresearch.techweb_design_by_id(v) - if(D.build_type & MECHFAB) - if(D.id == T) + + . = TRUE + + add_fingerprint(usr) + usr.set_machine(src) + + switch(action) + if("sync_rnd") + // Syncronises designs on interface with R&D techweb. + update_static_data(usr) + say("Successfully synchronized with R&D server.") + return + if("add_queue_set") + // Add all parts of a set to queue + var/part_list = params["part_list"] + add_part_set_to_queue(part_list) + return + if("add_queue_part") + // Add a specific part to queue + var/T = params["id"] + for(var/v in stored_research.researched_designs) + var/datum/design/D = SSresearch.techweb_design_by_id(v) + if((D.build_type & MECHFAB) && (D.id == T)) add_to_queue(D) break - return update_queue_on_page() - if(href_list["remove_from_queue"]) - remove_from_queue(text2num(href_list["remove_from_queue"])) - return update_queue_on_page() - if(href_list["partset_to_queue"]) - add_part_set_to_queue(href_list["partset_to_queue"]) - return update_queue_on_page() - if(href_list["process_queue"]) - spawn(0) - if(processing_queue || being_built) - return FALSE - processing_queue = 1 - process_queue() - processing_queue = 0 - if(href_list["clear_temp"]) - temp = null - if(href_list["screen"]) - screen = href_list["screen"] - if(href_list["queue_move"] && href_list["index"]) - var/index = text2num(href_list["index"]) - var/new_index = index + text2num(href_list["queue_move"]) - if(isnum(index) && isnum(new_index) && ISINTEGER(index) && ISINTEGER(new_index)) - if(ISINRANGE(new_index,1,queue.len)) - queue.Swap(index,new_index) - return update_queue_on_page() - if(href_list["clear_queue"]) - queue = list() - return update_queue_on_page() - if(href_list["sync"]) - sync() - if(href_list["part_desc"]) - var/T = href_list["part_desc"] - for(var/v in stored_research.researched_designs) - var/datum/design/D = SSresearch.techweb_design_by_id(v) - if(D.build_type & MECHFAB) - if(D.id == T) - var/obj/part = D.build_path - temp = {"

[initial(part.name)] description:

- [initial(part.desc)]
- Return - "} - break + return + if("del_queue_part") + // Delete a specific from from the queue + var/index = text2num(params["index"]) + remove_from_queue(index) + return + if("clear_queue") + // Delete everything from queue + queue.Cut() + return + if("build_queue") + // Build everything in queue + if(process_queue) + return + process_queue = TRUE - if(href_list["remove_mat"] && href_list["material"]) - eject_sheets(href_list["material"], href_list["remove_mat"]) + if(!being_built) + begin_processing() + return + if("stop_queue") + // Pause queue building. Also known as stop. + process_queue = FALSE + return + if("build_part") + // Build a single part + if(being_built || process_queue) + return - updateUsrDialog() - return + var/id = params["id"] + var/datum/design/D = SSresearch.techweb_design_by_id(id) + if(!(D.build_type & MECHFAB) || !(D.id == id)) + return + + if(build_part(D)) + on_start_printing() + begin_processing() + + return + if("move_queue_part") + // Moves a part up or down in the queue. + var/index = text2num(params["index"]) + var/new_index = index + text2num(params["newindex"]) + if(isnum(index) && isnum(new_index) && ISINTEGER(index) && ISINTEGER(new_index)) + if(ISINRANGE(new_index,1,length(queue))) + queue.Swap(index,new_index) + return + if("remove_mat") + // Remove a material from the fab + var/mat_ref = params["ref"] + var/amount = text2num(params["amount"]) + var/datum/material/mat = locate(mat_ref) + eject_sheets(mat, amount) + return + + return FALSE + +/** + * Eject material sheets. + * + * Returns the number of sheets successfully ejected. + * eject_sheet - Byond REF of the material to eject. + * eject_amt - Number of sheets to attempt to eject. + */ /obj/machinery/mecha_part_fabricator/proc/eject_sheets(eject_sheet, eject_amt) var/datum/component/material_container/mat_container = rmat.mat_container if (!mat_container) @@ -415,23 +614,26 @@ rmat.silo_log(src, "ejected", -count, "sheets", matlist) return count -/obj/machinery/mecha_part_fabricator/proc/AfterMaterialInsert(type_inserted, id_inserted, amount_inserted) - var/stack_name = material2name(id_inserted) - add_overlay("fab-load-[stack_name]") - addtimer(CALLBACK(src, /atom/proc/cut_overlay, "fab-load-[stack_name]"), 10) - updateUsrDialog() +/obj/machinery/mecha_part_fabricator/proc/AfterMaterialInsert(item_inserted, id_inserted, amount_inserted) + var/datum/material/M = id_inserted + add_overlay("fab-load-[M.name]") + addtimer(CALLBACK(src, /atom/proc/cut_overlay, "fab-load-[M.name]"), 10) -/obj/machinery/mecha_part_fabricator/attackby(obj/item/W, mob/user, params) - if(default_deconstruction_screwdriver(user, "fab-o", "fab-idle", W)) +/obj/machinery/mecha_part_fabricator/screwdriver_act(mob/living/user, obj/item/I) + if(..()) return TRUE + if(being_built) + to_chat(user, "\The [src] is currently processing! Please wait until completion.") + return FALSE + return default_deconstruction_screwdriver(user, "fab-o", "fab-idle", I) - if(default_deconstruction_crowbar(W)) +/obj/machinery/mecha_part_fabricator/crowbar_act(mob/living/user, obj/item/I) + if(..()) return TRUE - - return ..() - -/obj/machinery/mecha_part_fabricator/proc/material2name(ID) - return copytext(ID,2) + if(being_built) + to_chat(user, "\The [src] is currently processing! Please wait until completion.") + return FALSE + return default_deconstruction_crowbar(I) /obj/machinery/mecha_part_fabricator/proc/is_insertion_ready(mob/user) if(panel_open) @@ -440,5 +642,7 @@ if(being_built) to_chat(user, "\The [src] is currently processing! Please wait until completion.") return FALSE + return TRUE - return TRUE \ No newline at end of file +/obj/machinery/mecha_part_fabricator/maint + link_on_init = FALSE \ No newline at end of file diff --git a/code/game/objects/items.dm b/code/game/objects/items.dm index 626cda77c214..0a871299e446 100644 --- a/code/game/objects/items.dm +++ b/code/game/objects/items.dm @@ -66,7 +66,7 @@ GLOBAL_VAR_INIT(rpg_loot_items, FALSE) var/equip_delay_other = 20 //In deciseconds, how long an item takes to put on another person var/strip_delay = 40 //In deciseconds, how long an item takes to remove from another person var/breakouttime = 0 - var/list/materials + var/list/materials //materials in this object, and the amount var/list/attack_verb //Used in attackby() to say how something was attacked "[x] has been [z.attack_verb] by [y] with [z]" var/list/species_exception = null // list() of species types, if a species cannot put items in a certain slot, but species type is in list, it will be able to wear that item @@ -110,6 +110,14 @@ GLOBAL_VAR_INIT(rpg_loot_items, FALSE) materials = typelist("materials", materials) + if(materials) //Otherwise, use the instances already provided. + var/list/temp_list = list() + for(var/i in materials) //Go through all of our materials, get the subsystem instance, and then replace the list. + var/amount = materials[i] + var/datum/material/M = getmaterialref(i) + temp_list[M] = amount + materials = temp_list + if (attack_verb) attack_verb = typelist("attack_verb", attack_verb) diff --git a/code/game/objects/items/AI_modules.dm b/code/game/objects/items/AI_modules.dm index 8efb0d4e2247..0d84b9118dc2 100644 --- a/code/game/objects/items/AI_modules.dm +++ b/code/game/objects/items/AI_modules.dm @@ -22,7 +22,7 @@ AI MODULES throw_range = 7 var/list/laws = list() var/bypass_law_amt_check = 0 - materials = list(MAT_GOLD=50) + materials = list(/datum/material/gold=50) /obj/item/aiModule/examine(var/mob/user as mob) . = ..() diff --git a/code/game/objects/items/RCD.dm b/code/game/objects/items/RCD.dm index 399f11bb186c..1ab3c533cefa 100644 --- a/code/game/objects/items/RCD.dm +++ b/code/game/objects/items/RCD.dm @@ -23,7 +23,7 @@ RLD throw_range = 5 w_class = WEIGHT_CLASS_NORMAL slot_flags = ITEM_SLOT_BELT - materials = list(MAT_METAL=100000) + materials = list(/datum/material/iron=100000) req_access_txt = "11" armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 100, "acid" = 50) resistance_flags = FIRE_PROOF @@ -599,11 +599,11 @@ RLD w_class = WEIGHT_CLASS_TINY lefthand_file = 'icons/mob/inhands/equipment/tools_lefthand.dmi' righthand_file = 'icons/mob/inhands/equipment/tools_righthand.dmi' - materials = list(MAT_METAL=12000, MAT_GLASS=8000) + materials = list(/datum/material/iron=12000, /datum/material/glass=8000) var/ammoamt = 40 /obj/item/rcd_ammo/large - materials = list(MAT_METAL=48000, MAT_GLASS=32000) + materials = list(/datum/material/iron=48000, /datum/material/glass=32000) ammoamt = 160 diff --git a/code/game/objects/items/RPD.dm b/code/game/objects/items/RPD.dm index 4697a908b544..973918d50086 100644 --- a/code/game/objects/items/RPD.dm +++ b/code/game/objects/items/RPD.dm @@ -206,7 +206,7 @@ GLOBAL_LIST_INIT(fluid_duct_recipes, list( throw_range = 5 w_class = WEIGHT_CLASS_NORMAL slot_flags = ITEM_SLOT_BELT - materials = list(MAT_METAL=75000, MAT_GLASS=37500) + materials = list(/datum/material/iron=75000, /datum/material/glass=37500) armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 100, "acid" = 50) resistance_flags = FIRE_PROOF var/datum/effect_system/spark_spread/spark_system diff --git a/code/game/objects/items/airlock_painter.dm b/code/game/objects/items/airlock_painter.dm index 0170a9d4843a..5495151ba95d 100644 --- a/code/game/objects/items/airlock_painter.dm +++ b/code/game/objects/items/airlock_painter.dm @@ -7,7 +7,7 @@ w_class = WEIGHT_CLASS_SMALL - materials = list(MAT_METAL=50, MAT_GLASS=50) + materials = list(/datum/material/iron=50, /datum/material/glass=50) flags_1 = CONDUCT_1 item_flags = NOBLUDGEON diff --git a/code/game/objects/items/apc_frame.dm b/code/game/objects/items/apc_frame.dm index 6bf90b421919..d8279832bb44 100644 --- a/code/game/objects/items/apc_frame.dm +++ b/code/game/objects/items/apc_frame.dm @@ -1,6 +1,6 @@ /obj/item/wallframe icon = 'icons/obj/wallframe.dmi' - materials = list(MAT_METAL=MINERAL_MATERIAL_AMOUNT*2) + materials = list(/datum/material/iron=MINERAL_MATERIAL_AMOUNT*2) flags_1 = CONDUCT_1 item_state = "syringe_kit" lefthand_file = 'icons/mob/inhands/equipment/medical_lefthand.dmi' @@ -66,8 +66,8 @@ if(iswallturf(T)) T.attackby(src, user, params) - var/metal_amt = round(materials[MAT_METAL]/MINERAL_MATERIAL_AMOUNT) - var/glass_amt = round(materials[MAT_GLASS]/MINERAL_MATERIAL_AMOUNT) + var/metal_amt = round(materials[/datum/material/iron]/MINERAL_MATERIAL_AMOUNT) + var/glass_amt = round(materials[/datum/material/glass]/MINERAL_MATERIAL_AMOUNT) if(W.tool_behaviour == TOOL_WRENCH && (metal_amt || glass_amt)) to_chat(user, "You dismantle [src].") @@ -119,5 +119,5 @@ righthand_file = 'icons/mob/inhands/misc/devices_righthand.dmi' flags_1 = CONDUCT_1 w_class = WEIGHT_CLASS_SMALL - materials = list(MAT_METAL=50, MAT_GLASS=50) + materials = list(/datum/material/iron=50, /datum/material/glass=50) grind_results = list(/datum/reagent/iron = 10, /datum/reagent/silicon = 10) diff --git a/code/game/objects/items/circuitboards/circuitboard.dm b/code/game/objects/items/circuitboards/circuitboard.dm index 5f87f9ffd931..8c1b92172b82 100644 --- a/code/game/objects/items/circuitboards/circuitboard.dm +++ b/code/game/objects/items/circuitboards/circuitboard.dm @@ -10,7 +10,7 @@ item_state = "electronic" lefthand_file = 'icons/mob/inhands/misc/devices_lefthand.dmi' righthand_file = 'icons/mob/inhands/misc/devices_righthand.dmi' - materials = list(MAT_GLASS=1000) + materials = list(/datum/material/glass=1000) w_class = WEIGHT_CLASS_SMALL grind_results = list(/datum/reagent/silicon = 20) var/build_path = null diff --git a/code/game/objects/items/devices/desynchronizer.dm b/code/game/objects/items/devices/desynchronizer.dm index e846cc9d2d22..6788b0158b6f 100644 --- a/code/game/objects/items/devices/desynchronizer.dm +++ b/code/game/objects/items/devices/desynchronizer.dm @@ -8,7 +8,7 @@ item_flags = NOBLUDGEON lefthand_file = 'icons/mob/inhands/misc/devices_lefthand.dmi' righthand_file = 'icons/mob/inhands/misc/devices_righthand.dmi' - materials = list(MAT_METAL=250, MAT_GLASS=500) + materials = list(/datum/material/iron=250, /datum/material/glass=500) var/max_duration = 3000 var/duration = 300 var/last_use = 0 diff --git a/code/game/objects/items/devices/doorCharge.dm b/code/game/objects/items/devices/doorCharge.dm index e9ba9ea4a40b..6a06508046d0 100644 --- a/code/game/objects/items/devices/doorCharge.dm +++ b/code/game/objects/items/devices/doorCharge.dm @@ -12,7 +12,7 @@ item_flags = NOBLUDGEON force = 3 attack_verb = list("blown up", "exploded", "detonated") - materials = list(MAT_METAL=50, MAT_GLASS=30) + materials = list(/datum/material/iron=50, /datum/material/glass=30) /obj/item/doorCharge/ex_act(severity, target) switch(severity) diff --git a/code/game/objects/items/devices/electroadaptive_pseudocircuit.dm b/code/game/objects/items/devices/electroadaptive_pseudocircuit.dm index a1da04c1eb52..e87ea386c278 100644 --- a/code/game/objects/items/devices/electroadaptive_pseudocircuit.dm +++ b/code/game/objects/items/devices/electroadaptive_pseudocircuit.dm @@ -5,7 +5,7 @@ icon = 'icons/obj/module.dmi' icon_state = "boris" w_class = WEIGHT_CLASS_TINY - materials = list(MAT_METAL = 50, MAT_GLASS = 300) + materials = list(/datum/material/iron = 50, /datum/material/glass = 300) var/recharging = FALSE var/circuits = 5 //How many circuits the pseudocircuit has left var/static/recycleable_circuits = typecacheof(list(/obj/item/electronics/firelock, /obj/item/electronics/airalarm, /obj/item/electronics/firealarm, \ diff --git a/code/game/objects/items/devices/flashlight.dm b/code/game/objects/items/devices/flashlight.dm index 86ffdd732a19..9173c066060b 100644 --- a/code/game/objects/items/devices/flashlight.dm +++ b/code/game/objects/items/devices/flashlight.dm @@ -10,7 +10,7 @@ w_class = WEIGHT_CLASS_SMALL flags_1 = CONDUCT_1 slot_flags = ITEM_SLOT_BELT - materials = list(MAT_METAL=50, MAT_GLASS=20) + materials = list(/datum/material/iron=50, /datum/material/glass=20) actions_types = list(/datum/action/item_action/toggle_light) var/on = FALSE var/brightness_on = 4 //range of light when on diff --git a/code/game/objects/items/devices/forcefieldprojector.dm b/code/game/objects/items/devices/forcefieldprojector.dm index 290d33b7e5c1..3be4b93f8e67 100644 --- a/code/game/objects/items/devices/forcefieldprojector.dm +++ b/code/game/objects/items/devices/forcefieldprojector.dm @@ -9,7 +9,7 @@ item_state = "electronic" lefthand_file = 'icons/mob/inhands/misc/devices_lefthand.dmi' righthand_file = 'icons/mob/inhands/misc/devices_righthand.dmi' - materials = list(MAT_METAL=250, MAT_GLASS=500) + materials = list(/datum/material/iron=250, /datum/material/glass=500) var/max_shield_integrity = 250 var/shield_integrity = 250 var/max_fields = 3 diff --git a/code/game/objects/items/devices/geiger_counter.dm b/code/game/objects/items/devices/geiger_counter.dm index f3a892f3a379..fb5db099a58e 100644 --- a/code/game/objects/items/devices/geiger_counter.dm +++ b/code/game/objects/items/devices/geiger_counter.dm @@ -18,7 +18,7 @@ righthand_file = 'icons/mob/inhands/equipment/tools_righthand.dmi' w_class = WEIGHT_CLASS_SMALL slot_flags = ITEM_SLOT_BELT - materials = list(MAT_METAL = 150, MAT_GLASS = 150) + materials = list(/datum/material/iron = 150, /datum/material/glass = 150) var/grace = RAD_GRACE_PERIOD var/datum/looping_sound/geiger/soundloop diff --git a/code/game/objects/items/devices/laserpointer.dm b/code/game/objects/items/devices/laserpointer.dm index e437d21e2e63..284a569df110 100644 --- a/code/game/objects/items/devices/laserpointer.dm +++ b/code/game/objects/items/devices/laserpointer.dm @@ -8,7 +8,7 @@ flags_1 = CONDUCT_1 item_flags = NOBLUDGEON slot_flags = ITEM_SLOT_BELT - materials = list(MAT_METAL=500, MAT_GLASS=500) + materials = list(/datum/material/iron=500, /datum/material/glass=500) w_class = WEIGHT_CLASS_SMALL var/turf/pointer_loc var/energy = 5 diff --git a/code/game/objects/items/devices/multitool.dm b/code/game/objects/items/devices/multitool.dm index 81d9756a0520..d9d779cd67a7 100644 --- a/code/game/objects/items/devices/multitool.dm +++ b/code/game/objects/items/devices/multitool.dm @@ -24,7 +24,7 @@ throwforce = 0 throw_range = 7 throw_speed = 3 - materials = list(MAT_METAL=50, MAT_GLASS=20) + materials = list(/datum/material/iron=50, /datum/material/glass=20) var/obj/machinery/buffer // simple machine buffer for device linkage toolspeed = 1 usesound = 'sound/weapons/empty.ogg' diff --git a/code/game/objects/items/devices/pipe_painter.dm b/code/game/objects/items/devices/pipe_painter.dm index e8e15b41b822..2317e529abc6 100644 --- a/code/game/objects/items/devices/pipe_painter.dm +++ b/code/game/objects/items/devices/pipe_painter.dm @@ -6,7 +6,7 @@ item_flags = NOBLUDGEON var/paint_color = "grey" - materials = list(MAT_METAL=5000, MAT_GLASS=2000) + materials = list(/datum/material/iron=5000, /datum/material/glass=2000) /obj/item/pipe_painter/afterattack(atom/A, mob/user, proximity_flag) . = ..() diff --git a/code/game/objects/items/devices/powersink.dm b/code/game/objects/items/devices/powersink.dm index b413a5b99f56..177ac21971cf 100644 --- a/code/game/objects/items/devices/powersink.dm +++ b/code/game/objects/items/devices/powersink.dm @@ -13,7 +13,7 @@ throwforce = 5 throw_speed = 1 throw_range = 2 - materials = list(MAT_METAL=750) + materials = list(/datum/material/iron=750) var/drain_rate = 2000000 // amount of power to drain per tick var/power_drained = 0 // has drained this much power var/max_power = 6e8 // maximum power that can be drained before exploding diff --git a/code/game/objects/items/devices/radio/electropack.dm b/code/game/objects/items/devices/radio/electropack.dm index 0d61457fb481..ff7113715174 100644 --- a/code/game/objects/items/devices/radio/electropack.dm +++ b/code/game/objects/items/devices/radio/electropack.dm @@ -9,7 +9,7 @@ flags_1 = CONDUCT_1 slot_flags = ITEM_SLOT_BACK w_class = WEIGHT_CLASS_HUGE - materials = list(MAT_METAL=10000, MAT_GLASS=2500) + materials = list(/datum/material/iron=10000, /datum/material/glass=2500) var/on = TRUE var/code = 2 var/frequency = FREQ_ELECTROPACK diff --git a/code/game/objects/items/devices/radio/headset.dm b/code/game/objects/items/devices/radio/headset.dm index 1b5ac8c25774..92a4548a8d0e 100644 --- a/code/game/objects/items/devices/radio/headset.dm +++ b/code/game/objects/items/devices/radio/headset.dm @@ -19,7 +19,7 @@ GLOBAL_LIST_INIT(channel_tokens, list( desc = "An updated, modular intercom that fits over the head. Takes encryption keys." icon_state = "headset" item_state = "headset" - materials = list(MAT_METAL=75) + materials = list(/datum/material/iron=75) subspace_transmission = TRUE canhear_range = 0 // can't hear headsets from very far away @@ -73,7 +73,7 @@ GLOBAL_LIST_INIT(channel_tokens, list( else if(AIuser) return ..(freq, level) return FALSE - + /obj/item/radio/headset/ui_data(mob/user) . = ..() .["headset"] = TRUE diff --git a/code/game/objects/items/devices/radio/intercom.dm b/code/game/objects/items/devices/radio/intercom.dm index 8596783df9b0..40c7b9051fcd 100644 --- a/code/game/objects/items/devices/radio/intercom.dm +++ b/code/game/objects/items/devices/radio/intercom.dm @@ -151,4 +151,4 @@ result_path = /obj/item/radio/intercom/unscrewed pixel_shift = 29 inverse = TRUE - materials = list(MAT_METAL = 75, MAT_GLASS = 25) + materials = list(/datum/material/iron = 75, /datum/material/glass = 25) diff --git a/code/game/objects/items/devices/radio/radio.dm b/code/game/objects/items/devices/radio/radio.dm index 12a0a6288242..3f0860e91df4 100644 --- a/code/game/objects/items/devices/radio/radio.dm +++ b/code/game/objects/items/devices/radio/radio.dm @@ -11,7 +11,7 @@ throw_speed = 3 throw_range = 7 w_class = WEIGHT_CLASS_SMALL - materials = list(MAT_METAL=75, MAT_GLASS=25) + materials = list(/datum/material/iron=75, /datum/material/glass=25) obj_flags = USES_TGUI var/on = TRUE diff --git a/code/game/objects/items/devices/scanners.dm b/code/game/objects/items/devices/scanners.dm index 1c6a640d8bf1..ea90fa08734d 100644 --- a/code/game/objects/items/devices/scanners.dm +++ b/code/game/objects/items/devices/scanners.dm @@ -22,7 +22,7 @@ GENE SCANNER item_state = "electronic" lefthand_file = 'icons/mob/inhands/misc/devices_lefthand.dmi' righthand_file = 'icons/mob/inhands/misc/devices_righthand.dmi' - materials = list(MAT_METAL=150) + materials = list(/datum/material/iron=150) /obj/item/t_scanner/suicide_act(mob/living/carbon/user) user.visible_message("[user] begins to emit terahertz-rays into [user.p_their()] brain with [src]! It looks like [user.p_theyre()] trying to commit suicide!") @@ -86,7 +86,7 @@ GENE SCANNER w_class = WEIGHT_CLASS_TINY throw_speed = 3 throw_range = 7 - materials = list(MAT_METAL=200) + materials = list(/datum/material/iron=200) var/mode = 1 var/scanmode = 0 var/advanced = FALSE @@ -442,7 +442,7 @@ GENE SCANNER throw_speed = 3 throw_range = 7 tool_behaviour = TOOL_ANALYZER - materials = list(MAT_METAL=30, MAT_GLASS=20) + materials = list(/datum/material/iron=30, /datum/material/glass=20) grind_results = list(/datum/reagent/mercury = 5, /datum/reagent/iron = 5, /datum/reagent/silicon = 5) var/cooldown = FALSE var/cooldown_time = 250 @@ -630,7 +630,7 @@ GENE SCANNER throwforce = 0 throw_speed = 3 throw_range = 7 - materials = list(MAT_METAL=30, MAT_GLASS=20) + materials = list(/datum/material/iron=30, /datum/material/glass=20) /obj/item/slime_scanner/attack(mob/living/M, mob/living/user) if(user.stat || user.eye_blind) @@ -689,7 +689,7 @@ GENE SCANNER w_class = WEIGHT_CLASS_TINY throw_speed = 3 throw_range = 7 - materials = list(MAT_METAL=200) + materials = list(/datum/material/iron=200) /obj/item/nanite_scanner/attack(mob/living/M, mob/living/carbon/human/user) user.visible_message("[user] has analyzed [M]'s nanites.") @@ -715,7 +715,7 @@ GENE SCANNER w_class = WEIGHT_CLASS_TINY throw_speed = 3 throw_range = 7 - materials = list(MAT_METAL=200) + materials = list(/datum/material/iron=200) var/list/discovered = list() //hit a dna console to update the scanners database var/list/buffer var/ready = TRUE diff --git a/code/game/objects/items/devices/taperecorder.dm b/code/game/objects/items/devices/taperecorder.dm index c13d9c33208c..85f26c1d1dcc 100644 --- a/code/game/objects/items/devices/taperecorder.dm +++ b/code/game/objects/items/devices/taperecorder.dm @@ -9,7 +9,7 @@ w_class = WEIGHT_CLASS_SMALL flags_1 = HEAR_1 slot_flags = ITEM_SLOT_BELT - materials = list(MAT_METAL=60, MAT_GLASS=30) + materials = list(/datum/material/iron=60, /datum/material/glass=30) force = 2 throwforce = 0 var/recording = 0 @@ -220,7 +220,7 @@ if(mytape.ruined) to_chat(user, "The tape inside the [src] appears to be broken.") return - + update_available_icons() if(icons_available) var/selection = show_radial_menu(user, src, icons_available, radius = 38, require_near = TRUE, tooltips = TRUE) @@ -283,7 +283,7 @@ lefthand_file = 'icons/mob/inhands/equipment/tools_lefthand.dmi' righthand_file = 'icons/mob/inhands/equipment/tools_righthand.dmi' w_class = WEIGHT_CLASS_TINY - materials = list(MAT_METAL=20, MAT_GLASS=5) + materials = list(/datum/material/iron=20, /datum/material/glass=5) force = 1 throwforce = 0 var/max_capacity = 600 diff --git a/code/game/objects/items/devices/traitordevices.dm b/code/game/objects/items/devices/traitordevices.dm index 1c367bc3e76f..b12ae1feb9e2 100644 --- a/code/game/objects/items/devices/traitordevices.dm +++ b/code/game/objects/items/devices/traitordevices.dm @@ -69,7 +69,7 @@ effective or pretty fucking useless. */ /obj/item/healthanalyzer/rad_laser - materials = list(MAT_METAL=400) + materials = list(/datum/material/iron=400) var/irradiate = TRUE var/stealth = FALSE var/used = FALSE // is it cooling down? diff --git a/code/game/objects/items/extinguisher.dm b/code/game/objects/items/extinguisher.dm index 5ba2fa5c5581..d14124de5960 100644 --- a/code/game/objects/items/extinguisher.dm +++ b/code/game/objects/items/extinguisher.dm @@ -11,7 +11,7 @@ throw_speed = 2 throw_range = 7 force = 10 - materials = list(MAT_METAL = 90) + materials = list(/datum/material/iron = 90) attack_verb = list("slammed", "whacked", "bashed", "thunked", "battered", "bludgeoned", "thrashed") dog_fashion = /datum/dog_fashion/back resistance_flags = FIRE_PROOF @@ -36,7 +36,7 @@ throwforce = 2 w_class = WEIGHT_CLASS_SMALL force = 3 - materials = list(MAT_METAL = 50, MAT_GLASS = 40) + materials = list(/datum/material/iron = 50, /datum/material/glass = 40) max_water = 30 sprite_name = "miniFE" dog_fashion = null diff --git a/code/game/objects/items/flamethrower.dm b/code/game/objects/items/flamethrower.dm index ffb870c5c1de..2e55c4538c25 100644 --- a/code/game/objects/items/flamethrower.dm +++ b/code/game/objects/items/flamethrower.dm @@ -12,7 +12,7 @@ throw_speed = 1 throw_range = 5 w_class = WEIGHT_CLASS_NORMAL - materials = list(MAT_METAL=500) + materials = list(/datum/material/iron=500) resistance_flags = FIRE_PROOF var/status = FALSE var/lit = FALSE //on or off diff --git a/code/game/objects/items/handcuffs.dm b/code/game/objects/items/handcuffs.dm index 5b01ae153fc3..3fb6de7762aa 100644 --- a/code/game/objects/items/handcuffs.dm +++ b/code/game/objects/items/handcuffs.dm @@ -34,7 +34,7 @@ w_class = WEIGHT_CLASS_SMALL throw_speed = 3 throw_range = 5 - materials = list(MAT_METAL=500) + materials = list(/datum/material/iron=500) breakouttime = 600 //Deciseconds = 60s = 1 minute armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 50, "acid" = 50) var/cuffsound = 'sound/weapons/handcuffs.ogg' @@ -116,7 +116,7 @@ color = "#ff0000" lefthand_file = 'icons/mob/inhands/equipment/tools_lefthand.dmi' righthand_file = 'icons/mob/inhands/equipment/tools_righthand.dmi' - materials = list(MAT_METAL=150, MAT_GLASS=75) + materials = list(/datum/material/iron=150, /datum/material/glass=75) breakouttime = 300 //Deciseconds = 30s cuffsound = 'sound/weapons/cablecuff.ogg' diff --git a/code/game/objects/items/implants/implantcase.dm b/code/game/objects/items/implants/implantcase.dm index 4b8427386c8c..4d4802e01866 100644 --- a/code/game/objects/items/implants/implantcase.dm +++ b/code/game/objects/items/implants/implantcase.dm @@ -9,7 +9,7 @@ throw_speed = 2 throw_range = 5 w_class = WEIGHT_CLASS_TINY - materials = list(MAT_GLASS=500) + materials = list(/datum/material/glass=500) var/obj/item/implant/imp = null var/imp_type diff --git a/code/game/objects/items/implants/implanter.dm b/code/game/objects/items/implants/implanter.dm index b774763defd0..7f3b06d79ea9 100644 --- a/code/game/objects/items/implants/implanter.dm +++ b/code/game/objects/items/implants/implanter.dm @@ -9,7 +9,7 @@ throw_speed = 3 throw_range = 5 w_class = WEIGHT_CLASS_SMALL - materials = list(MAT_METAL=600, MAT_GLASS=200) + materials = list(/datum/material/iron=600, /datum/material/glass=200) var/obj/item/implant/imp = null var/imp_type = null diff --git a/code/game/objects/items/kitchen.dm b/code/game/objects/items/kitchen.dm index 53724c27767d..c7a35e84ef70 100644 --- a/code/game/objects/items/kitchen.dm +++ b/code/game/objects/items/kitchen.dm @@ -23,7 +23,7 @@ throwforce = 0 throw_speed = 3 throw_range = 5 - materials = list(MAT_METAL=80) + materials = list(/datum/material/iron=80) flags_1 = CONDUCT_1 attack_verb = list("attacked", "stabbed", "poked") hitsound = 'sound/weapons/bladeslice.ogg' @@ -73,7 +73,7 @@ hitsound = 'sound/weapons/bladeslice.ogg' throw_speed = 3 throw_range = 6 - materials = list(MAT_METAL=12000) + materials = list(/datum/material/iron=12000) attack_verb = list("slashed", "stabbed", "sliced", "torn", "ripped", "diced", "cut") sharpness = IS_SHARP_ACCURATE armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 50, "acid" = 50) @@ -131,7 +131,7 @@ flags_1 = CONDUCT_1 force = 15 throwforce = 10 - materials = list(MAT_METAL=18000) + materials = list(/datum/material/iron=18000) attack_verb = list("cleaved", "slashed", "stabbed", "sliced", "torn", "ripped", "diced", "cut") w_class = WEIGHT_CLASS_NORMAL custom_price = 60 diff --git a/code/game/objects/items/melee/misc.dm b/code/game/objects/items/melee/misc.dm index babee4bb44f0..c3034a29c58b 100644 --- a/code/game/objects/items/melee/misc.dm +++ b/code/game/objects/items/melee/misc.dm @@ -15,7 +15,7 @@ w_class = WEIGHT_CLASS_NORMAL attack_verb = list("flogged", "whipped", "lashed", "disciplined") hitsound = 'sound/weapons/chainhit.ogg' - materials = list(MAT_METAL = 1000) + materials = list(/datum/material/iron = 1000) /obj/item/melee/chainofcommand/suicide_act(mob/user) user.visible_message("[user] is strangling [user.p_them()]self with [src]! It looks like [user.p_theyre()] trying to commit suicide!") @@ -57,7 +57,7 @@ sharpness = IS_SHARP attack_verb = list("slashed", "cut") hitsound = 'sound/weapons/rapierhit.ogg' - materials = list(MAT_METAL = 1000) + materials = list(/datum/material/iron = 1000) /obj/item/melee/cutlass name = "cutlass" @@ -71,7 +71,7 @@ w_class = WEIGHT_CLASS_BULKY attack_verb = list("slashed", "cut") hitsound = 'sound/weapons/rapierhit.ogg' - materials = list(MAT_METAL = 1000) + materials = list(/datum/material/iron = 1000) /obj/item/melee/sabre/Initialize() . = ..() diff --git a/code/game/objects/items/pet_carrier.dm b/code/game/objects/items/pet_carrier.dm index ae74d75d9e06..f36e08813d88 100644 --- a/code/game/objects/items/pet_carrier.dm +++ b/code/game/objects/items/pet_carrier.dm @@ -15,7 +15,7 @@ w_class = WEIGHT_CLASS_BULKY throw_speed = 2 throw_range = 3 - materials = list(MAT_METAL = 7500, MAT_GLASS = 100) + materials = list(/datum/material/iron = 7500, /datum/material/glass = 100) var/open = TRUE var/locked = FALSE var/list/occupants = list() diff --git a/code/game/objects/items/pinpointer.dm b/code/game/objects/items/pinpointer.dm index 7237cb6d0599..9d5308f849e2 100644 --- a/code/game/objects/items/pinpointer.dm +++ b/code/game/objects/items/pinpointer.dm @@ -12,7 +12,7 @@ righthand_file = 'icons/mob/inhands/misc/devices_righthand.dmi' throw_speed = 3 throw_range = 7 - materials = list(MAT_METAL = 500, MAT_GLASS = 250) + materials = list(/datum/material/iron = 500, /datum/material/glass = 250) resistance_flags = INDESTRUCTIBLE | LAVA_PROOF | FIRE_PROOF | ACID_PROOF var/active = FALSE var/atom/movable/target //The thing we're searching for diff --git a/code/game/objects/items/robot/robot_upgrades.dm b/code/game/objects/items/robot/robot_upgrades.dm index 209f1a30420e..2599e02e605e 100644 --- a/code/game/objects/items/robot/robot_upgrades.dm +++ b/code/game/objects/items/robot/robot_upgrades.dm @@ -13,6 +13,8 @@ // if true, is not stored in the robot to be ejected // if module is reset var/one_use = FALSE + /// Bitflags listing module compatibility. Used in the exosuit fabricator for creating sub-categories. + var/list/module_flags = NONE /obj/item/borg/upgrade/proc/action(mob/living/silicon/robot/R, user = usr) if(R.stat == DEAD) @@ -95,6 +97,7 @@ icon_state = "cyborg_upgrade3" require_module = 1 module_type = /obj/item/robot_module/security + module_flags = BORG_MODULE_SECURITY /obj/item/borg/upgrade/disablercooler/action(mob/living/silicon/robot/R, user = usr) . = ..() @@ -143,6 +146,7 @@ icon_state = "cyborg_upgrade3" require_module = 1 module_type = /obj/item/robot_module/miner + module_flags = BORG_MODULE_MINER /obj/item/borg/upgrade/ddrill/action(mob/living/silicon/robot/R, user = usr) . = ..() @@ -175,6 +179,7 @@ icon_state = "cyborg_upgrade3" require_module = 1 module_type = /obj/item/robot_module/miner + module_flags = BORG_MODULE_MINER /obj/item/borg/upgrade/soh/action(mob/living/silicon/robot/R , user = usr) //yogs single line . = ..() @@ -207,6 +212,7 @@ icon_state = "cyborg_upgrade3" require_module = 1 module_type = /obj/item/robot_module/janitor + module_flags = BORG_MODULE_JANITOR /obj/item/borg/upgrade/tboh/action(mob/living/silicon/robot/R, user = usr)//yogs single line . = ..() @@ -239,6 +245,7 @@ icon_state = "cyborg_upgrade3" require_module = 1 module_type = /obj/item/robot_module/janitor + module_flags = BORG_MODULE_JANITOR /obj/item/borg/upgrade/amop/action(mob/living/silicon/robot/R, user = usr)//yogs single line . = ..() @@ -293,6 +300,7 @@ resistance_flags = LAVA_PROOF | FIRE_PROOF require_module = 1 module_type = /obj/item/robot_module/miner + module_flags = BORG_MODULE_MINER /obj/item/borg/upgrade/lavaproof/action(mob/living/silicon/robot/R, user = usr) . = ..() @@ -424,6 +432,7 @@ require_module = 1 module_type = /obj/item/robot_module/medical var/list/additional_reagents = list() + module_flags = BORG_MODULE_MEDICAL /obj/item/borg/upgrade/hypospray/action(mob/living/silicon/robot/R, user = usr) . = ..() @@ -483,6 +492,7 @@ icon_state = "cyborg_upgrade3" require_module = 1 module_type = /obj/item/robot_module/medical + module_flags = BORG_MODULE_MEDICAL /obj/item/borg/upgrade/defib/action(mob/living/silicon/robot/R, user = usr) . = ..() @@ -510,6 +520,7 @@ icon_state = "cyborg_upgrade3" require_module = 1 module_type = /obj/item/robot_module/medical + module_flags = BORG_MODULE_MEDICAL /obj/item/borg/upgrade/processor/action(mob/living/silicon/robot/R, user = usr) . = ..() @@ -600,6 +611,7 @@ icon_state = "borgrped" require_module = TRUE module_type = /obj/item/robot_module/engineering + module_flags = BORG_MODULE_ENGINEERING /obj/item/borg/upgrade/rped/action(mob/living/silicon/robot/R, user = usr) . = ..() @@ -627,6 +639,7 @@ icon_state = "adv_plasmacutter" require_module = TRUE module_type = /obj/item/robot_module/miner + module_flags = BORG_MODULE_MINER /obj/item/borg/upgrade/plasmacutter/action(mob/living/silicon/robot/R, user = usr) . = ..() @@ -654,6 +667,7 @@ icon_state = "pinpointer_crew" require_module = TRUE module_type = /obj/item/robot_module/medical + module_flags = BORG_MODULE_MEDICAL /obj/item/borg/upgrade/pinpointer/action(mob/living/silicon/robot/R, user = usr) . = ..() @@ -701,4 +715,4 @@ if(CONFIG_GET(flag/disable_secborg)) to_chat(user, "Nanotrasen policy disallows the use of weapons of mass destruction.") return FALSE - return ..() + return ..() \ No newline at end of file diff --git a/code/game/objects/items/shields.dm b/code/game/objects/items/shields.dm index 54cb53a3d4c7..b95e8ba5c556 100644 --- a/code/game/objects/items/shields.dm +++ b/code/game/objects/items/shields.dm @@ -20,7 +20,7 @@ throw_speed = 2 throw_range = 3 w_class = WEIGHT_CLASS_BULKY - materials = list(MAT_GLASS=7500, MAT_METAL=1000) + materials = list(/datum/material/glass=7500, /datum/material/iron=1000) attack_verb = list("shoved", "bashed") var/cooldown = 0 //shield bash cooldown. based on world.time transparent = TRUE @@ -87,7 +87,7 @@ lefthand_file = 'icons/mob/inhands/equipment/shields_lefthand.dmi' righthand_file = 'icons/mob/inhands/equipment/shields_righthand.dmi' transparent = FALSE - materials = list(MAT_METAL=8500) + materials = list(/datum/material/iron=8500) max_integrity = 65 /obj/item/shield/riot/roman/fake diff --git a/code/game/objects/items/stacks/bscrystal.dm b/code/game/objects/items/stacks/bscrystal.dm index 2686c7be6c4d..20abdf97fbd4 100644 --- a/code/game/objects/items/stacks/bscrystal.dm +++ b/code/game/objects/items/stacks/bscrystal.dm @@ -7,7 +7,7 @@ item_color = "cosmos" singular_name = "bluespace crystal" w_class = WEIGHT_CLASS_TINY - materials = list(MAT_BLUESPACE=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/bluespace=MINERAL_MATERIAL_AMOUNT) points = 75 var/blink_range = 8 // The teleport range when crushed/thrown at someone. refined_type = /obj/item/stack/sheet/bluespace_crystal @@ -50,7 +50,7 @@ /obj/item/stack/ore/bluespace_crystal/artificial name = "artificial bluespace crystal" desc = "An artificially made bluespace crystal, it looks delicate." - materials = list(MAT_BLUESPACE=MINERAL_MATERIAL_AMOUNT*0.5) + materials = list(/datum/material/bluespace=MINERAL_MATERIAL_AMOUNT*0.5) blink_range = 4 // Not as good as the organic stuff! points = 0 //nice try refined_type = null @@ -64,7 +64,7 @@ item_state = "sheet-polycrystal" singular_name = "bluespace polycrystal" desc = "A stable polycrystal, made of fused-together bluespace crystals. You could probably break one off." - materials = list(MAT_BLUESPACE=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/bluespace=MINERAL_MATERIAL_AMOUNT) attack_verb = list("bluespace polybashed", "bluespace polybattered", "bluespace polybludgeoned", "bluespace polythrashed", "bluespace polysmashed") novariants = TRUE grind_results = list(/datum/reagent/bluespace = 20) diff --git a/code/game/objects/items/stacks/rods.dm b/code/game/objects/items/stacks/rods.dm index 2d204eed1afb..ed13e24be401 100644 --- a/code/game/objects/items/stacks/rods.dm +++ b/code/game/objects/items/stacks/rods.dm @@ -25,7 +25,7 @@ GLOBAL_LIST_INIT(rod_recipes, list ( \ throwforce = 10 throw_speed = 3 throw_range = 7 - materials = list(MAT_METAL=1000) + materials = list(/datum/material/iron=1000) max_amount = 50 attack_verb = list("hit", "bludgeoned", "whacked") hitsound = 'sound/weapons/grenadelaunch.ogg' diff --git a/code/game/objects/items/stacks/sheets/glass.dm b/code/game/objects/items/stacks/sheets/glass.dm index 26f4fe5bbf93..9a5589a8269e 100644 --- a/code/game/objects/items/stacks/sheets/glass.dm +++ b/code/game/objects/items/stacks/sheets/glass.dm @@ -19,7 +19,7 @@ GLOBAL_LIST_INIT(glass_recipes, list ( \ singular_name = "glass sheet" icon_state = "sheet-glass" item_state = "sheet-glass" - materials = list(MAT_GLASS=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/glass=MINERAL_MATERIAL_AMOUNT) armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 50, "acid" = 100) resistance_flags = ACID_PROOF merge_type = /obj/item/stack/sheet/glass @@ -94,7 +94,7 @@ GLOBAL_LIST_INIT(pglass_recipes, list ( \ singular_name = "plasma glass sheet" icon_state = "sheet-pglass" item_state = "sheet-pglass" - materials = list(MAT_PLASMA=MINERAL_MATERIAL_AMOUNT * 0.5, MAT_GLASS=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/plasma=MINERAL_MATERIAL_AMOUNT * 0.5, /datum/material/glass=MINERAL_MATERIAL_AMOUNT) armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 75, "acid" = 100) resistance_flags = ACID_PROOF merge_type = /obj/item/stack/sheet/plasmaglass @@ -145,7 +145,7 @@ GLOBAL_LIST_INIT(reinforced_glass_recipes, list ( \ singular_name = "reinforced glass sheet" icon_state = "sheet-rglass" item_state = "sheet-rglass" - materials = list(MAT_METAL=MINERAL_MATERIAL_AMOUNT * 0.5, MAT_GLASS=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/iron=MINERAL_MATERIAL_AMOUNT * 0.5, /datum/material/glass=MINERAL_MATERIAL_AMOUNT) armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 70, "acid" = 100) resistance_flags = ACID_PROOF merge_type = /obj/item/stack/sheet/rglass @@ -191,7 +191,7 @@ GLOBAL_LIST_INIT(prglass_recipes, list ( \ singular_name = "reinforced plasma glass sheet" icon_state = "sheet-prglass" item_state = "sheet-prglass" - materials = list(MAT_PLASMA=MINERAL_MATERIAL_AMOUNT * 0.5, MAT_GLASS=MINERAL_MATERIAL_AMOUNT, MAT_METAL = MINERAL_MATERIAL_AMOUNT * 0.5,) + materials = list(/datum/material/plasma=MINERAL_MATERIAL_AMOUNT * 0.5, /datum/material/glass=MINERAL_MATERIAL_AMOUNT, /datum/material/iron = MINERAL_MATERIAL_AMOUNT * 0.5,) armor = list("melee" = 20, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 80, "acid" = 100) resistance_flags = ACID_PROOF merge_type = /obj/item/stack/sheet/plasmarglass @@ -212,7 +212,7 @@ GLOBAL_LIST_INIT(titaniumglass_recipes, list( singular_name = "titanium glass sheet" icon_state = "sheet-titaniumglass" item_state = "sheet-titaniumglass" - materials = list(MAT_TITANIUM=MINERAL_MATERIAL_AMOUNT * 0.5, MAT_GLASS=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/titanium=MINERAL_MATERIAL_AMOUNT * 0.5, /datum/material/glass=MINERAL_MATERIAL_AMOUNT) armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 80, "acid" = 100) resistance_flags = ACID_PROOF merge_type = /obj/item/stack/sheet/titaniumglass @@ -234,7 +234,7 @@ GLOBAL_LIST_INIT(plastitaniumglass_recipes, list( singular_name = "plastitanium glass sheet" icon_state = "sheet-plastitaniumglass" item_state = "sheet-plastitaniumglass" - materials = list(MAT_TITANIUM=MINERAL_MATERIAL_AMOUNT * 0.5, MAT_PLASMA=MINERAL_MATERIAL_AMOUNT * 0.5, MAT_GLASS=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/titanium=MINERAL_MATERIAL_AMOUNT * 0.5, /datum/material/plasma=MINERAL_MATERIAL_AMOUNT * 0.5, /datum/material/glass=MINERAL_MATERIAL_AMOUNT) armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 80, "acid" = 100) resistance_flags = ACID_PROOF merge_type = /obj/item/stack/sheet/plastitaniumglass @@ -257,7 +257,7 @@ GLOBAL_LIST_INIT(plastitaniumglass_recipes, list( item_state = "shard-glass" lefthand_file = 'icons/mob/inhands/weapons/melee_lefthand.dmi' righthand_file = 'icons/mob/inhands/weapons/melee_righthand.dmi' - materials = list(MAT_GLASS=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/glass=MINERAL_MATERIAL_AMOUNT) attack_verb = list("stabbed", "slashed", "sliced", "cut") hitsound = 'sound/weapons/bladeslice.ogg' resistance_flags = ACID_PROOF @@ -347,5 +347,5 @@ GLOBAL_LIST_INIT(plastitaniumglass_recipes, list( force = 6 throwforce = 11 icon_state = "plasmalarge" - materials = list(MAT_PLASMA=MINERAL_MATERIAL_AMOUNT * 0.5, MAT_GLASS=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/plasma=MINERAL_MATERIAL_AMOUNT * 0.5, /datum/material/glass=MINERAL_MATERIAL_AMOUNT) icon_prefix = "plasma" diff --git a/code/game/objects/items/stacks/sheets/mineral.dm b/code/game/objects/items/stacks/sheets/mineral.dm index d6d60c5c5ef5..1f0280b7267c 100644 --- a/code/game/objects/items/stacks/sheets/mineral.dm +++ b/code/game/objects/items/stacks/sheets/mineral.dm @@ -44,7 +44,7 @@ GLOBAL_LIST_INIT(sandstone_recipes, list ( \ item_state = "sheet-sandstone" throw_speed = 3 throw_range = 5 - materials = list(MAT_GLASS=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/glass=MINERAL_MATERIAL_AMOUNT) sheettype = "sandstone" merge_type = /obj/item/stack/sheet/mineral/sandstone @@ -103,7 +103,7 @@ GLOBAL_LIST_INIT(sandbag_recipes, list ( \ item_state = "sheet-diamond" singular_name = "diamond" sheettype = "diamond" - materials = list(MAT_DIAMOND=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/diamond=MINERAL_MATERIAL_AMOUNT) novariants = TRUE grind_results = list(/datum/reagent/carbon = 30) point_value = 50 @@ -133,7 +133,7 @@ GLOBAL_LIST_INIT(diamond_recipes, list ( \ item_state = "sheet-uranium" singular_name = "uranium sheet" sheettype = "uranium" - materials = list(MAT_URANIUM=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/uranium=MINERAL_MATERIAL_AMOUNT) novariants = TRUE grind_results = list(/datum/reagent/uranium = 20) point_value = 35 @@ -164,7 +164,7 @@ GLOBAL_LIST_INIT(uranium_recipes, list ( \ sheettype = "plasma" resistance_flags = FLAMMABLE max_integrity = 100 - materials = list(MAT_PLASMA=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/plasma=MINERAL_MATERIAL_AMOUNT) grind_results = list(/datum/reagent/toxin/plasma = 20) point_value = 25 merge_type = /obj/item/stack/sheet/mineral/plasma @@ -208,7 +208,7 @@ GLOBAL_LIST_INIT(plasma_recipes, list ( \ item_state = "sheet-gold" singular_name = "gold bar" sheettype = "gold" - materials = list(MAT_GOLD=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/gold=MINERAL_MATERIAL_AMOUNT) grind_results = list(/datum/reagent/gold = 20) point_value = 30 merge_type = /obj/item/stack/sheet/mineral/gold @@ -240,7 +240,7 @@ GLOBAL_LIST_INIT(gold_recipes, list ( \ item_state = "sheet-silver" singular_name = "silver bar" sheettype = "silver" - materials = list(MAT_SILVER=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/silver=MINERAL_MATERIAL_AMOUNT) grind_results = list(/datum/reagent/silver = 20) point_value = 25 merge_type = /obj/item/stack/sheet/mineral/silver @@ -272,7 +272,7 @@ GLOBAL_LIST_INIT(silver_recipes, list ( \ item_state = "sheet-bananium" singular_name = "bananium sheet" sheettype = "bananium" - materials = list(MAT_BANANIUM=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/bananium=MINERAL_MATERIAL_AMOUNT) novariants = TRUE grind_results = list(/datum/reagent/consumable/banana = 20) point_value = 50 @@ -307,7 +307,7 @@ GLOBAL_LIST_INIT(bananium_recipes, list ( \ throw_speed = 1 throw_range = 3 sheettype = "titanium" - materials = list(MAT_TITANIUM=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/titanium=MINERAL_MATERIAL_AMOUNT) point_value = 35 merge_type = /obj/item/stack/sheet/mineral/titanium @@ -337,7 +337,7 @@ GLOBAL_LIST_INIT(titanium_recipes, list ( \ throw_speed = 1 throw_range = 3 sheettype = "plastitanium" - materials = list(MAT_TITANIUM=MINERAL_MATERIAL_AMOUNT, MAT_PLASMA=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/titanium=MINERAL_MATERIAL_AMOUNT, /datum/material/plasma=MINERAL_MATERIAL_AMOUNT) point_value = 45 merge_type = /obj/item/stack/sheet/mineral/plastitanium diff --git a/code/game/objects/items/stacks/sheets/sheet_types.dm b/code/game/objects/items/stacks/sheets/sheet_types.dm index 2eb9a9e6423f..0882ceab71b4 100644 --- a/code/game/objects/items/stacks/sheets/sheet_types.dm +++ b/code/game/objects/items/stacks/sheets/sheet_types.dm @@ -99,7 +99,7 @@ GLOBAL_LIST_INIT(metal_recipes, list ( \ singular_name = "metal sheet" icon_state = "sheet-metal" item_state = "sheet-metal" - materials = list(MAT_METAL=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/iron=MINERAL_MATERIAL_AMOUNT) throwforce = 10 flags_1 = CONDUCT_1 resistance_flags = FIRE_PROOF @@ -160,7 +160,7 @@ GLOBAL_LIST_INIT(plasteel_recipes, list ( \ desc = "This sheet is an alloy of iron and plasma." icon_state = "sheet-plasteel" item_state = "sheet-metal" - materials = list(MAT_METAL=2000, MAT_PLASMA=2000) + materials = list(/datum/material/iron=2000, /datum/material/plasma=2000) throwforce = 10 flags_1 = CONDUCT_1 armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 100, "acid" = 80) @@ -674,7 +674,7 @@ GLOBAL_LIST_INIT(plastic_recipes, list( singular_name = "plastic sheet" icon_state = "sheet-plastic" item_state = "sheet-plastic" - materials = list(MAT_PLASTIC=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/plastic=MINERAL_MATERIAL_AMOUNT) throwforce = 7 merge_type = /obj/item/stack/sheet/plastic diff --git a/code/game/objects/items/stacks/sheets/sheets.dm b/code/game/objects/items/stacks/sheets/sheets.dm index 9ca043ba19e5..a8cc518d596d 100644 --- a/code/game/objects/items/stacks/sheets/sheets.dm +++ b/code/game/objects/items/stacks/sheets/sheets.dm @@ -10,7 +10,7 @@ throw_range = 3 attack_verb = list("bashed", "battered", "bludgeoned", "thrashed", "smashed") novariants = FALSE - var/perunit = MINERAL_MATERIAL_AMOUNT + mats_per_stack = MINERAL_MATERIAL_AMOUNT var/sheettype = null //this is used for girders in the creation of walls/false walls var/point_value = 0 //turn-in value for the gulag stacker - loosely relative to its rarity. var/is_fabric = FALSE //is this a valid material for the loom? diff --git a/code/game/objects/items/stacks/stack.dm b/code/game/objects/items/stacks/stack.dm index 1a15bca88142..5b02146a4396 100644 --- a/code/game/objects/items/stacks/stack.dm +++ b/code/game/objects/items/stacks/stack.dm @@ -23,6 +23,7 @@ var/novariants = TRUE //Determines whether the item should update it's sprites based on amount. //NOTE: When adding grind_results, the amounts should be for an INDIVIDUAL ITEM - these amounts will be multiplied by the stack size in on_grind() var/obj/structure/table/tableVariant // we tables now (stores table variant to be built from this stack) + var/mats_per_stack = 0 /obj/item/stack/on_grind() for(var/i in 1 to grind_results.len) //This should only call if it's ground, so no need to check if grind_results exists diff --git a/code/game/objects/items/stacks/tiles/tile_mineral.dm b/code/game/objects/items/stacks/tiles/tile_mineral.dm index 9b46420febbe..03380c2c0007 100644 --- a/code/game/objects/items/stacks/tiles/tile_mineral.dm +++ b/code/game/objects/items/stacks/tiles/tile_mineral.dm @@ -6,7 +6,7 @@ item_state = "tile-plasma" turf_type = /turf/open/floor/mineral/plasma mineralType = "plasma" - materials = list(MAT_PLASMA=500) + materials = list(/datum/material/plasma=500) /obj/item/stack/tile/mineral/uranium name = "uranium tile" @@ -16,7 +16,7 @@ item_state = "tile-uranium" turf_type = /turf/open/floor/mineral/uranium mineralType = "uranium" - materials = list(MAT_URANIUM=500) + materials = list(/datum/material/uranium=500) /obj/item/stack/tile/mineral/gold name = "gold tile" @@ -26,7 +26,7 @@ item_state = "tile-gold" turf_type = /turf/open/floor/mineral/gold mineralType = "gold" - materials = list(MAT_GOLD=500) + materials = list(/datum/material/gold=500) /obj/item/stack/tile/mineral/silver name = "silver tile" @@ -36,7 +36,7 @@ item_state = "tile-silver" turf_type = /turf/open/floor/mineral/silver mineralType = "silver" - materials = list(MAT_SILVER=500) + materials = list(/datum/material/silver=500) /obj/item/stack/tile/mineral/diamond name = "diamond tile" @@ -46,7 +46,7 @@ item_state = "tile-diamond" turf_type = /turf/open/floor/mineral/diamond mineralType = "diamond" - materials = list(MAT_DIAMOND=500) + materials = list(/datum/material/diamond=500) /obj/item/stack/tile/mineral/bananium name = "bananium tile" @@ -56,7 +56,7 @@ item_state = "tile-bananium" turf_type = /turf/open/floor/mineral/bananium mineralType = "bananium" - materials = list(MAT_BANANIUM=500) + materials = list(/datum/material/bananium=500) /obj/item/stack/tile/mineral/abductor name = "alien floor tile" @@ -76,7 +76,7 @@ item_state = "tile-shuttle" turf_type = /turf/open/floor/mineral/titanium mineralType = "titanium" - materials = list(MAT_TITANIUM=500) + materials = list(/datum/material/titanium=500) /obj/item/stack/tile/mineral/plastitanium name = "plastitanium tile" @@ -86,7 +86,7 @@ item_state = "tile-darkshuttle" turf_type = /turf/open/floor/mineral/plastitanium mineralType = "plastitanium" - materials = list(MAT_TITANIUM=250, MAT_PLASMA=250) + materials = list(/datum/material/titanium=250, /datum/material/plasma=250) /obj/item/stack/tile/mineral/snow name = "snow tile" diff --git a/code/game/objects/items/stacks/tiles/tile_types.dm b/code/game/objects/items/stacks/tiles/tile_types.dm index 5727ff80c564..777d8f051463 100644 --- a/code/game/objects/items/stacks/tiles/tile_types.dm +++ b/code/game/objects/items/stacks/tiles/tile_types.dm @@ -11,6 +11,7 @@ throw_speed = 3 throw_range = 7 max_amount = 60 + mats_per_stack = 500 var/turf_type = null var/mineralType = null novariants = TRUE @@ -303,7 +304,7 @@ icon_state = "tile" item_state = "tile" force = 6 - materials = list(MAT_METAL=500) + materials = list(/datum/material/iron=500) throwforce = 10 flags_1 = CONDUCT_1 turf_type = /turf/open/floor/plasteel diff --git a/code/game/objects/items/storage/bags.dm b/code/game/objects/items/storage/bags.dm index 743ae710050d..8fa064c68695 100644 --- a/code/game/objects/items/storage/bags.dm +++ b/code/game/objects/items/storage/bags.dm @@ -287,7 +287,7 @@ throw_range = 5 w_class = WEIGHT_CLASS_BULKY flags_1 = CONDUCT_1 - materials = list(MAT_METAL=3000) + materials = list(/datum/material/iron=3000) /obj/item/storage/bag/tray/ComponentInitialize() . = ..() diff --git a/code/game/objects/items/storage/belt.dm b/code/game/objects/items/storage/belt.dm index c6c6e53fd29b..b1c30f04cd41 100644 --- a/code/game/objects/items/storage/belt.dm +++ b/code/game/objects/items/storage/belt.dm @@ -342,7 +342,7 @@ desc = "Proves to the world that you are the strongest!" icon_state = "championbelt" item_state = "champion" - materials = list(MAT_GOLD=400) + materials = list(/datum/material/gold=400) /obj/item/storage/belt/champion/ComponentInitialize() . = ..() diff --git a/code/game/objects/items/storage/toolbox.dm b/code/game/objects/items/storage/toolbox.dm index ee10ed78f9ad..d8834722d25a 100644 --- a/code/game/objects/items/storage/toolbox.dm +++ b/code/game/objects/items/storage/toolbox.dm @@ -1,8 +1,8 @@ /obj/item/storage/toolbox name = "toolbox" desc = "Danger. Very robust." - icon_state = "red" - item_state = "toolbox_red" + icon_state = "toolbox_default" + item_state = "toolbox_default" lefthand_file = 'icons/mob/inhands/equipment/toolbox_lefthand.dmi' righthand_file = 'icons/mob/inhands/equipment/toolbox_righthand.dmi' flags_1 = CONDUCT_1 @@ -11,9 +11,10 @@ throw_speed = 2 throw_range = 7 w_class = WEIGHT_CLASS_BULKY - materials = list(MAT_METAL = 500) + materials = list(/datum/material/iron = 500) attack_verb = list("robusted") hitsound = 'sound/weapons/smash.ogg' + custom_materials = list(/datum/material/iron = 500) //Toolboxes by default use iron as their core, custom material. var/latches = "single_latch" var/has_latches = TRUE @@ -41,6 +42,7 @@ name = "emergency toolbox" icon_state = "red" item_state = "toolbox_red" + material_flags = MATERIAL_NO_COLOR /obj/item/storage/toolbox/emergency/PopulateContents() new /obj/item/crowbar/red(src) @@ -63,11 +65,13 @@ name = "rusty red toolbox" icon_state = "toolbox_red_old" has_latches = FALSE + material_flags = MATERIAL_NO_COLOR /obj/item/storage/toolbox/mechanical name = "mechanical toolbox" icon_state = "blue" item_state = "toolbox_blue" + material_flags = MATERIAL_NO_COLOR /obj/item/storage/toolbox/mechanical/PopulateContents() new /obj/item/screwdriver(src) @@ -81,6 +85,7 @@ name = "rusty blue toolbox" icon_state = "toolbox_blue_old" has_latches = FALSE + material_flags = MATERIAL_NO_COLOR /obj/item/storage/toolbox/mechanical/old/heirloom name = "toolbox" //this will be named "X family toolbox" @@ -128,6 +133,7 @@ name = "electrical toolbox" icon_state = "yellow" item_state = "toolbox_yellow" + material_flags = MATERIAL_NO_COLOR /obj/item/storage/toolbox/electrical/PopulateContents() var/pickedcolor = pick("red","yellow","green","blue","pink","orange","cyan","white") @@ -149,6 +155,7 @@ force = 15 throwforce = 18 w_class = WEIGHT_CLASS_NORMAL + material_flags = MATERIAL_NO_COLOR /obj/item/storage/toolbox/syndicate/ComponentInitialize() . = ..() @@ -176,6 +183,7 @@ name = "mechanical toolbox" icon_state = "blue" item_state = "toolbox_blue" + material_flags = MATERIAL_NO_COLOR /obj/item/storage/toolbox/drone/PopulateContents() var/pickedcolor = pick("red","yellow","green","blue","pink","orange","cyan","white") @@ -197,6 +205,7 @@ w_class = WEIGHT_CLASS_HUGE attack_verb = list("robusted", "crushed", "smashed") var/fabricator_type = /obj/item/clockwork/replica_fabricator/scarab + material_flags = MATERIAL_NO_COLOR /obj/item/storage/toolbox/brass/ComponentInitialize() . = ..() diff --git a/code/game/objects/items/tanks/tanks.dm b/code/game/objects/items/tanks/tanks.dm index 2eed62ea38b2..31c31f188b53 100644 --- a/code/game/objects/items/tanks/tanks.dm +++ b/code/game/objects/items/tanks/tanks.dm @@ -11,7 +11,7 @@ throwforce = 10 throw_speed = 1 throw_range = 4 - materials = list(MAT_METAL = 500) + materials = list(/datum/material/iron = 500) actions_types = list(/datum/action/item_action/set_internals) armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 10, "bio" = 0, "rad" = 0, "fire" = 80, "acid" = 30) var/datum/gas_mixture/air_contents = null diff --git a/code/game/objects/items/teleportation.dm b/code/game/objects/items/teleportation.dm index 018f300d3eaf..726517bd64f5 100644 --- a/code/game/objects/items/teleportation.dm +++ b/code/game/objects/items/teleportation.dm @@ -23,7 +23,7 @@ righthand_file = 'icons/mob/inhands/misc/devices_righthand.dmi' throw_speed = 3 throw_range = 7 - materials = list(MAT_METAL=400) + materials = list(/datum/material/iron=400) var/tracking_range = 20 /obj/item/locator/ui_interact(mob/user, datum/tgui/ui) @@ -109,7 +109,7 @@ w_class = WEIGHT_CLASS_SMALL throw_speed = 3 throw_range = 5 - materials = list(MAT_METAL=10000) + materials = list(/datum/material/iron=10000) armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 30, "bio" = 0, "rad" = 0, "fire" = 100, "acid" = 100) resistance_flags = INDESTRUCTIBLE | LAVA_PROOF | FIRE_PROOF | ACID_PROOF var/list/active_portal_pairs diff --git a/code/game/objects/items/tools/crowbar.dm b/code/game/objects/items/tools/crowbar.dm index 11ab0e86551a..459081c2c396 100644 --- a/code/game/objects/items/tools/crowbar.dm +++ b/code/game/objects/items/tools/crowbar.dm @@ -11,7 +11,7 @@ force = 5 throwforce = 7 w_class = WEIGHT_CLASS_SMALL - materials = list(MAT_METAL=50) + materials = list(/datum/material/iron=50) attack_verb = list("attacked", "bashed", "battered", "bludgeoned", "whacked") tool_behaviour = TOOL_CROWBAR @@ -50,7 +50,7 @@ w_class = WEIGHT_CLASS_NORMAL throw_speed = 3 throw_range = 3 - materials = list(MAT_METAL=70) + materials = list(/datum/material/iron=70) icon_state = "crowbar_large" item_state = "crowbar" toolspeed = 0.7 diff --git a/code/game/objects/items/tools/screwdriver.dm b/code/game/objects/items/tools/screwdriver.dm index 8317885c25f8..03899e4a9547 100644 --- a/code/game/objects/items/tools/screwdriver.dm +++ b/code/game/objects/items/tools/screwdriver.dm @@ -13,7 +13,7 @@ throwforce = 5 throw_speed = 3 throw_range = 5 - materials = list(MAT_METAL=75) + materials = list(/datum/material/iron=75) attack_verb = list("stabbed") hitsound = 'sound/weapons/bladeslice.ogg' usesound = list('sound/items/screwdriver.ogg', 'sound/items/screwdriver2.ogg') diff --git a/code/game/objects/items/tools/weldingtool.dm b/code/game/objects/items/tools/weldingtool.dm index 842394aee813..248d6589ff12 100644 --- a/code/game/objects/items/tools/weldingtool.dm +++ b/code/game/objects/items/tools/weldingtool.dm @@ -21,7 +21,7 @@ armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 100, "acid" = 30) resistance_flags = FIRE_PROOF - materials = list(MAT_METAL=70, MAT_GLASS=30) + materials = list(/datum/material/iron=70, /datum/material/glass=30) var/welding = 0 //Whether or not the welding tool is off(0), on(1) or currently welding(2) var/status = TRUE //Whether the welder is secured or unsecured (able to attach rods to it to make a flamethrower) var/max_fuel = 20 //The max amount of fuel the welder can hold @@ -297,7 +297,7 @@ desc = "A slightly larger welder with a larger tank." icon_state = "indwelder" max_fuel = 40 - materials = list(MAT_GLASS=60) + materials = list(/datum/material/glass=60) /obj/item/weldingtool/largetank/cyborg name = "integrated welding tool" @@ -319,7 +319,7 @@ icon_state = "miniwelder" max_fuel = 10 w_class = WEIGHT_CLASS_TINY - materials = list(MAT_METAL=30, MAT_GLASS=10) + materials = list(/datum/material/iron=30, /datum/material/glass=10) change_icons = 0 /obj/item/weldingtool/mini/flamethrower_screwdriver() @@ -345,7 +345,7 @@ icon_state = "upindwelder" item_state = "upindwelder" max_fuel = 80 - materials = list(MAT_METAL=70, MAT_GLASS=120) + materials = list(/datum/material/iron=70, /datum/material/glass=120) /obj/item/weldingtool/experimental name = "experimental welding tool" @@ -353,7 +353,7 @@ icon_state = "exwelder" item_state = "exwelder" max_fuel = 40 - materials = list(MAT_METAL=70, MAT_GLASS=120) + materials = list(/datum/material/iron=70, /datum/material/glass=120) var/last_gen = 0 change_icons = 0 can_off_process = 1 diff --git a/code/game/objects/items/tools/wirecutters.dm b/code/game/objects/items/tools/wirecutters.dm index 80ea4304045f..ef5b99f850b1 100644 --- a/code/game/objects/items/tools/wirecutters.dm +++ b/code/game/objects/items/tools/wirecutters.dm @@ -12,7 +12,7 @@ throw_speed = 3 throw_range = 7 w_class = WEIGHT_CLASS_SMALL - materials = list(MAT_METAL=80) + materials = list(/datum/material/iron=80) attack_verb = list("pinched", "nipped") hitsound = 'sound/items/wirecutter.ogg' usesound = 'sound/items/wirecutter.ogg' diff --git a/code/game/objects/items/tools/wrench.dm b/code/game/objects/items/tools/wrench.dm index af1344dc2737..9654f7aced12 100644 --- a/code/game/objects/items/tools/wrench.dm +++ b/code/game/objects/items/tools/wrench.dm @@ -11,7 +11,7 @@ throwforce = 7 w_class = WEIGHT_CLASS_SMALL usesound = 'sound/items/ratchet.ogg' - materials = list(MAT_METAL=150) + materials = list(/datum/material/iron=150) attack_verb = list("bashed", "battered", "bludgeoned", "whacked") tool_behaviour = TOOL_WRENCH diff --git a/code/game/objects/items/toys.dm b/code/game/objects/items/toys.dm index 88321d5b346d..797526459dcc 100644 --- a/code/game/objects/items/toys.dm +++ b/code/game/objects/items/toys.dm @@ -180,7 +180,7 @@ flags_1 = CONDUCT_1 slot_flags = ITEM_SLOT_BELT w_class = WEIGHT_CLASS_NORMAL - materials = list(MAT_METAL=10, MAT_GLASS=10) + materials = list(/datum/material/iron=10, /datum/material/glass=10) attack_verb = list("struck", "pistol whipped", "hit", "bashed") var/bullets = 7 @@ -234,7 +234,7 @@ icon = 'icons/obj/ammo.dmi' icon_state = "357OLD-7" w_class = WEIGHT_CLASS_TINY - materials = list(MAT_METAL=10, MAT_GLASS=10) + materials = list(/datum/material/iron=10, /datum/material/glass=10) var/amount_left = 7 /obj/item/toy/ammo/gun/update_icon() diff --git a/code/game/objects/items/twohanded.dm b/code/game/objects/items/twohanded.dm index 409ae88f2c24..d3eb51d2d4f5 100644 --- a/code/game/objects/items/twohanded.dm +++ b/code/game/objects/items/twohanded.dm @@ -467,7 +467,7 @@ throw_speed = 4 embedding = list("embedded_impact_pain_multiplier" = 3) armour_penetration = 10 - materials = list(MAT_METAL=1150, MAT_GLASS=2075) + materials = list(/datum/material/iron=1150, /datum/material/glass=2075) hitsound = 'sound/weapons/bladeslice.ogg' attack_verb = list("attacked", "poked", "jabbed", "torn", "gored") sharpness = IS_SHARP @@ -575,7 +575,7 @@ throwforce = 13 throw_speed = 2 throw_range = 4 - materials = list(MAT_METAL=13000) + materials = list(/datum/material/iron=13000) attack_verb = list("sawed", "torn", "cut", "chopped", "diced") hitsound = "swing_hit" sharpness = IS_SHARP diff --git a/code/game/objects/items/weaponry.dm b/code/game/objects/items/weaponry.dm index 8c43e9e80f6e..4cf4225719d5 100644 --- a/code/game/objects/items/weaponry.dm +++ b/code/game/objects/items/weaponry.dm @@ -17,7 +17,7 @@ /obj/item/banhammer/suicide_act(mob/user) user.visible_message("[user] is hitting [user.p_them()]self with [src]! It looks like [user.p_theyre()] trying to ban [user.p_them()]self from life.") return (BRUTELOSS|FIRELOSS|TOXLOSS|OXYLOSS) -/* +/* oranges says: This is a meme relating to the english translation of the ss13 russian wiki page on lurkmore. mrdoombringer sez: and remember kids, if you try and PR a fix for this item's grammar, you are admitting that you are, indeed, a newfriend. for further reading, please see: https://github.com/tgstation/tgstation/pull/30173 and https://translate.google.com/translate?sl=auto&tl=en&js=y&prev=_t&hl=en&ie=UTF-8&u=%2F%2Flurkmore.to%2FSS13&edit-text=&act=url @@ -239,7 +239,7 @@ for further reading, please see: https://github.com/tgstation/tgstation/pull/301 force = 9 throwforce = 10 w_class = WEIGHT_CLASS_NORMAL - materials = list(MAT_METAL=1150, MAT_GLASS=75) + materials = list(/datum/material/iron=1150, /datum/material/glass=75) attack_verb = list("hit", "bludgeoned", "whacked", "bonked") /obj/item/wirerod/attackby(obj/item/I, mob/user, params) @@ -283,7 +283,7 @@ for further reading, please see: https://github.com/tgstation/tgstation/pull/301 embedding = list("embedded_pain_multiplier" = 4, "embed_chance" = 100, "embedded_fall_chance" = 0) w_class = WEIGHT_CLASS_SMALL sharpness = IS_SHARP - materials = list(MAT_METAL=500, MAT_GLASS=500) + materials = list(/datum/material/iron=500, /datum/material/glass=500) resistance_flags = FIRE_PROOF /obj/item/throwing_star/magspear @@ -309,7 +309,7 @@ for further reading, please see: https://github.com/tgstation/tgstation/pull/301 throwforce = 5 throw_speed = 3 throw_range = 6 - materials = list(MAT_METAL=12000) + materials = list(/datum/material/iron=12000) hitsound = 'sound/weapons/genhit.ogg' attack_verb = list("stubbed", "poked") resistance_flags = FIRE_PROOF @@ -358,7 +358,7 @@ for further reading, please see: https://github.com/tgstation/tgstation/pull/301 else user.visible_message("[user] is strangling [user.p_them()]self with [src]'s cord! It looks like [user.p_theyre()] trying to commit suicide!") return(OXYLOSS) - + /obj/item/phone/real desc = "A bluespace last resort negotiation tool connected directly to the enemy should anything ever go wrong. Misuse will likely lead to the line being cut or anything else they're capable of. All communication is monitored by Nanotrasen Officials." @@ -371,7 +371,7 @@ for further reading, please see: https://github.com/tgstation/tgstation/pull/301 to_chat(usr, "Message sent. Pray you made the right choice.") usr.log_talk(input, LOG_SAY, tag="Syndicate announcement") deadchat_broadcast(" has messaged the Syndicate using the red phone, \"[input]\" at [get_area_name(usr, TRUE)].", "[usr.real_name]", usr) - + /obj/item/phone/banana name = "banana phone" desc = "Direct telecommunications line to the Clown Planet. Use for emergencies only!" @@ -384,7 +384,7 @@ for further reading, please see: https://github.com/tgstation/tgstation/pull/301 w_class = WEIGHT_CLASS_SMALL attack_verb = list("called", "rang") hitsound = 'sound/items/bikehorn.ogg' - + /obj/item/phone/banana/attack_self(mob/user) var/input = stripped_input(usr, "Please choose a message to send. If you are unsure, you can still turn back.", "Send a message to the Clown Planet.", "") if(!input || !(usr in view(1,src))) @@ -394,7 +394,7 @@ for further reading, please see: https://github.com/tgstation/tgstation/pull/301 to_chat(usr, "Message sent. The Clown Planet will judge your message.") usr.log_talk(input, LOG_SAY, tag="Clown Planet announcement") deadchat_broadcast(" has messaged the Clown Planet using the banana phone, \"[input]\" at [get_area_name(usr, TRUE)].", "[usr.real_name]", usr) - + /obj/item/cane name = "cane" desc = "A cane used by a true gentleman. Or a clown." @@ -406,7 +406,7 @@ for further reading, please see: https://github.com/tgstation/tgstation/pull/301 force = 5 throwforce = 5 w_class = WEIGHT_CLASS_SMALL - materials = list(MAT_METAL=50) + materials = list(/datum/material/iron=50) attack_verb = list("bludgeoned", "whacked", "disciplined", "thrashed") /obj/item/staff diff --git a/code/game/objects/structures/beds_chairs/chair.dm b/code/game/objects/structures/beds_chairs/chair.dm index 4244af813909..b8418d3b1921 100644 --- a/code/game/objects/structures/beds_chairs/chair.dm +++ b/code/game/objects/structures/beds_chairs/chair.dm @@ -270,7 +270,7 @@ throw_range = 3 hitsound = 'sound/items/trayhit1.ogg' hit_reaction_chance = 50 - materials = list(MAT_METAL = 2000) + materials = list(/datum/material/iron = 2000) var/break_chance = 5 //Likely hood of smashing the chair. var/obj/structure/chair/origin_type = /obj/structure/chair @@ -311,7 +311,7 @@ if(remaining_mats) for(var/M=1 to remaining_mats) new stack_type(get_turf(loc)) - else if(materials[MAT_METAL]) + else if(materials[/datum/material/iron]) new /obj/item/stack/rods(get_turf(loc), 2) qdel(src) diff --git a/code/game/objects/structures/tables_racks.dm b/code/game/objects/structures/tables_racks.dm index fa3452347dc8..b0bdba9d572a 100644 --- a/code/game/objects/structures/tables_racks.dm +++ b/code/game/objects/structures/tables_racks.dm @@ -33,7 +33,7 @@ integrity_failure = 30 smooth = SMOOTH_TRUE canSmoothWith = list(/obj/structure/table, /obj/structure/table/reinforced) - + /** Performs a complex check for toe stubbing as people would scream "IMPROVE DONT REMOVE" if I had my way. * Uses an early probability based return for to save cycles which is perfectly valid since the highest probability is 20 anyway. * Chance of getting your toe stubbed: (regular = 0.033%, running = 0.1%, blind = 20%, blurry_eyes = 2%, congenitally blind = 1% ) @@ -45,7 +45,7 @@ return if(!istype(H) || H.shoes || !(H.mobility_flags & MOBILITY_STAND) || !H.dna.species.has_toes()) return - var/speed_multiplier = 2/H.cached_multiplicative_slowdown + var/speed_multiplier = 2/H.cached_multiplicative_slowdown var/blindness_multiplier = 0 if(H.eye_blurry) blindness_multiplier = 4 @@ -56,7 +56,7 @@ var/chance = 0.5*blindness_multiplier*speed_multiplier if(prob(chance)) to_chat(H, "You stub your toe on the [name]!") - H.visible_message("[H] stubs their toe on the [name].") + H.visible_message("[H] stubs their toe on the [name].") H.emote("scream") var/shiddedleg = pick(BODY_ZONE_PRECISE_R_FOOT, BODY_ZONE_PRECISE_L_FOOT) H.apply_damage(2*speed_multiplier, BRUTE, def_zone = shiddedleg) @@ -130,7 +130,7 @@ if(istype(mover) && (mover.pass_flags & PASSTABLE)) return TRUE - + if(iscarbon(mover)) var/mob/living/carbon/C = mover var/obj/item/tank/jetpack/jetpacktable = C.get_jetpack() @@ -640,7 +640,7 @@ icon = 'icons/obj/items_and_weapons.dmi' icon_state = "rack_parts" flags_1 = CONDUCT_1 - materials = list(MAT_METAL=2000) + materials = list(/datum/material/iron=2000) var/building = FALSE /obj/item/rack_parts/attackby(obj/item/W, mob/user, params) diff --git a/code/modules/antagonists/overthrow/overthrow_converter.dm b/code/modules/antagonists/overthrow/overthrow_converter.dm index 23599bd01be1..cfd888766522 100644 --- a/code/modules/antagonists/overthrow/overthrow_converter.dm +++ b/code/modules/antagonists/overthrow/overthrow_converter.dm @@ -9,7 +9,7 @@ throw_speed = 3 throw_range = 5 w_class = WEIGHT_CLASS_SMALL - materials = list(MAT_METAL=600, MAT_GLASS=200) + materials = list(/datum/material/iron=600, /datum/material/glass=200) var/uses = 2 /obj/item/overthrow_converter/proc/convert(mob/living/carbon/human/target, mob/living/carbon/human/user) // Should probably also delete any mindshield implant. Not sure. diff --git a/code/modules/assembly/assembly.dm b/code/modules/assembly/assembly.dm index fdaa2cc07244..54dc8b194e68 100644 --- a/code/modules/assembly/assembly.dm +++ b/code/modules/assembly/assembly.dm @@ -12,7 +12,7 @@ icon_state = "" flags_1 = CONDUCT_1 w_class = WEIGHT_CLASS_SMALL - materials = list(MAT_METAL=100) + materials = list(/datum/material/iron=100) throwforce = 2 throw_speed = 3 throw_range = 7 diff --git a/code/modules/assembly/flash.dm b/code/modules/assembly/flash.dm index 7a7bd2e98c3e..17ee6d11bfe4 100644 --- a/code/modules/assembly/flash.dm +++ b/code/modules/assembly/flash.dm @@ -8,7 +8,7 @@ righthand_file = 'icons/mob/inhands/equipment/security_righthand.dmi' throwforce = 0 w_class = WEIGHT_CLASS_TINY - materials = list(MAT_METAL = 300, MAT_GLASS = 300) + materials = list(/datum/material/iron = 300, /datum/material/glass = 300) light_color = LIGHT_COLOR_WHITE light_power = FLASH_LIGHT_POWER var/flashing_overlay = "flash-f" diff --git a/code/modules/assembly/health.dm b/code/modules/assembly/health.dm index 5a132f033d4a..19ec84f4433a 100644 --- a/code/modules/assembly/health.dm +++ b/code/modules/assembly/health.dm @@ -2,7 +2,7 @@ name = "health sensor" desc = "Used for scanning and monitoring health." icon_state = "health" - materials = list(MAT_METAL=800, MAT_GLASS=200) + materials = list(/datum/material/iron=800, /datum/material/glass=200) attachable = TRUE var/scanning = FALSE diff --git a/code/modules/assembly/igniter.dm b/code/modules/assembly/igniter.dm index e303e2341297..79a793da1c47 100644 --- a/code/modules/assembly/igniter.dm +++ b/code/modules/assembly/igniter.dm @@ -2,7 +2,7 @@ name = "igniter" desc = "A small electronic device able to ignite combustible substances." icon_state = "igniter" - materials = list(MAT_METAL=500, MAT_GLASS=50) + materials = list(/datum/material/iron=500, /datum/material/glass=50) var/datum/effect_system/spark_spread/sparks heat = 1000 diff --git a/code/modules/assembly/mousetrap.dm b/code/modules/assembly/mousetrap.dm index d49576588be5..4e7248c9ffb0 100644 --- a/code/modules/assembly/mousetrap.dm +++ b/code/modules/assembly/mousetrap.dm @@ -3,7 +3,7 @@ desc = "A handy little spring-loaded trap for catching pesty rodents." icon_state = "mousetrap" item_state = "mousetrap" - materials = list(MAT_METAL=100) + materials = list(/datum/material/iron=100) attachable = TRUE layer = BELOW_OBJ_LAYER var/armed = FALSE diff --git a/code/modules/assembly/signaler.dm b/code/modules/assembly/signaler.dm index f23ab23affc2..c7ee578f15e0 100644 --- a/code/modules/assembly/signaler.dm +++ b/code/modules/assembly/signaler.dm @@ -5,7 +5,7 @@ item_state = "signaler" lefthand_file = 'icons/mob/inhands/misc/devices_lefthand.dmi' righthand_file = 'icons/mob/inhands/misc/devices_righthand.dmi' - materials = list(MAT_METAL=400, MAT_GLASS=120) + materials = list(/datum/material/iron=400, /datum/material/glass=120) wires = WIRE_RECEIVE | WIRE_PULSE | WIRE_RADIO_PULSE | WIRE_RADIO_RECEIVE attachable = TRUE var/code = DEFAULT_SIGNALER_CODE diff --git a/code/modules/assembly/timer.dm b/code/modules/assembly/timer.dm index fa393ec1fe86..844ebf5d6507 100644 --- a/code/modules/assembly/timer.dm +++ b/code/modules/assembly/timer.dm @@ -2,7 +2,7 @@ name = "timer" desc = "Used to time things. Works well with contraptions which has to count down. Tick tock." icon_state = "timer" - materials = list(MAT_METAL=500, MAT_GLASS=50) + materials = list(/datum/material/iron=500, /datum/material/glass=50) attachable = TRUE var/timing = FALSE var/time = 5 diff --git a/code/modules/assembly/voice.dm b/code/modules/assembly/voice.dm index da3943747af6..cd92269d88bc 100644 --- a/code/modules/assembly/voice.dm +++ b/code/modules/assembly/voice.dm @@ -7,7 +7,7 @@ name = "voice analyzer" desc = "A small electronic device able to record a voice sample, and send a signal when that sample is repeated." icon_state = "voice" - materials = list(MAT_METAL=500, MAT_GLASS=50) + materials = list(/datum/material/iron=500, /datum/material/glass=50) flags_1 = HEAR_1 attachable = TRUE verb_say = "beeps" diff --git a/code/modules/awaymissions/super_secret_room.dm b/code/modules/awaymissions/super_secret_room.dm index 5b0bf03fe5d0..412f7cf75d4f 100644 --- a/code/modules/awaymissions/super_secret_room.dm +++ b/code/modules/awaymissions/super_secret_room.dm @@ -121,7 +121,7 @@ icon = 'icons/obj/economy.dmi' icon_state = "rupee" w_class = WEIGHT_CLASS_SMALL - materials = list(MAT_GLASS = 500) + materials = list(/datum/material/glass = 500) /obj/item/rupee/Initialize() . = ..() diff --git a/code/modules/cargo/exports/materials.dm b/code/modules/cargo/exports/materials.dm index 04dc76fd52bc..4f478d3c6e8b 100644 --- a/code/modules/cargo/exports/materials.dm +++ b/code/modules/cargo/exports/materials.dm @@ -14,10 +14,10 @@ if(!isitem(O)) return 0 var/obj/item/I = O - if(!(material_id in I.materials)) + if(!(getmaterialref(material_id) in I.materials)) return 0 - var/amount = I.materials[material_id] + var/amount = I.materials[getmaterialref(material_id)] if(istype(I, /obj/item/stack)) var/obj/item/stack/S = I @@ -31,49 +31,49 @@ /datum/export/material/bananium cost = 1000 - material_id = MAT_BANANIUM + material_id = /datum/material/bananium message = "cm3 of bananium" /datum/export/material/diamond cost = 500 - material_id = MAT_DIAMOND + material_id = /datum/material/diamond message = "cm3 of diamonds" /datum/export/material/plasma cost = 200 k_elasticity = 0 - material_id = MAT_PLASMA + material_id = /datum/material/plasma message = "cm3 of plasma" /datum/export/material/uranium cost = 100 - material_id = MAT_URANIUM + material_id = /datum/material/uranium message = "cm3 of uranium" /datum/export/material/gold cost = 125 - material_id = MAT_GOLD + material_id = /datum/material/gold message = "cm3 of gold" /datum/export/material/silver cost = 50 - material_id = MAT_SILVER + material_id = /datum/material/silver message = "cm3 of silver" /datum/export/material/titanium cost = 125 - material_id = MAT_TITANIUM + material_id = /datum/material/titanium message = "cm3 of titanium" /datum/export/material/plastitanium cost = 325 // plasma + titanium costs - material_id = MAT_TITANIUM // code can only check for one material_id; plastitanium is half plasma, half titanium + material_id = /datum/material/titanium // code can only check for one material_id; plastitanium is half plasma, half titanium message = "cm3 of plastitanium" /datum/export/material/metal cost = 5 message = "cm3 of metal" - material_id = MAT_METAL + material_id = /datum/material/iron export_types = list( /obj/item/stack/sheet/metal, /obj/item/stack/tile/plasteel, /obj/item/stack/rods, /obj/item/stack/ore, /obj/item/coin) @@ -81,6 +81,6 @@ /datum/export/material/glass cost = 5 message = "cm3 of glass" - material_id = MAT_GLASS + material_id = /datum/material/glass export_types = list(/obj/item/stack/sheet/glass, /obj/item/stack/ore, /obj/item/shard) diff --git a/code/modules/clothing/glasses/_glasses.dm b/code/modules/clothing/glasses/_glasses.dm index d350d997da61..aaab9b505842 100644 --- a/code/modules/clothing/glasses/_glasses.dm +++ b/code/modules/clothing/glasses/_glasses.dm @@ -8,7 +8,7 @@ strip_delay = 20 equip_delay_other = 25 resistance_flags = NONE - materials = list(MAT_GLASS = 250) + materials = list(/datum/material/glass = 250) var/vision_flags = 0 var/darkness_view = 2//Base human is 2 var/invis_view = SEE_INVISIBLE_LIVING //admin only for now @@ -259,7 +259,7 @@ icon_state = "welding-g" item_state = "welding-g" actions_types = list(/datum/action/item_action/toggle) - materials = list(MAT_METAL = 250) + materials = list(/datum/material/iron = 250) flash_protect = 2 tint = 2 visor_vars_to_toggle = VISOR_FLASHPROTECT | VISOR_TINT diff --git a/code/modules/clothing/head/misc_special.dm b/code/modules/clothing/head/misc_special.dm index 91a073222ec7..416dea915b50 100644 --- a/code/modules/clothing/head/misc_special.dm +++ b/code/modules/clothing/head/misc_special.dm @@ -19,7 +19,7 @@ icon_state = "welding" flags_cover = HEADCOVERSEYES | HEADCOVERSMOUTH item_state = "welding" - materials = list(MAT_METAL=1750, MAT_GLASS=400) + materials = list(/datum/material/iron=1750, /datum/material/glass=400) flash_protect = 2 tint = 2 armor = list("melee" = 10, "bullet" = 0, "laser" = 0,"energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 100, "acid" = 60) @@ -336,4 +336,4 @@ desc = "You feel ashamed about what you had to do to get this hat" icon_state = "cowboy" item_state = "cowboy" - + diff --git a/code/modules/clothing/masks/gasmask.dm b/code/modules/clothing/masks/gasmask.dm index 4e4620d4c449..276ad282d1bb 100644 --- a/code/modules/clothing/masks/gasmask.dm +++ b/code/modules/clothing/masks/gasmask.dm @@ -17,7 +17,7 @@ name = "welding mask" desc = "A gas mask with built-in welding goggles and a face shield. Looks like a skull - clearly designed by a nerd." icon_state = "weldingmask" - materials = list(MAT_METAL=4000, MAT_GLASS=2000) + materials = list(/datum/material/iron=4000, /datum/material/glass=2000) flash_protect = 2 tint = 2 armor = list("melee" = 10, "bullet" = 0, "laser" = 0,"energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 100, "acid" = 55) diff --git a/code/modules/clothing/shoes/bananashoes.dm b/code/modules/clothing/shoes/bananashoes.dm index c4d06ea14c35..ffb7771d2fad 100644 --- a/code/modules/clothing/shoes/bananashoes.dm +++ b/code/modules/clothing/shoes/bananashoes.dm @@ -10,7 +10,7 @@ /obj/item/clothing/shoes/clown_shoes/banana_shoes/Initialize() . = ..() - AddComponent(/datum/component/material_container, list(MAT_BANANIUM), 200000, TRUE, /obj/item/stack) + AddComponent(/datum/component/material_container, list(/datum/material/bananium), 200000, TRUE, /obj/item/stack) AddComponent(/datum/component/squeak, list('sound/items/bikehorn.ogg'=1), 75) if(always_noslip) clothing_flags |= NOSLIP @@ -19,7 +19,7 @@ . = ..() var/datum/component/material_container/bananium = GetComponent(/datum/component/material_container) if(on) - if(bananium.amount(MAT_BANANIUM) < 100) + if(bananium.get_material_amount(/datum/material/bananium) < 100) on = !on if(!always_noslip) clothing_flags &= ~NOSLIP @@ -27,7 +27,7 @@ to_chat(loc, "You ran out of bananium!") else new /obj/item/grown/bananapeel/specialpeel(get_step(src,turn(usr.dir, 180))) //honk - bananium.use_amount_type(100, MAT_BANANIUM) + bananium.use_amount_mat(100, /datum/material/bananium) /obj/item/clothing/shoes/clown_shoes/banana_shoes/attack_self(mob/user) var/datum/component/material_container/bananium = GetComponent(/datum/component/material_container) @@ -43,7 +43,7 @@ /obj/item/clothing/shoes/clown_shoes/banana_shoes/ui_action_click(mob/user) var/datum/component/material_container/bananium = GetComponent(/datum/component/material_container) - if(bananium.amount(MAT_BANANIUM)) + if(bananium.get_material_amount(/datum/material/bananium)) on = !on update_icon() to_chat(user, "You [on ? "activate" : "deactivate"] the prototype shoes.") diff --git a/code/modules/clothing/under/accessories.dm b/code/modules/clothing/under/accessories.dm index 09d9f92e11da..ce411f11b2b3 100755 --- a/code/modules/clothing/under/accessories.dm +++ b/code/modules/clothing/under/accessories.dm @@ -112,7 +112,7 @@ desc = "A bronze medal." icon_state = "bronze" item_color = "bronze" - materials = list(MAT_METAL=1000) + materials = list(/datum/material/iron=1000) resistance_flags = FIRE_PROOF var/medaltype = "medal" //Sprite used for medalbox var/commended = FALSE @@ -183,7 +183,7 @@ icon_state = "silver" item_color = "silver" medaltype = "medal-silver" - materials = list(MAT_SILVER=1000) + materials = list(/datum/material/silver=1000) /obj/item/clothing/accessory/medal/silver/valor name = "medal of valor" @@ -203,7 +203,7 @@ icon_state = "gold" item_color = "gold" medaltype = "medal-gold" - materials = list(MAT_GOLD=1000) + materials = list(/datum/material/gold=1000) /obj/item/clothing/accessory/medal/gold/captain name = "medal of captaincy" @@ -221,7 +221,7 @@ item_color = "plasma" medaltype = "medal-plasma" armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = -10, "acid" = 0) //It's made of plasma. Of course it's flammable. - materials = list(MAT_PLASMA=1000) + materials = list(/datum/material/plasma=1000) /obj/item/clothing/accessory/medal/plasma/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume) if(exposed_temperature > 300) diff --git a/code/modules/food_and_drinks/drinks/drinks.dm b/code/modules/food_and_drinks/drinks/drinks.dm index 136ee7e1398f..6e539778bfde 100644 --- a/code/modules/food_and_drinks/drinks/drinks.dm +++ b/code/modules/food_and_drinks/drinks/drinks.dm @@ -145,7 +145,7 @@ force = 1 throwforce = 1 amount_per_transfer_from_this = 5 - materials = list(MAT_METAL=100) + materials = list(/datum/material/iron=100) possible_transfer_amounts = list() volume = 5 flags_1 = CONDUCT_1 @@ -161,7 +161,7 @@ force = 14 throwforce = 10 amount_per_transfer_from_this = 20 - materials = list(MAT_GOLD=1000) + materials = list(/datum/material/gold=1000) volume = 150 /obj/item/reagent_containers/food/drinks/trophy/silver_cup @@ -172,7 +172,7 @@ force = 10 throwforce = 8 amount_per_transfer_from_this = 15 - materials = list(MAT_SILVER=800) + materials = list(/datum/material/silver=800) volume = 100 @@ -184,7 +184,7 @@ force = 5 throwforce = 4 amount_per_transfer_from_this = 10 - materials = list(MAT_METAL=400) + materials = list(/datum/material/iron=400) volume = 25 ///////////////////////////////////////////////Drinks @@ -364,7 +364,7 @@ name = "shaker" desc = "A metal shaker to mix drinks in." icon_state = "shaker" - materials = list(MAT_METAL=1500) + materials = list(/datum/material/iron=1500) amount_per_transfer_from_this = 10 volume = 100 isGlass = FALSE @@ -374,7 +374,7 @@ desc = "Every good spaceman knows it's a good idea to bring along a couple of pints of whiskey wherever they go." custom_price = 30 icon_state = "flask" - materials = list(MAT_METAL=250) + materials = list(/datum/material/iron=250) volume = 60 isGlass = FALSE @@ -382,7 +382,7 @@ name = "captain's flask" desc = "A gold flask belonging to the captain." icon_state = "flask_gold" - materials = list(MAT_GOLD=500) + materials = list(/datum/material/gold=500) /obj/item/reagent_containers/food/drinks/flask/det name = "detective's flask" diff --git a/code/modules/food_and_drinks/drinks/drinks/drinkingglass.dm b/code/modules/food_and_drinks/drinks/drinks/drinkingglass.dm index c3b5739a7ce3..176bf61a40ef 100644 --- a/code/modules/food_and_drinks/drinks/drinks/drinkingglass.dm +++ b/code/modules/food_and_drinks/drinks/drinks/drinkingglass.dm @@ -7,7 +7,7 @@ icon_state = "glass_empty" amount_per_transfer_from_this = 10 volume = 50 - materials = list(MAT_GLASS=500) + materials = list(/datum/material/glass=500) max_integrity = 20 spillable = TRUE resistance_flags = ACID_PROOF @@ -47,7 +47,7 @@ amount_per_transfer_from_this = 15 possible_transfer_amounts = list() volume = 15 - materials = list(MAT_GLASS=100) + materials = list(/datum/material/glass=100) /obj/item/reagent_containers/food/drinks/drinkingglass/shotglass/on_reagent_change(changetype) cut_overlays() diff --git a/code/modules/food_and_drinks/food/customizables.dm b/code/modules/food_and_drinks/food/customizables.dm index 1bb0a125eb3d..8f5a48077e58 100644 --- a/code/modules/food_and_drinks/food/customizables.dm +++ b/code/modules/food_and_drinks/food/customizables.dm @@ -180,7 +180,7 @@ icon = 'icons/obj/food/piecake.dmi' icon_state = "plaincake" foodtype = GRAIN | DAIRY - + /obj/item/reagent_containers/food/snacks/customizable/cheesewheel/cheddar name = "cheese" ingredients_placement = INGREDIENTS_SCATTER @@ -300,7 +300,7 @@ icon = 'icons/obj/food/soupsalad.dmi' icon_state = "bowl" reagent_flags = OPENCONTAINER - materials = list(MAT_GLASS = 500) + materials = list(/datum/material/glass = 500) w_class = WEIGHT_CLASS_NORMAL /obj/item/reagent_containers/glass/bowl/attackby(obj/item/I,mob/user, params) diff --git a/code/modules/food_and_drinks/kitchen_machinery/microwave.dm b/code/modules/food_and_drinks/kitchen_machinery/microwave.dm index 438689b8d463..4e091556987f 100644 --- a/code/modules/food_and_drinks/kitchen_machinery/microwave.dm +++ b/code/modules/food_and_drinks/kitchen_machinery/microwave.dm @@ -309,8 +309,8 @@ var/metal = 0 for(var/obj/item/O in ingredients) O.microwave_act(src) - if(O.materials[MAT_METAL]) - metal += O.materials[MAT_METAL] + if(O.materials[/datum/material/iron]) + metal += O.materials[/datum/material/iron] if(metal) spark() diff --git a/code/modules/goals/department_goals/cargo.dm b/code/modules/goals/department_goals/cargo.dm index df6aed30d7ea..16dd4c41d451 100644 --- a/code/modules/goals/department_goals/cargo.dm +++ b/code/modules/goals/department_goals/cargo.dm @@ -13,8 +13,8 @@ /datum/department_goal/car/uranium/check_complete() var/obj/machinery/ore_silo/O = GLOB.ore_silo_default var/datum/component/material_container/materials = O.GetComponent(/datum/component/material_container) - return materials.can_use_amount(500*MINERAL_MATERIAL_AMOUNT, MAT_URANIUM) - + return materials.has_enough_of_material(/datum/material/uranium, MINERAL_MATERIAL_AMOUNT, 500) + // Setup a tesla in cargo /datum/department_goal/car/tesla name = "Create a tesla" diff --git a/code/modules/hydroponics/biogenerator.dm b/code/modules/hydroponics/biogenerator.dm index b3352f89dc53..61862bb43465 100644 --- a/code/modules/hydroponics/biogenerator.dm +++ b/code/modules/hydroponics/biogenerator.dm @@ -181,13 +181,13 @@ update_icon() /obj/machinery/biogenerator/proc/check_cost(list/materials, multiplier = 1, remove_points = TRUE) - if(materials.len != 1 || materials[1] != MAT_BIOMASS) + if(materials.len != 1 || materials[1] != getmaterialref(/datum/material/biomass)) return FALSE - if (materials[MAT_BIOMASS]*multiplier/efficiency > points) + if (materials[getmaterialref(/datum/material/biomass)]*multiplier/efficiency > points) return FALSE else if(remove_points) - points -= materials[MAT_BIOMASS]*multiplier/efficiency + points -= materials[getmaterialref(/datum/material/biomass)]*multiplier/efficiency update_icon() return TRUE @@ -290,7 +290,7 @@ cat["items"] += list(list( "id" = D.id, "name" = D.name, - "cost" = D.materials[MAT_BIOMASS]/efficiency, + "cost" = D.materials[getmaterialref(/datum/material/biomass)]/efficiency, )) data["categories"] += list(cat) diff --git a/code/modules/hydroponics/gene_modder.dm b/code/modules/hydroponics/gene_modder.dm index 743d7997a378..d2ad0bb3f7f3 100644 --- a/code/modules/hydroponics/gene_modder.dm +++ b/code/modules/hydroponics/gene_modder.dm @@ -422,7 +422,7 @@ name = "plant data disk" desc = "A disk for storing plant genetic data." icon_state = "datadisk_hydro" - materials = list(MAT_METAL=30, MAT_GLASS=10) + materials = list(/datum/material/iron=30, /datum/material/glass=10) var/datum/plant_gene/gene var/read_only = 0 //Well, it's still a floppy disk obj_flags = UNIQUE_RENAME diff --git a/code/modules/hydroponics/hydroitemdefines.dm b/code/modules/hydroponics/hydroitemdefines.dm index d43283c58145..37c5637d9314 100644 --- a/code/modules/hydroponics/hydroitemdefines.dm +++ b/code/modules/hydroponics/hydroitemdefines.dm @@ -9,7 +9,7 @@ righthand_file = 'icons/mob/inhands/equipment/tools_righthand.dmi' w_class = WEIGHT_CLASS_TINY slot_flags = ITEM_SLOT_BELT - materials = list(MAT_METAL=30, MAT_GLASS=20) + materials = list(/datum/material/iron=30, /datum/material/glass=20) // ************************************* // Hydroponics Tools @@ -57,7 +57,7 @@ force = 5 throwforce = 7 w_class = WEIGHT_CLASS_SMALL - materials = list(MAT_METAL=50) + materials = list(/datum/material/iron=50) attack_verb = list("slashed", "sliced", "cut", "clawed") hitsound = 'sound/weapons/bladeslice.ogg' @@ -90,7 +90,7 @@ throwforce = 15 throw_speed = 3 throw_range = 4 - materials = list(MAT_METAL = 15000) + materials = list(/datum/material/iron = 15000) attack_verb = list("chopped", "torn", "cut") hitsound = 'sound/weapons/bladeslice.ogg' sharpness = IS_SHARP diff --git a/code/modules/mining/equipment/kinetic_crusher.dm b/code/modules/mining/equipment/kinetic_crusher.dm index 61eee5a5e5e7..93cd20868868 100644 --- a/code/modules/mining/equipment/kinetic_crusher.dm +++ b/code/modules/mining/equipment/kinetic_crusher.dm @@ -19,7 +19,7 @@ light_range = 5 light_power = 1 armour_penetration = 10 - materials = list(MAT_METAL=1150, MAT_GLASS=2075) + materials = list(/datum/material/iron=1150, /datum/material/glass=2075) hitsound = 'sound/weapons/bladeslice.ogg' attack_verb = list("smashed", "crushed", "cleaved", "chopped", "pulped") sharpness = IS_SHARP diff --git a/code/modules/mining/equipment/mining_tools.dm b/code/modules/mining/equipment/mining_tools.dm index f998e6c837fe..7a1e9ad15be0 100644 --- a/code/modules/mining/equipment/mining_tools.dm +++ b/code/modules/mining/equipment/mining_tools.dm @@ -11,7 +11,7 @@ lefthand_file = 'icons/mob/inhands/equipment/mining_lefthand.dmi' righthand_file = 'icons/mob/inhands/equipment/mining_righthand.dmi' w_class = WEIGHT_CLASS_BULKY - materials = list(MAT_METAL=2000) //one sheet, but where can you make them? + materials = list(/datum/material/iron=2000) //one sheet, but where can you make them? tool_behaviour = TOOL_MINING toolspeed = 1 usesound = list('sound/effects/picaxe1.ogg', 'sound/effects/picaxe2.ogg', 'sound/effects/picaxe3.ogg') @@ -32,7 +32,7 @@ throwforce = 7 slot_flags = ITEM_SLOT_BELT w_class = WEIGHT_CLASS_NORMAL - materials = list(MAT_METAL=1000) + materials = list(/datum/material/iron=1000) /obj/item/pickaxe/silver name = "silver-plated pickaxe" @@ -106,7 +106,7 @@ throwforce = 4 item_state = "shovel" w_class = WEIGHT_CLASS_NORMAL - materials = list(MAT_METAL=50) + materials = list(/datum/material/iron=50) attack_verb = list("bashed", "bludgeoned", "thrashed", "whacked") sharpness = IS_SHARP diff --git a/code/modules/mining/lavaland/necropolis_chests.dm b/code/modules/mining/lavaland/necropolis_chests.dm index 43edf59f11bc..997e631bab84 100644 --- a/code/modules/mining/lavaland/necropolis_chests.dm +++ b/code/modules/mining/lavaland/necropolis_chests.dm @@ -109,28 +109,28 @@ name = "Kinetic Accelerator Offensive Mining Explosion Mod" desc = "A device which causes kinetic accelerators to fire AoE blasts that destroy rock and damage creatures." id = "hyperaoemod" - materials = list(MAT_METAL = 7000, MAT_GLASS = 3000, MAT_SILVER = 3000, MAT_GOLD = 3000, MAT_DIAMOND = 4000) + materials = list(/datum/material/iron = 7000, /datum/material/glass = 3000, /datum/material/silver = 3000, /datum/material/gold = 3000, /datum/material/diamond = 4000) build_path = /obj/item/borg/upgrade/modkit/aoe/turfs/andmobs /datum/design/unique_modkit/rapid_repeater name = "Kinetic Accelerator Rapid Repeater Mod" desc = "A device which greatly reduces a kinetic accelerator's cooldown on striking a living target or rock, but greatly increases its base cooldown." id = "repeatermod" - materials = list(MAT_METAL = 5000, MAT_GLASS = 5000, MAT_URANIUM = 8000, MAT_BLUESPACE = 2000) + materials = list(/datum/material/iron = 5000, /datum/material/glass = 5000, /datum/material/uranium = 8000, /datum/material/bluespace = 2000) build_path = /obj/item/borg/upgrade/modkit/cooldown/repeater /datum/design/unique_modkit/resonator_blast name = "Kinetic Accelerator Resonator Blast Mod" desc = "A device which causes kinetic accelerators to fire shots that leave and detonate resonator blasts." id = "resonatormod" - materials = list(MAT_METAL = 5000, MAT_GLASS = 5000, MAT_SILVER = 5000, MAT_URANIUM = 5000) + materials = list(/datum/material/iron = 5000, /datum/material/glass = 5000, /datum/material/silver = 5000, /datum/material/uranium = 5000) build_path = /obj/item/borg/upgrade/modkit/resonator_blasts /datum/design/unique_modkit/bounty name = "Kinetic Accelerator Death Syphon Mod" desc = "A device which causes kinetic accelerators to permanently gain damage against creature types killed with it." id = "bountymod" - materials = list(MAT_METAL = 4000, MAT_SILVER = 4000, MAT_GOLD = 4000, MAT_BLUESPACE = 4000) + materials = list(/datum/material/iron = 4000, /datum/material/silver = 4000, /datum/material/gold = 4000, /datum/material/bluespace = 4000) reagents_list = list(/datum/reagent/blood = 40) build_path = /obj/item/borg/upgrade/modkit/bounty @@ -1372,7 +1372,7 @@ /obj/item/hierophant_antenna name = "hierophant's antenna" - icon = 'icons/obj/lavaland/artefacts.dmi' + icon = 'icons/obj/lavaland/artefacts.dmi' icon_state = "hierophant_antenna" item_state = "hierophant_antenna" desc = "Extends the range of the herald's power." diff --git a/code/modules/mining/machine_processing.dm b/code/modules/mining/machine_processing.dm index 39f99bf1e316..609762cb2c83 100644 --- a/code/modules/mining/machine_processing.dm +++ b/code/modules/mining/machine_processing.dm @@ -49,8 +49,10 @@ add_fingerprint(usr) if(href_list["material"]) - machine.selected_material = href_list["material"] - machine.selected_alloy = null + var/datum/material/new_material = locate(href_list["material"]) + if(istype(new_material)) + machine.selected_material = new_material + machine.selected_alloy = null if(href_list["alloy"]) machine.selected_material = null @@ -77,14 +79,14 @@ density = TRUE var/obj/machinery/mineral/CONSOLE = null var/on = FALSE - var/selected_material = MAT_METAL + var/selected_material = /datum/material/iron var/selected_alloy = null var/datum/techweb/stored_research /obj/machinery/mineral/processing_unit/Initialize() . = ..() proximity_monitor = new(src, 1) - AddComponent(/datum/component/material_container, list(MAT_METAL, MAT_GLASS, MAT_SILVER, MAT_GOLD, MAT_DIAMOND, MAT_PLASMA, MAT_URANIUM, MAT_BANANIUM, MAT_TITANIUM, MAT_BLUESPACE), INFINITY, TRUE, /obj/item/stack) + AddComponent(/datum/component/material_container, list(/datum/material/iron, /datum/material/glass, /datum/material/silver, /datum/material/gold, /datum/material/diamond, /datum/material/plasma, /datum/material/uranium, /datum/material/bananium, /datum/material/titanium, /datum/material/bluespace), INFINITY, TRUE, /obj/item/stack) stored_research = new /datum/techweb/specialized/autounlocking/smelter /obj/machinery/mineral/processing_unit/Destroy() @@ -110,13 +112,13 @@ /obj/machinery/mineral/processing_unit/proc/get_machine_data() var/dat = "Smelter control console

" var/datum/component/material_container/materials = GetComponent(/datum/component/material_container) - for(var/mat_id in materials.materials) - var/datum/material/M = materials.materials[mat_id] - dat += "[M.name]: [M.amount] cm³" - if (selected_material == mat_id) + for(var/datum/material/M in materials.materials) + var/amount = materials.materials[M] + dat += "[M.name]: [amount] cm³" + if (selected_material == M) dat += " Smelting" else - dat += " Not Smelting " + dat += " Not Smelting " dat += "
" dat += "

" @@ -155,14 +157,14 @@ /obj/machinery/mineral/processing_unit/proc/smelt_ore() var/datum/component/material_container/materials = GetComponent(/datum/component/material_container) - var/datum/material/mat = materials.materials[selected_material] + var/datum/material/mat = selected_material if(mat) - var/sheets_to_remove = (mat.amount >= (MINERAL_MATERIAL_AMOUNT * SMELT_AMOUNT) ) ? SMELT_AMOUNT : round(mat.amount / MINERAL_MATERIAL_AMOUNT) + var/sheets_to_remove = (materials.materials[mat] >= (MINERAL_MATERIAL_AMOUNT * SMELT_AMOUNT) ) ? SMELT_AMOUNT : round(materials.materials[mat] / MINERAL_MATERIAL_AMOUNT) if(!sheets_to_remove) on = FALSE else var/out = get_step(src, output_dir) - materials.retrieve_sheets(sheets_to_remove, selected_material, out) + materials.retrieve_sheets(sheets_to_remove, mat, out) /obj/machinery/mineral/processing_unit/proc/smelt_alloy() @@ -178,7 +180,7 @@ return var/datum/component/material_container/materials = GetComponent(/datum/component/material_container) - materials.use_amount(alloy.materials, amount) + materials.use_materials(alloy.materials, amount) generate_mineral(alloy.build_path) @@ -190,14 +192,11 @@ var/datum/component/material_container/materials = GetComponent(/datum/component/material_container) - for(var/mat_id in D.materials) - var/M = D.materials[mat_id] - var/datum/material/smelter_mat = materials.materials[mat_id] + for(var/mat_cat in D.materials) + var/required_amount = D.materials[mat_cat] + var/amount = materials.materials[mat_cat] - if(!M || !smelter_mat) - return FALSE - - build_amount = min(build_amount, round(smelter_mat.amount / M)) + build_amount = min(build_amount, round(amount / required_amount)) return build_amount diff --git a/code/modules/mining/machine_redemption.dm b/code/modules/mining/machine_redemption.dm index 577972c6b058..462b7f996944 100644 --- a/code/modules/mining/machine_redemption.dm +++ b/code/modules/mining/machine_redemption.dm @@ -18,7 +18,7 @@ var/ore_pickup_rate = 15 var/sheet_per_ore = 1 var/point_upgrade = 1 - var/list/ore_values = list(MAT_GLASS = 1, MAT_METAL = 1, MAT_PLASMA = 15, MAT_SILVER = 16, MAT_GOLD = 18, MAT_TITANIUM = 30, MAT_URANIUM = 30, MAT_DIAMOND = 50, MAT_BLUESPACE = 50, MAT_BANANIUM = 60) + var/list/ore_values = list(/datum/material/glass = 1, /datum/material/iron = 1, /datum/material/plasma = 15, /datum/material/silver = 16, /datum/material/gold = 18, /datum/material/titanium = 30, /datum/material/uranium = 30, /datum/material/diamond = 50, /datum/material/bluespace = 50, /datum/material/bananium = 60) var/message_sent = FALSE var/list/ore_buffer = list() var/datum/techweb/stored_research @@ -46,7 +46,7 @@ point_upgrade_temp = 0.65 + (0.35 * L.rating) ore_pickup_rate = ore_pickup_rate_temp point_upgrade = point_upgrade_temp - sheet_per_ore = sheet_per_ore_temp + sheet_per_ore = round(sheet_per_ore_temp, 0.01) /obj/machinery/mineral/ore_redemption/examine(mob/user) . = ..() @@ -91,14 +91,14 @@ var/build_amount = 0 - for(var/mat_id in D.materials) - var/M = D.materials[mat_id] - var/datum/material/redemption_mat = mat_container.materials[mat_id] + for(var/mat in D.materials) + var/amount = D.materials[mat] + var/datum/material/redemption_mat_amount = mat_container.materials[mat] - if(!M || !redemption_mat) + if(!amount || !redemption_mat_amount) return FALSE - var/smeltable_sheets = FLOOR(redemption_mat.amount / M, 1) + var/smeltable_sheets = FLOOR(redemption_mat_amount / amount, 1) if(!smeltable_sheets) return FALSE @@ -128,9 +128,9 @@ var/has_minerals = FALSE - for(var/mat_id in mat_container.materials) - var/datum/material/M = mat_container.materials[mat_id] - var/mineral_amount = M.amount / MINERAL_MATERIAL_AMOUNT + for(var/mat in mat_container.materials) + var/datum/material/M = mat + var/mineral_amount = mat_container.materials[mat] / MINERAL_MATERIAL_AMOUNT if(mineral_amount) has_minerals = TRUE msg += "[capitalize(M.name)]: [mineral_amount] sheets
" @@ -213,10 +213,12 @@ data["materials"] = list() var/datum/component/material_container/mat_container = materials.mat_container if (mat_container) - for(var/mat_id in mat_container.materials) - var/datum/material/M = mat_container.materials[mat_id] - var/sheet_amount = M.amount ? M.amount / MINERAL_MATERIAL_AMOUNT : "0" - data["materials"] += list(list("name" = M.name, "id" = M.id, "amount" = sheet_amount, "value" = ore_values[M.id] * point_upgrade)) + for(var/mat in mat_container.materials) + var/datum/material/M = mat + var/amount = mat_container.materials[M] + var/sheet_amount = amount / MINERAL_MATERIAL_AMOUNT + var/ref = REF(M) + data["materials"] += list(list("name" = M.name, "id" = ref, "amount" = sheet_amount, "value" = ore_values[M.type])) data["alloys"] = list() for(var/v in stored_research.researched_designs) @@ -267,11 +269,11 @@ else if(!allowed(usr)) //check the user to_chat(usr, "Required access not found.") else - var/mat_id = params["id"] - if(!mat_container.materials[mat_id]) + var/datum/material/mat = locate(params["id"]) + var/amount = mat_container.materials[mat] + if(!amount) return - var/datum/material/mat = mat_container.materials[mat_id] - var/stored_amount = mat.amount / MINERAL_MATERIAL_AMOUNT + var/stored_amount = CEILING(amount / MINERAL_MATERIAL_AMOUNT, 0.1) if(!stored_amount) return @@ -283,9 +285,9 @@ desired = input("How many sheets?", "How many sheets would you like to smelt?", 1) as null|num var/sheets_to_remove = round(min(desired,50,stored_amount)) - var/count = mat_container.retrieve_sheets(sheets_to_remove, mat_id, get_step(src, output_dir)) + var/count = mat_container.retrieve_sheets(sheets_to_remove, mat, get_step(src, output_dir)) var/list/mats = list() - mats[mat_id] = MINERAL_MATERIAL_AMOUNT + mats[mat] = MINERAL_MATERIAL_AMOUNT materials.silo_log(src, "released", -count, "sheets", mats) return TRUE if("diskInsert") @@ -324,7 +326,7 @@ else desired = input("How many sheets?", "How many sheets would you like to smelt?", 1) as null|num var/amount = round(min(desired,50,smelt_amount)) - mat_container.use_amount(alloy.materials, amount) + mat_container.use_materials(alloy.materials, amount) materials.silo_log(src, "released", -amount, "sheets", alloy.materials) var/output if(ispath(alloy.build_path, /obj/item/stack/sheet)) diff --git a/code/modules/mining/machine_silo.dm b/code/modules/mining/machine_silo.dm index d7d32d7557ca..ad15872d5d74 100644 --- a/code/modules/mining/machine_silo.dm +++ b/code/modules/mining/machine_silo.dm @@ -16,7 +16,7 @@ GLOBAL_LIST_EMPTY(silo_access_logs) /obj/machinery/ore_silo/Initialize(mapload) . = ..() AddComponent(/datum/component/material_container, - list(MAT_METAL, MAT_GLASS, MAT_SILVER, MAT_GOLD, MAT_DIAMOND, MAT_PLASMA, MAT_URANIUM, MAT_BANANIUM, MAT_TITANIUM, MAT_BLUESPACE, MAT_PLASTIC), + list(/datum/material/iron, /datum/material/glass, /datum/material/silver, /datum/material/gold, /datum/material/diamond, /datum/material/plasma, /datum/material/uranium, /datum/material/bananium, /datum/material/titanium, /datum/material/bluespace, /datum/material/plastic), INFINITY, FALSE, /obj/item/stack, @@ -75,15 +75,17 @@ GLOBAL_LIST_EMPTY(silo_access_logs) var/list/ui = list("Ore Silo

Stored Material:

") var/any = FALSE for(var/M in materials.materials) - var/datum/material/mat = materials.materials[M] - var/sheets = round(mat.amount) / MINERAL_MATERIAL_AMOUNT + var/datum/material/mat = M + var/amount = materials.materials[M] + var/sheets = round(amount) / MINERAL_MATERIAL_AMOUNT + var/ref = REF(M) if (sheets) if (sheets >= 1) - ui += "Eject" + ui += "Eject" else ui += "Eject" if (sheets >= 20) - ui += "20x" + ui += "20x" else ui += "20x" ui += "[mat.name]: [sheets] sheets
" @@ -148,7 +150,7 @@ GLOBAL_LIST_EMPTY(silo_access_logs) updateUsrDialog() return TRUE else if(href_list["ejectsheet"]) - var/eject_sheet = href_list["ejectsheet"] + var/datum/material/eject_sheet = locate(href_list["ejectsheet"]) var/datum/component/material_container/materials = GetComponent(/datum/component/material_container) var/count = materials.retrieve_sheets(text2num(href_list["eject_amt"]), eject_sheet, drop_location()) var/list/matlist = list() @@ -222,13 +224,13 @@ GLOBAL_LIST_EMPTY(silo_access_logs) return TRUE /datum/ore_silo_log/proc/format() - name = "[machine_name]: [action] [amount]x [noun]" - - var/list/msg = list("([timestamp]) [machine_name] in [area_name]
[action] [abs(amount)]x [noun]
") - var/sep = "" - for(var/key in materials) - var/val = round(materials[key]) / MINERAL_MATERIAL_AMOUNT - msg += sep - sep = ", " - msg += "[amount < 0 ? "-" : "+"][val] [copytext(key, length(key[1]) + 1)]" - formatted = msg.Join() + name = "[machine_name]: [action] [amount]x [noun]" + var/list/msg = list("([timestamp]) [machine_name] in [area_name]
[action] [abs(amount)]x [noun]
") + var/sep = "" + for(var/key in materials) + var/datum/material/M = key + var/val = round(materials[key]) / MINERAL_MATERIAL_AMOUNT + msg += sep + sep = ", " + msg += "[amount < 0 ? "-" : "+"][val] [M.name]" + formatted = msg.Join() diff --git a/code/modules/mining/mint.dm b/code/modules/mining/mint.dm index c20c012df6cd..7a0eee868a1d 100644 --- a/code/modules/mining/mint.dm +++ b/code/modules/mining/mint.dm @@ -8,15 +8,15 @@ density = TRUE var/newCoins = 0 //how many coins the machine made in it's last load var/processing = FALSE - var/chosen = MAT_METAL //which material will be used to make coins + var/chosen = /datum/material/iron //which material will be used to make coins var/coinsToProduce = 10 speed_process = TRUE /obj/machinery/mineral/mint/Initialize() . = ..() - AddComponent(/datum/component/material_container, list(MAT_METAL, MAT_PLASMA, MAT_SILVER, MAT_GOLD, MAT_URANIUM, MAT_DIAMOND, MAT_BANANIUM), MINERAL_MATERIAL_AMOUNT * 50, FALSE, /obj/item/stack) - + AddComponent(/datum/component/material_container, list(/datum/material/iron, /datum/material/plasma, /datum/material/silver, /datum/material/gold, /datum/material/uranium, /datum/material/diamond, /datum/material/bananium), MINERAL_MATERIAL_AMOUNT * 50, FALSE, /obj/item/stack) + chosen = getmaterialref(chosen) /obj/machinery/mineral/mint/process() var/turf/T = get_step(src, input_dir) if(!T) @@ -33,17 +33,17 @@ var/dat = "Coin Press
" var/datum/component/material_container/materials = GetComponent(/datum/component/material_container) - for(var/mat_id in materials.materials) - var/datum/material/M = materials.materials[mat_id] - if(!M.amount && chosen != mat_id) + for(var/datum/material/M in materials.materials) + var/amount = materials.get_material_amount(M) + if(!amount && chosen != M) continue - dat += "
[M.name] amount: [M.amount] cm3 " - if (chosen == mat_id) + dat += "
[M.name] amount: [amount] cm3 " + if (chosen == M) dat += "Chosen" else - dat += "Choose" + dat += "Choose" - var/datum/material/M = materials.materials[chosen] + var/datum/material/M = chosen dat += "

Will produce [coinsToProduce] [lowertext(M.name)] coins if enough materials are available.
" dat += "-10 " @@ -67,8 +67,9 @@ return var/datum/component/material_container/materials = GetComponent(/datum/component/material_container) if(href_list["choose"]) - if(materials.materials[href_list["choose"]]) - chosen = href_list["choose"] + var/datum/material/new_material = locate(href_list["choose"]) + if(istype(new_material)) + chosen = new_material if(href_list["chooseAmt"]) coinsToProduce = clamp(coinsToProduce + text2num(href_list["chooseAmt"]), 0, 1000) if(href_list["makeCoins"]) @@ -76,12 +77,12 @@ processing = TRUE icon_state = "coinpress1" var/coin_mat = MINERAL_MATERIAL_AMOUNT * 0.2 - var/datum/material/M = materials.materials[chosen] + var/datum/material/M = chosen if(!M || !M.coin_type) updateUsrDialog() return - while(coinsToProduce > 0 && materials.use_amount_type(coin_mat, chosen)) + while(coinsToProduce > 0 && materials.use_amount_mat(coin_mat, chosen)) create_coins(M.coin_type) coinsToProduce-- newCoins++ diff --git a/code/modules/mining/ores_coins.dm b/code/modules/mining/ores_coins.dm index f52c5b0c2ed5..1b1bca916b40 100644 --- a/code/modules/mining/ores_coins.dm +++ b/code/modules/mining/ores_coins.dm @@ -69,7 +69,7 @@ item_state = "Uranium ore" singular_name = "uranium ore chunk" points = 30 - materials = list(MAT_URANIUM=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/uranium=MINERAL_MATERIAL_AMOUNT) refined_type = /obj/item/stack/sheet/mineral/uranium /obj/item/stack/ore/iron @@ -78,7 +78,7 @@ item_state = "Iron ore" singular_name = "iron ore chunk" points = 1 - materials = list(MAT_METAL=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/iron=MINERAL_MATERIAL_AMOUNT) refined_type = /obj/item/stack/sheet/metal /obj/item/stack/ore/glass @@ -87,7 +87,7 @@ item_state = "Glass ore" singular_name = "sand pile" points = 1 - materials = list(MAT_GLASS=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/glass=MINERAL_MATERIAL_AMOUNT) refined_type = /obj/item/stack/sheet/glass w_class = WEIGHT_CLASS_TINY @@ -129,7 +129,7 @@ GLOBAL_LIST_INIT(sand_recipes, list(\ item_state = "Plasma ore" singular_name = "plasma ore chunk" points = 15 - materials = list(MAT_PLASMA=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/plasma=MINERAL_MATERIAL_AMOUNT) refined_type = /obj/item/stack/sheet/mineral/plasma /obj/item/stack/ore/plasma/welder_act(mob/living/user, obj/item/I) @@ -143,7 +143,7 @@ GLOBAL_LIST_INIT(sand_recipes, list(\ item_state = "Silver ore" singular_name = "silver ore chunk" points = 16 - materials = list(MAT_SILVER=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/silver=MINERAL_MATERIAL_AMOUNT) refined_type = /obj/item/stack/sheet/mineral/silver /obj/item/stack/ore/gold @@ -152,7 +152,7 @@ GLOBAL_LIST_INIT(sand_recipes, list(\ icon_state = "Gold ore" singular_name = "gold ore chunk" points = 18 - materials = list(MAT_GOLD=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/gold=MINERAL_MATERIAL_AMOUNT) refined_type = /obj/item/stack/sheet/mineral/gold /obj/item/stack/ore/diamond @@ -161,7 +161,7 @@ GLOBAL_LIST_INIT(sand_recipes, list(\ item_state = "Diamond ore" singular_name = "diamond ore chunk" points = 50 - materials = list(MAT_DIAMOND=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/diamond=MINERAL_MATERIAL_AMOUNT) refined_type = /obj/item/stack/sheet/mineral/diamond /obj/item/stack/ore/bananium @@ -170,7 +170,7 @@ GLOBAL_LIST_INIT(sand_recipes, list(\ item_state = "Bananium ore" singular_name = "bananium ore chunk" points = 60 - materials = list(MAT_BANANIUM=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/bananium=MINERAL_MATERIAL_AMOUNT) refined_type = /obj/item/stack/sheet/mineral/bananium /obj/item/stack/ore/titanium @@ -179,7 +179,7 @@ GLOBAL_LIST_INIT(sand_recipes, list(\ item_state = "Titanium ore" singular_name = "titanium ore chunk" points = 50 - materials = list(MAT_TITANIUM=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/titanium=MINERAL_MATERIAL_AMOUNT) refined_type = /obj/item/stack/sheet/mineral/titanium /obj/item/stack/ore/slag @@ -351,7 +351,7 @@ GLOBAL_LIST_INIT(sand_recipes, list(\ cmineral = "gold" icon_state = "coin_gold_heads" value = 25 - materials = list(MAT_GOLD = MINERAL_MATERIAL_AMOUNT*0.2) + materials = list(/datum/material/gold = MINERAL_MATERIAL_AMOUNT*0.2) grind_results = list(/datum/reagent/gold = 4) /obj/item/coin/silver @@ -359,7 +359,7 @@ GLOBAL_LIST_INIT(sand_recipes, list(\ cmineral = "silver" icon_state = "coin_silver_heads" value = 10 - materials = list(MAT_SILVER = MINERAL_MATERIAL_AMOUNT*0.2) + materials = list(/datum/material/silver = MINERAL_MATERIAL_AMOUNT*0.2) grind_results = list(/datum/reagent/silver = 4) /obj/item/coin/diamond @@ -367,7 +367,7 @@ GLOBAL_LIST_INIT(sand_recipes, list(\ cmineral = "diamond" icon_state = "coin_diamond_heads" value = 100 - materials = list(MAT_DIAMOND = MINERAL_MATERIAL_AMOUNT*0.2) + materials = list(/datum/material/diamond = MINERAL_MATERIAL_AMOUNT*0.2) grind_results = list(/datum/reagent/carbon = 4) /obj/item/coin/iron @@ -375,7 +375,7 @@ GLOBAL_LIST_INIT(sand_recipes, list(\ cmineral = "iron" icon_state = "coin_iron_heads" value = 1 - materials = list(MAT_METAL = MINERAL_MATERIAL_AMOUNT*0.2) + materials = list(/datum/material/iron = MINERAL_MATERIAL_AMOUNT*0.2) grind_results = list(/datum/reagent/iron = 4) /obj/item/coin/plasma @@ -383,7 +383,7 @@ GLOBAL_LIST_INIT(sand_recipes, list(\ cmineral = "plasma" icon_state = "coin_plasma_heads" value = 40 - materials = list(MAT_PLASMA = MINERAL_MATERIAL_AMOUNT*0.2) + materials = list(/datum/material/plasma = MINERAL_MATERIAL_AMOUNT*0.2) grind_results = list(/datum/reagent/toxin/plasma = 4) /obj/item/coin/uranium @@ -391,7 +391,7 @@ GLOBAL_LIST_INIT(sand_recipes, list(\ cmineral = "uranium" icon_state = "coin_uranium_heads" value = 25 - materials = list(MAT_URANIUM = MINERAL_MATERIAL_AMOUNT*0.2) + materials = list(/datum/material/uranium = MINERAL_MATERIAL_AMOUNT*0.2) grind_results = list(/datum/reagent/uranium = 4) /obj/item/coin/bananium @@ -399,7 +399,7 @@ GLOBAL_LIST_INIT(sand_recipes, list(\ cmineral = "bananium" icon_state = "coin_bananium_heads" value = 200 //makes the clown cry - materials = list(MAT_BANANIUM = MINERAL_MATERIAL_AMOUNT*0.2) + materials = list(/datum/material/bananium = MINERAL_MATERIAL_AMOUNT*0.2) grind_results = list(/datum/reagent/consumable/banana = 4) /obj/item/coin/adamantine @@ -419,7 +419,7 @@ GLOBAL_LIST_INIT(sand_recipes, list(\ icon_state = "coin_iron_heads" desc = "Hey, this coin's the same on both sides!" sideslist = list("heads") - materials = list(MAT_METAL = MINERAL_MATERIAL_AMOUNT*0.2) + materials = list(/datum/material/iron = MINERAL_MATERIAL_AMOUNT*0.2) value = 1 grind_results = list(/datum/reagent/iron = 4) diff --git a/code/modules/mob/living/silicon/robot/robot_modules.dm b/code/modules/mob/living/silicon/robot/robot_modules.dm index f6c62958c00a..1d83a65ddfc9 100644 --- a/code/modules/mob/living/silicon/robot/robot_modules.dm +++ b/code/modules/mob/living/silicon/robot/robot_modules.dm @@ -90,8 +90,8 @@ var/obj/item/stack/S = I if(is_type_in_list(S, list(/obj/item/stack/sheet/metal, /obj/item/stack/rods, /obj/item/stack/tile/plasteel))) - if(S.materials[MAT_METAL]) - S.cost = S.materials[MAT_METAL] * 0.25 + if(S.materials[/datum/material/iron]) + S.cost = S.materials[/datum/material/iron] * 0.25 S.source = get_or_create_estorage(/datum/robot_energy_storage/metal) else if(istype(S, /obj/item/stack/sheet/glass)) @@ -238,7 +238,7 @@ /* check_menu: Checks if we are allowed to interact with a radial menu - + Arguments: user The mob interacting with a menu */ diff --git a/code/modules/paperwork/pen.dm b/code/modules/paperwork/pen.dm index 1a25408f3fc0..c5d4a55ea4e7 100644 --- a/code/modules/paperwork/pen.dm +++ b/code/modules/paperwork/pen.dm @@ -21,7 +21,7 @@ w_class = WEIGHT_CLASS_TINY throw_speed = 3 throw_range = 7 - materials = list(MAT_METAL=10) + materials = list(/datum/material/iron=10) pressure_resistance = 2 grind_results = list(/datum/reagent/iron = 2, /datum/reagent/iodine = 1) var/colour = "black" //what colour the ink is! @@ -79,7 +79,7 @@ throwforce = 5 throw_speed = 4 colour = "crimson" - materials = list(MAT_GOLD = 750) + materials = list(/datum/material/gold = 750) sharpness = IS_SHARP resistance_flags = FIRE_PROOF unique_reskin = list("Oak" = "pen-fountain-o", @@ -179,7 +179,7 @@ /obj/item/pen/edagger/Initialize() . = ..() AddComponent(/datum/component/butchering, 60, 100, 0, 'sound/weapons/blade1.ogg', TRUE) - + /obj/item/pen/edagger/suicide_act(mob/user) . = BRUTELOSS if(on) @@ -226,7 +226,7 @@ item_state = initial(item_state) lefthand_file = initial(lefthand_file) righthand_file = initial(righthand_file) - + /obj/item/pen/charcoal name = "charcoal stylus" desc = "It's just a wooden stick with some compressed ash on the end. At least it can write." diff --git a/code/modules/paperwork/stamps.dm b/code/modules/paperwork/stamps.dm index 8777b6122a40..21f28062b45a 100644 --- a/code/modules/paperwork/stamps.dm +++ b/code/modules/paperwork/stamps.dm @@ -8,7 +8,7 @@ w_class = WEIGHT_CLASS_TINY throw_speed = 3 throw_range = 7 - materials = list(MAT_METAL=60) + materials = list(/datum/material/iron=60) item_color = "cargo" pressure_resistance = 2 attack_verb = list("stamped") diff --git a/code/modules/photography/camera/camera.dm b/code/modules/photography/camera/camera.dm index a17a90fe4bd8..12c62cbaca55 100644 --- a/code/modules/photography/camera/camera.dm +++ b/code/modules/photography/camera/camera.dm @@ -13,7 +13,7 @@ w_class = WEIGHT_CLASS_SMALL flags_1 = CONDUCT_1 slot_flags = ITEM_SLOT_NECK - materials = list(MAT_METAL = 50, MAT_GLASS = 150) + materials = list(/datum/material/iron = 50, /datum/material/glass = 150) var/obj/item/disk/holodisk/disk var/pictures_left = 0 var/default_picture_name @@ -123,7 +123,7 @@ else . += "It has photos left." else - . += "It has [pictures_left] photos left." + . += "It has [pictures_left] photos left." if(photographer) . += "[src] lens is set for a [picture_size_x] by [picture_size_y] picture." . += "[src] is set to the [camera_mode] mode." diff --git a/code/modules/photography/camera/film.dm b/code/modules/photography/camera/film.dm index b1cd6bae66d0..799bdb3ba2b8 100644 --- a/code/modules/photography/camera/film.dm +++ b/code/modules/photography/camera/film.dm @@ -11,4 +11,4 @@ righthand_file = 'icons/mob/inhands/misc/devices_righthand.dmi' w_class = WEIGHT_CLASS_TINY resistance_flags = FLAMMABLE - materials = list(MAT_METAL = 10, MAT_GLASS = 10) + materials = list(/datum/material/iron = 10, /datum/material/glass = 10) diff --git a/code/modules/power/cable.dm b/code/modules/power/cable.dm index 52cf38ea9f35..55d88b79fd4f 100644 --- a/code/modules/power/cable.dm +++ b/code/modules/power/cable.dm @@ -484,7 +484,7 @@ GLOBAL_LIST_INIT(cable_coil_recipes, list (new/datum/stack_recipe("cable restrai w_class = WEIGHT_CLASS_SMALL throw_speed = 3 throw_range = 5 - materials = list(MAT_METAL=10, MAT_GLASS=5) + materials = list(/datum/material/iron=10, /datum/material/glass=5) flags_1 = CONDUCT_1 slot_flags = ITEM_SLOT_BELT attack_verb = list("whipped", "lashed", "disciplined", "flogged") diff --git a/code/modules/power/cell.dm b/code/modules/power/cell.dm index 2f4db393244b..bb96e4fb3211 100644 --- a/code/modules/power/cell.dm +++ b/code/modules/power/cell.dm @@ -13,7 +13,7 @@ w_class = WEIGHT_CLASS_SMALL var/charge = 0 // note %age conveted to actual charge in New var/maxcharge = 1000 - materials = list(MAT_METAL=700, MAT_GLASS=50) + materials = list(/datum/material/iron=700, /datum/material/glass=50) grind_results = list(/datum/reagent/lithium = 15, /datum/reagent/iron = 5, /datum/reagent/silicon = 5) var/rigged = FALSE // true if rigged to explode var/chargerate = 100 //how much power is given every tick in a recharger @@ -170,7 +170,7 @@ name = "\improper Nanotrasen brand rechargeable AA battery" desc = "You can't top the plasma top." //TOTALLY TRADEMARK INFRINGEMENT maxcharge = 500 - materials = list(MAT_GLASS=40) + materials = list(/datum/material/glass=40) /obj/item/stock_parts/cell/crap/empty/Initialize() . = ..() @@ -181,7 +181,7 @@ name = "upgraded power cell" desc = "A power cell with a slightly higher capacity than normal!" maxcharge = 2500 - materials = list(MAT_GLASS=50) + materials = list(/datum/material/glass=50) chargerate = 1000 /obj/item/stock_parts/cell/upgraded/plus @@ -192,7 +192,7 @@ /obj/item/stock_parts/cell/secborg name = "security borg rechargeable D battery" maxcharge = 600 //600 max charge / 100 charge per shot = six shots - materials = list(MAT_GLASS=40) + materials = list(/datum/material/glass=40) /obj/item/stock_parts/cell/secborg/empty/Initialize() . = ..() @@ -225,7 +225,7 @@ name = "high-capacity power cell" icon_state = "hcell" maxcharge = 10000 - materials = list(MAT_GLASS=60) + materials = list(/datum/material/glass=60) chargerate = 1500 /obj/item/stock_parts/cell/high/plus @@ -244,7 +244,7 @@ name = "super-capacity power cell" icon_state = "scell" maxcharge = 20000 - materials = list(MAT_GLASS=300) + materials = list(/datum/material/glass=300) chargerate = 2000 /obj/item/stock_parts/cell/super/empty/Initialize() @@ -256,7 +256,7 @@ name = "hyper-capacity power cell" icon_state = "hpcell" maxcharge = 30000 - materials = list(MAT_GLASS=400) + materials = list(/datum/material/glass=400) chargerate = 3000 /obj/item/stock_parts/cell/hyper/empty/Initialize() @@ -269,7 +269,7 @@ desc = "A rechargeable transdimensional power cell." icon_state = "bscell" maxcharge = 40000 - materials = list(MAT_GLASS=600) + materials = list(/datum/material/glass=600) chargerate = 4000 /obj/item/stock_parts/cell/bluespace/empty/Initialize() @@ -281,7 +281,7 @@ name = "infinite-capacity power cell!" icon_state = "icell" maxcharge = 30000 - materials = list(MAT_GLASS=1000) + materials = list(/datum/material/glass=1000) rating = 100 chargerate = 30000 @@ -356,7 +356,7 @@ name = "miniature power cell" desc = "A tiny power cell with a very low power capacity. Used in light fixtures to power them in the event of an outage." maxcharge = 120 //Emergency lights use 0.2 W per tick, meaning ~10 minutes of emergency power from a cell - materials = list(MAT_GLASS = 20) + materials = list(/datum/material/glass = 20) w_class = WEIGHT_CLASS_TINY /obj/item/stock_parts/cell/emergency_light/Initialize() diff --git a/code/modules/power/energyharvester.dm b/code/modules/power/energyharvester.dm index f8229d041df0..0d85ecd6b3fa 100644 --- a/code/modules/power/energyharvester.dm +++ b/code/modules/power/energyharvester.dm @@ -18,7 +18,7 @@ throwforce = 1 throw_speed = 1 throw_range = 1 - materials = list(MAT_METAL=750) + materials = list(/datum/material/iron=750) ///amount of power consumed by the harvester, incremented every tick and reset every budget cycle var/accumulated_power = 0 ///stores last REALTIMEOFDAY tick. SSEconomy runs off of that, don't see why this one shouldn't too diff --git a/code/modules/power/lighting.dm b/code/modules/power/lighting.dm index 5c9b640da163..71975d75ed15 100644 --- a/code/modules/power/lighting.dm +++ b/code/modules/power/lighting.dm @@ -24,7 +24,7 @@ name = "small light fixture frame" icon_state = "bulb-construct-item" result_path = /obj/structure/light_construct/small - materials = list(MAT_METAL=MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/iron=MINERAL_MATERIAL_AMOUNT) /obj/item/wallframe/light_fixture/try_build(turf/on_wall, user) if(!..()) @@ -120,7 +120,7 @@ else if (istype(W, /obj/item/light)) to_chat(user, "This [name] isn't finished being setup!") return - + switch(stage) if(1) if(W.tool_behaviour == TOOL_WRENCH) @@ -789,7 +789,7 @@ var/status = LIGHT_OK // LIGHT_OK, LIGHT_BURNED or LIGHT_BROKEN var/base_state var/switchcount = 0 // number of times switched - materials = list(MAT_GLASS=100) + materials = list(/datum/material/glass=100) grind_results = list(/datum/reagent/silicon = 5, /datum/reagent/nitrogen = 10) //Nitrogen is used as a cheaper alternative to argon in incandescent lighbulbs var/rigged = FALSE // true if rigged to explode var/brightness = 2 //how much light it gives off diff --git a/code/modules/projectiles/ammunition/_ammunition.dm b/code/modules/projectiles/ammunition/_ammunition.dm index 08018b402401..d1fed99d2b11 100644 --- a/code/modules/projectiles/ammunition/_ammunition.dm +++ b/code/modules/projectiles/ammunition/_ammunition.dm @@ -7,7 +7,7 @@ slot_flags = ITEM_SLOT_BELT throwforce = 0 w_class = WEIGHT_CLASS_TINY - materials = list(MAT_METAL = 500) + materials = list(/datum/material/iron = 500) var/fire_sound = null //What sound should play when this ammo is fired var/caliber = null //Which kind of guns it can be loaded into var/projectile_type = null //The bullet type to create when New() is called diff --git a/code/modules/projectiles/ammunition/ballistic/shotgun.dm b/code/modules/projectiles/ammunition/ballistic/shotgun.dm index 3c45fa25a43b..8c0f6034c7fe 100644 --- a/code/modules/projectiles/ammunition/ballistic/shotgun.dm +++ b/code/modules/projectiles/ammunition/ballistic/shotgun.dm @@ -6,14 +6,14 @@ icon_state = "blshell" caliber = "shotgun" projectile_type = /obj/item/projectile/bullet/shotgun_slug - materials = list(MAT_METAL=4000) + materials = list(/datum/material/iron=4000) /obj/item/ammo_casing/shotgun/beanbag name = "beanbag slug" desc = "A weak beanbag slug for riot control." icon_state = "bshell" projectile_type = /obj/item/projectile/bullet/shotgun_beanbag - materials = list(MAT_METAL=250) + materials = list(/datum/material/iron=250) /obj/item/ammo_casing/shotgun/incendiary name = "incendiary slug" @@ -34,7 +34,7 @@ desc = "A stunning taser slug." icon_state = "stunshell" projectile_type = /obj/item/projectile/bullet/shotgun_stunslug - materials = list(MAT_METAL=250) + materials = list(/datum/material/iron=250) /obj/item/ammo_casing/shotgun/meteorslug name = "meteorslug shell" @@ -71,14 +71,14 @@ projectile_type = /obj/item/projectile/bullet/pellet/shotgun_rubbershot pellets = 6 variance = 25 - materials = list(MAT_METAL=4000) + materials = list(/datum/material/iron=4000) /obj/item/ammo_casing/shotgun/improvised name = "improvised shell" desc = "An extremely weak shotgun shell with multiple small pellets made out of metal shards." icon_state = "improvshell" projectile_type = /obj/item/projectile/bullet/pellet/shotgun_improvised - materials = list(MAT_METAL=250) + materials = list(/datum/material/iron=250) pellets = 10 variance = 25 @@ -143,5 +143,5 @@ desc = "A 12 gauge anti-material slug. Great for breaching airlocks and windows with minimal shots. Only fits in tactical breaching shotguns." icon_state = "breacher" projectile_type = /obj/item/projectile/bullet/shotgun_breaching - materials = list(MAT_METAL=4000) + materials = list(/datum/material/iron=4000) caliber = "breaching" diff --git a/code/modules/projectiles/ammunition/caseless/foam.dm b/code/modules/projectiles/ammunition/caseless/foam.dm index 03dc17321889..0b192893dc2d 100644 --- a/code/modules/projectiles/ammunition/caseless/foam.dm +++ b/code/modules/projectiles/ammunition/caseless/foam.dm @@ -5,7 +5,7 @@ caliber = "foam_force" icon = 'icons/obj/guns/toy.dmi' icon_state = "foamdart" - materials = list(MAT_METAL = 11.25) + materials = list(/datum/material/iron = 11.25) harmful = FALSE var/modified = FALSE @@ -62,4 +62,4 @@ desc = "Whose smart idea was it to use toys as crowd control? Ages 18 and up." projectile_type = /obj/item/projectile/bullet/reusable/foam_dart/riot icon_state = "foamdart_riot" - materials = list(MAT_METAL = 1125) + materials = list(/datum/material/iron = 1125) diff --git a/code/modules/projectiles/boxes_magazines/_box_magazine.dm b/code/modules/projectiles/boxes_magazines/_box_magazine.dm index 630f94a26b08..492981197f25 100644 --- a/code/modules/projectiles/boxes_magazines/_box_magazine.dm +++ b/code/modules/projectiles/boxes_magazines/_box_magazine.dm @@ -8,7 +8,7 @@ item_state = "syringe_kit" lefthand_file = 'icons/mob/inhands/equipment/medical_lefthand.dmi' righthand_file = 'icons/mob/inhands/equipment/medical_righthand.dmi' - materials = list(MAT_METAL = 30000) + materials = list(/datum/material/iron = 30000) throwforce = 2 w_class = WEIGHT_CLASS_TINY throw_speed = 3 diff --git a/code/modules/projectiles/boxes_magazines/ammo_boxes.dm b/code/modules/projectiles/boxes_magazines/ammo_boxes.dm index f27528be8f9e..ec3283c2b941 100644 --- a/code/modules/projectiles/boxes_magazines/ammo_boxes.dm +++ b/code/modules/projectiles/boxes_magazines/ammo_boxes.dm @@ -13,7 +13,7 @@ ammo_type = /obj/item/ammo_casing/c38 max_ammo = 6 multiple_sprites = AMMO_BOX_PER_BULLET - materials = list(MAT_METAL = 20000) + materials = list(/datum/material/iron = 20000) /obj/item/ammo_box/c38/trac name = "speed loader (.38 TRAC)" @@ -75,9 +75,9 @@ icon_state = "foambox" ammo_type = /obj/item/ammo_casing/caseless/foam_dart max_ammo = 40 - materials = list(MAT_METAL = 500) + materials = list(/datum/material/iron = 500) /obj/item/ammo_box/foambox/riot icon_state = "foambox_riot" ammo_type = /obj/item/ammo_casing/caseless/foam_dart/riot - materials = list(MAT_METAL = 50000) + materials = list(/datum/material/iron = 50000) diff --git a/code/modules/projectiles/gun.dm b/code/modules/projectiles/gun.dm index dfe1869b52c7..ae532bc50211 100644 --- a/code/modules/projectiles/gun.dm +++ b/code/modules/projectiles/gun.dm @@ -10,7 +10,7 @@ flags_1 = CONDUCT_1 obj_flags = UNIQUE_RENAME slot_flags = ITEM_SLOT_BELT - materials = list(MAT_METAL=2000) + materials = list(/datum/material/iron=2000) w_class = WEIGHT_CLASS_NORMAL throwforce = 5 throw_speed = 3 @@ -304,7 +304,7 @@ /obj/item/gun/proc/process_fire(atom/target, mob/living/user, message = TRUE, params = null, zone_override = "", bonus_spread = 0) if(user) SEND_SIGNAL(user, COMSIG_MOB_FIRED_GUN, user, target, params, zone_override) - + add_fingerprint(user) if(semicd) diff --git a/code/modules/projectiles/guns/energy/kinetic_accelerator.dm b/code/modules/projectiles/guns/energy/kinetic_accelerator.dm index 4ba1ee95a5bb..bfa481074dcc 100644 --- a/code/modules/projectiles/guns/energy/kinetic_accelerator.dm +++ b/code/modules/projectiles/guns/energy/kinetic_accelerator.dm @@ -234,6 +234,7 @@ var/modifier = 1 //For use in any mod kit that has numerical modifiers var/minebot_upgrade = TRUE var/minebot_exclusive = FALSE + module_flags = BORG_MODULE_MINER /obj/item/borg/upgrade/modkit/examine(mob/user) . = ..() diff --git a/code/modules/projectiles/guns/energy/laser.dm b/code/modules/projectiles/guns/energy/laser.dm index 4d6e852c7714..e79349f23c40 100644 --- a/code/modules/projectiles/guns/energy/laser.dm +++ b/code/modules/projectiles/guns/energy/laser.dm @@ -4,7 +4,7 @@ icon_state = "laser" item_state = "laser" w_class = WEIGHT_CLASS_NORMAL - materials = list(MAT_METAL=2000) + materials = list(/datum/material/iron=2000) ammo_type = list(/obj/item/ammo_casing/energy/lasergun) ammo_x_offset = 1 shaded_charge = 1 @@ -140,7 +140,7 @@ /obj/item/gun/energy/laser/redtag/hitscan ammo_type = list(/obj/item/ammo_casing/energy/laser/redtag/hitscan) - + /obj/item/gun/energy/laser/makeshiftlasrifle name = "makeshift laser rifle" desc = "A makeshift rifle that shoots lasers. Lacks factory precision, but the screwable bulb allows modulating the photonic output." @@ -173,4 +173,4 @@ /obj/item/projectile/beam/laser/makeshiftlasrifle/weak name = "weak laser" - damage = 5 + damage = 5 diff --git a/code/modules/projectiles/guns/energy/special.dm b/code/modules/projectiles/guns/energy/special.dm index 10440568c213..e69300a1c197 100644 --- a/code/modules/projectiles/guns/energy/special.dm +++ b/code/modules/projectiles/guns/energy/special.dm @@ -89,7 +89,7 @@ icon_state = "crossbow" item_state = "crossbow" w_class = WEIGHT_CLASS_SMALL - materials = list(MAT_METAL=2000) + materials = list(/datum/material/iron=2000) suppressed = TRUE ammo_type = list(/obj/item/ammo_casing/energy/bolt) weapon_weight = WEAPON_LIGHT @@ -112,7 +112,7 @@ desc = "A reverse engineered weapon using syndicate technology." icon_state = "crossbowlarge" w_class = WEIGHT_CLASS_NORMAL - materials = list(MAT_METAL=4000) + materials = list(/datum/material/iron=4000) suppressed = null ammo_type = list(/obj/item/ammo_casing/energy/bolt/large) pin = null diff --git a/code/modules/projectiles/guns/misc/chem_gun.dm b/code/modules/projectiles/guns/misc/chem_gun.dm index 78b104964b5a..03101abe87cc 100644 --- a/code/modules/projectiles/guns/misc/chem_gun.dm +++ b/code/modules/projectiles/guns/misc/chem_gun.dm @@ -9,7 +9,7 @@ throw_speed = 3 throw_range = 7 force = 4 - materials = list(MAT_METAL=2000) + materials = list(/datum/material/iron=2000) clumsy_check = FALSE fire_sound = 'sound/items/syringeproj.ogg' var/time_per_syringe = 250 diff --git a/code/modules/projectiles/guns/misc/grenade_launcher.dm b/code/modules/projectiles/guns/misc/grenade_launcher.dm index 5a8c5a066e5c..1de003976683 100644 --- a/code/modules/projectiles/guns/misc/grenade_launcher.dm +++ b/code/modules/projectiles/guns/misc/grenade_launcher.dm @@ -10,7 +10,7 @@ force = 5 var/list/grenades = new/list() var/max_grenades = 3 - materials = list(MAT_METAL=2000) + materials = list(/datum/material/iron=2000) /obj/item/gun/grenadelauncher/examine(mob/user) . = ..() diff --git a/code/modules/projectiles/guns/misc/syringe_gun.dm b/code/modules/projectiles/guns/misc/syringe_gun.dm index dc96c253b8b6..89a78fe24752 100644 --- a/code/modules/projectiles/guns/misc/syringe_gun.dm +++ b/code/modules/projectiles/guns/misc/syringe_gun.dm @@ -7,7 +7,7 @@ throw_speed = 3 throw_range = 7 force = 4 - materials = list(MAT_METAL=2000) + materials = list(/datum/material/iron=2000) clumsy_check = 0 fire_sound = 'sound/items/syringeproj.ogg' var/list/syringes = list() diff --git a/code/modules/reagents/reagent_containers/glass.dm b/code/modules/reagents/reagent_containers/glass.dm index 6dfc7a967908..b8f6ab89610a 100755 --- a/code/modules/reagents/reagent_containers/glass.dm +++ b/code/modules/reagents/reagent_containers/glass.dm @@ -115,7 +115,7 @@ icon = 'icons/obj/chemical.dmi' icon_state = "beaker" item_state = "beaker" - materials = list(MAT_GLASS=500) + materials = list(/datum/material/glass=500) /obj/item/reagent_containers/glass/beaker/Initialize() . = ..() @@ -163,7 +163,7 @@ name = "large beaker" desc = "A large beaker. Can hold up to 100 units." icon_state = "beakerlarge" - materials = list(MAT_GLASS=2500) + materials = list(/datum/material/glass=2500) volume = 100 amount_per_transfer_from_this = 10 possible_transfer_amounts = list(5,10,15,20,25,30,50,100) @@ -172,7 +172,7 @@ name = "x-large beaker" desc = "An extra-large beaker. Can hold up to 120 units." icon_state = "beakerwhite" - materials = list(MAT_GLASS=2500, MAT_PLASTIC=3000) + materials = list(/datum/material/glass=2500, /datum/material/plastic=3000) volume = 120 amount_per_transfer_from_this = 10 possible_transfer_amounts = list(5,10,15,20,25,30,60,120) @@ -186,7 +186,7 @@ name = "metamaterial beaker" desc = "A large beaker. Can hold up to 180 units." icon_state = "beakergold" - materials = list(MAT_GLASS=2500, MAT_PLASTIC=3000, MAT_GOLD=1000, MAT_TITANIUM=1000) + materials = list(/datum/material/glass=2500, /datum/material/plastic=3000, /datum/material/gold=1000, /datum/material/titanium=1000) volume = 180 amount_per_transfer_from_this = 10 possible_transfer_amounts = list(5,10,15,20,25,30,60,120,180) @@ -196,7 +196,7 @@ desc = "A cryostasis beaker that allows for chemical storage without \ reactions. Can hold up to 50 units." icon_state = "beakernoreact" - materials = list(MAT_METAL=3000) + materials = list(/datum/material/iron=3000) reagent_flags = OPENCONTAINER | NO_REACT volume = 50 amount_per_transfer_from_this = 10 @@ -207,7 +207,7 @@ and Element Cuban combined with the Compound Pete. Can hold up to \ 300 units." icon_state = "beakerbluespace" - materials = list(MAT_GLASS = 5000, MAT_PLASMA = 3000, MAT_DIAMOND = 1000, MAT_BLUESPACE = 1000) + materials = list(/datum/material/glass = 5000, /datum/material/plasma = 3000, /datum/material/diamond = 1000, /datum/material/bluespace = 1000) volume = 300 amount_per_transfer_from_this = 10 possible_transfer_amounts = list(5,10,15,20,25,30,50,100,300) @@ -248,7 +248,7 @@ item_state = "bucket" lefthand_file = 'icons/mob/inhands/equipment/custodial_lefthand.dmi' righthand_file = 'icons/mob/inhands/equipment/custodial_righthand.dmi' - materials = list(MAT_METAL=200) + materials = list(/datum/material/iron=200) w_class = WEIGHT_CLASS_NORMAL amount_per_transfer_from_this = 20 possible_transfer_amounts = list(5,10,15,20,25,30,50,70) @@ -321,7 +321,7 @@ icon_state = "smallbottle" item_state = "bottle" list_reagents = list(/datum/reagent/water = 49.5, /datum/reagent/fluorine = 0.5)//see desc, don't think about it too hard - materials = list(MAT_GLASS=0) + materials = list(/datum/material/glass=0) volume = 50 amount_per_transfer_from_this = 10 @@ -331,7 +331,7 @@ /obj/item/reagent_containers/glass/beaker/waterbottle/large desc = "A fresh commercial-sized bottle of water." icon_state = "largebottle" - materials = list(MAT_GLASS=0) + materials = list(/datum/material/glass=0) list_reagents = list(/datum/reagent/water = 100) volume = 100 amount_per_transfer_from_this = 20 @@ -414,7 +414,7 @@ resistance_flags = NONE possible_transfer_amounts = list(10, 25, 50, 100) volume = 100 - materials = list(MAT_METAL=1000) + materials = list(/datum/material/iron=1000) /obj/item/reagent_containers/glass/mixbowl/on_reagent_change(changetype) ..() @@ -452,7 +452,7 @@ amount_per_transfer_from_this = 30 // Not very good at accurate reagent transfer and shouldn't be used for such possible_transfer_amounts = list(30) volume = 30 - materials = list(MAT_METAL=0) // No free mats for you, chap + materials = list(/datum/material/iron=0) // No free mats for you, chap var/spilled = FALSE // Is it currently spilled? var/locked = FALSE // Is it currently locked shut? diff --git a/code/modules/reagents/reagent_containers/syringes.dm b/code/modules/reagents/reagent_containers/syringes.dm index f2ac83a76322..b88433b5bbe1 100644 --- a/code/modules/reagents/reagent_containers/syringes.dm +++ b/code/modules/reagents/reagent_containers/syringes.dm @@ -12,7 +12,7 @@ var/mode = SYRINGE_DRAW var/busy = FALSE // needed for delayed drawing of blood var/proj_piercing = 0 //does it pierce through thick clothes when shot with syringe gun - materials = list(MAT_METAL=10, MAT_GLASS=20) + materials = list(/datum/material/iron=10, /datum/material/glass=20) reagent_flags = TRANSPARENT /obj/item/reagent_containers/syringe/Initialize() @@ -152,7 +152,7 @@ for(var/datum/symptom/S in DD.symptoms) viruslist += "[S.name] " viruslist += "\]" - + if(viruslist) investigate_log("[user.real_name] ([user.ckey]) injected [L.real_name] ([L.ckey]) with [viruslist]", INVESTIGATE_VIROLOGY) log_game("[user.real_name] ([user.ckey]) injected [L.real_name] ([L.ckey]) with [viruslist]") @@ -260,7 +260,7 @@ amount_per_transfer_from_this = 1 volume = 1 list_reagents = list(/datum/reagent/gluttonytoxin = 1) - + /obj/item/reagent_containers/syringe/ghost name = "Spectral Curse" desc = "A syringe recovered from a dreaded place. It probably isn't wise to use." diff --git a/code/modules/recycling/conveyor2.dm b/code/modules/recycling/conveyor2.dm index 15f54fc81615..67011529344a 100644 --- a/code/modules/recycling/conveyor2.dm +++ b/code/modules/recycling/conveyor2.dm @@ -397,7 +397,7 @@ GLOBAL_LIST_EMPTY(conveyors_by_id) max_amount = 30 singular_name = "conveyor belt" w_class = WEIGHT_CLASS_BULKY - materials = list(MAT_METAL = 3000) + materials = list(/datum/material/iron = 3000) ///id for linking var/id = "" @@ -437,4 +437,4 @@ GLOBAL_LIST_EMPTY(conveyors_by_id) /obj/item/paper/guides/conveyor name = "paper- 'Nano-it-up U-build series, #9: Build your very own conveyor belt, in SPACE'" info = "

Congratulations!

You are now the proud owner of the best conveyor set available for space mail order! We at Nano-it-up know you love to prepare your own structures without wasting time, so we have devised a special streamlined assembly procedure that puts all other mail-order products to shame!

Firstly, you need to link the conveyor switch assembly to each of the conveyor belt assemblies. After doing so, you simply need to install the belt assemblies onto the floor, et voila, belt built. Our special Nano-it-up smart switch will detected any linked assemblies as far as the eye can see! This convenience, you can only have it when you Nano-it-up. Stay nano!

" -#undef MAX_CONVEYOR_ITEMS_MOVE +#undef MAX_CONVEYOR_ITEMS_MOVE diff --git a/code/modules/research/designs.dm b/code/modules/research/designs.dm index 312136a366c5..db63feccab3a 100644 --- a/code/modules/research/designs.dm +++ b/code/modules/research/designs.dm @@ -7,15 +7,6 @@ For the materials datum, it assumes you need reagents unless specified otherwise you use one of the material IDs below. These are NOT ids in the usual sense (they aren't defined in the object or part of a datum), they are simply references used as part of a "has materials?" type proc. They all start with a $ to denote that they aren't reagents. The currently supporting non-reagent materials. All material amounts are set as the define MINERAL_MATERIAL_AMOUNT, which defaults to 2000 -- MAT_METAL (/obj/item/stack/metal). -- MAT_GLASS (/obj/item/stack/glass). -- MAT_PLASMA (/obj/item/stack/plasma). -- MAT_SILVER (/obj/item/stack/silver). -- MAT_GOLD (/obj/item/stack/gold). -- MAT_URANIUM (/obj/item/stack/uranium). -- MAT_DIAMOND (/obj/item/stack/diamond). -- MAT_BANANIUM (/obj/item/stack/bananium). -(Insert new ones here) Don't add new keyword/IDs if they are made from an existing one (such as rods which are made from metal). Only add raw materials. @@ -48,6 +39,8 @@ other types of metals and chemistry for reagents). var/research_icon //Replaces the item icon in the research console var/research_icon_state var/icon_cache + /// Optional string that interfaces can use as part of search filters. See- item/borg/upgrade/ai and the Exosuit Fabs. + var/search_metadata /datum/design/error_design name = "ERROR" @@ -57,6 +50,19 @@ other types of metals and chemistry for reagents). SSresearch.techweb_designs -= id return ..() +/datum/design/proc/InitializeMaterials() + var/list/temp_list = list() + for(var/i in materials) //Go through all of our materials, get the subsystem instance, and then replace the list. + var/amount = materials[i] + if(!istext(i)) //Not a category, so get the ref the normal way + var/datum/material/M = getmaterialref(i) + temp_list[M] = amount + else + temp_list[i] = amount + materials = temp_list + for(var/i in materials) + to_chat("[i] [materials[i]]") + /datum/design/proc/icon_html(client/user) var/datum/asset/spritesheet/sheet = get_asset_datum(/datum/asset/spritesheet/research_designs) sheet.send(user) @@ -70,7 +76,7 @@ other types of metals and chemistry for reagents). name = "Component Design Disk" desc = "A disk for storing device design data for construction in lathes." icon_state = "datadisk1" - materials = list(MAT_METAL=300, MAT_GLASS=100) + materials = list(/datum/material/iron=300, /datum/material/glass=100) var/list/blueprints = list() var/max_blueprints = 1 @@ -84,5 +90,5 @@ other types of metals and chemistry for reagents). /obj/item/disk/design_disk/adv name = "Advanced Component Design Disk" desc = "A disk for storing device design data for construction in lathes. This one has extra storage space." - materials = list(MAT_METAL=300, MAT_GLASS=100, MAT_SILVER = 50) + materials = list(/datum/material/iron=300, /datum/material/glass=100, /datum/material/silver = 50) max_blueprints = 5 diff --git a/code/modules/research/designs/AI_module_designs.dm b/code/modules/research/designs/AI_module_designs.dm index 44ee33d402a3..1d9de7f6975a 100644 --- a/code/modules/research/designs/AI_module_designs.dm +++ b/code/modules/research/designs/AI_module_designs.dm @@ -14,7 +14,7 @@ name = "Module Design (Safeguard)" desc = "Allows for the construction of a Safeguard AI Module." id = "safeguard_module" - materials = list(MAT_GLASS = 1000, MAT_GOLD = 2000) + materials = list(/datum/material/glass = 1000, /datum/material/gold = 2000) build_path = /obj/item/aiModule/supplied/safeguard category = list("AI Modules") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -23,7 +23,7 @@ name = "Module Design (OneHuman)" desc = "Allows for the construction of a OneHuman AI Module." id = "onehuman_module" - materials = list(MAT_GLASS = 1000, MAT_DIAMOND = 6000) + materials = list(/datum/material/glass = 1000, /datum/material/diamond = 6000) build_path = /obj/item/aiModule/zeroth/oneHuman category = list("AI Modules") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -32,7 +32,7 @@ name = "Module Design (ProtectStation)" desc = "Allows for the construction of a ProtectStation AI Module." id = "protectstation_module" - materials = list(MAT_GLASS = 1000, MAT_GOLD = 2000) + materials = list(/datum/material/glass = 1000, /datum/material/gold = 2000) build_path = /obj/item/aiModule/supplied/protectStation category = list("AI Modules") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -41,7 +41,7 @@ name = "Module Design (Quarantine)" desc = "Allows for the construction of a Quarantine AI Module." id = "quarantine_module" - materials = list(MAT_GLASS = 1000, MAT_GOLD = 2000) + materials = list(/datum/material/glass = 1000, /datum/material/gold = 2000) build_path = /obj/item/aiModule/supplied/quarantine category = list("AI Modules") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -50,7 +50,7 @@ name = "Module Design (OxygenIsToxicToHumans)" desc = "Allows for the construction of a Safeguard AI Module." id = "oxygen_module" - materials = list(MAT_GLASS = 1000, MAT_GOLD = 2000) + materials = list(/datum/material/glass = 1000, /datum/material/gold = 2000) build_path = /obj/item/aiModule/supplied/oxygen category = list("AI Modules") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -59,7 +59,7 @@ name = "Module Design (Freeform)" desc = "Allows for the construction of a Freeform AI Module." id = "freeform_module" - materials = list(MAT_GLASS = 1000, MAT_GOLD = 10000)//Custom inputs should be more expensive to get + materials = list(/datum/material/glass = 1000, /datum/material/gold = 10000)//Custom inputs should be more expensive to get build_path = /obj/item/aiModule/supplied/freeform category = list("AI Modules") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -68,7 +68,7 @@ name = "Module Design (Reset)" desc = "Allows for the construction of a Reset AI Module." id = "reset_module" - materials = list(MAT_GLASS = 1000, MAT_GOLD = 2000) + materials = list(/datum/material/glass = 1000, /datum/material/gold = 2000) build_path = /obj/item/aiModule/reset category = list("AI Modules") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -77,7 +77,7 @@ name = "Module Design (Purge)" desc = "Allows for the construction of a Purge AI Module." id = "purge_module" - materials = list(MAT_GLASS = 1000, MAT_DIAMOND = 2000) + materials = list(/datum/material/glass = 1000, /datum/material/diamond = 2000) build_path = /obj/item/aiModule/reset/purge category = list("AI Modules") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -86,7 +86,7 @@ name = "Module Design (Law Removal)" desc = "Allows for the construction of a Law Removal AI Core Module." id = "remove_module" - materials = list(MAT_GLASS = 1000, MAT_DIAMOND = 2000) + materials = list(/datum/material/glass = 1000, /datum/material/diamond = 2000) build_path = /obj/item/aiModule/remove category = list("AI Modules") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -95,7 +95,7 @@ name = "AI Core Module (Freeform)" desc = "Allows for the construction of a Freeform AI Core Module." id = "freeformcore_module" - materials = list(MAT_GLASS = 1000, MAT_DIAMOND = 10000)//Ditto + materials = list(/datum/material/glass = 1000, /datum/material/diamond = 10000)//Ditto build_path = /obj/item/aiModule/core/freeformcore category = list("AI Modules") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -104,7 +104,7 @@ name = "Core Module Design (Asimov)" desc = "Allows for the construction of an Asimov AI Core Module." id = "asimov_module" - materials = list(MAT_GLASS = 1000, MAT_DIAMOND = 2000) + materials = list(/datum/material/glass = 1000, /datum/material/diamond = 2000) build_path = /obj/item/aiModule/core/full/asimov category = list("AI Modules") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -113,7 +113,7 @@ name = "Core Module Design (Crewsimov)" desc = "Allows for the construction of a Crewsimov AI Core Module." id = "crewsimov_module" - materials = list(MAT_GLASS = 1000, MAT_DIAMOND = 2000) + materials = list(/datum/material/glass = 1000, /datum/material/diamond = 2000) build_path = /obj/item/aiModule/core/full/crewsimov category = list("AI Modules") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -123,7 +123,7 @@ desc = "Allows for the construction of a P.A.L.A.D.I.N. AI Core Module." id = "paladin_module" build_type = IMPRINTER - materials = list(MAT_GLASS = 1000, MAT_DIAMOND = 2000) + materials = list(/datum/material/glass = 1000, /datum/material/diamond = 2000) build_path = /obj/item/aiModule/core/full/paladin category = list("AI Modules") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -132,7 +132,7 @@ name = "Core Module Design (T.Y.R.A.N.T.)" desc = "Allows for the construction of a T.Y.R.A.N.T. AI Module." id = "tyrant_module" - materials = list(MAT_GLASS = 1000, MAT_DIAMOND = 2000) + materials = list(/datum/material/glass = 1000, /datum/material/diamond = 2000) build_path = /obj/item/aiModule/core/full/tyrant category = list("AI Modules") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -141,7 +141,7 @@ name = "Core Module Design (Overlord)" desc = "Allows for the construction of an Overlord AI Module." id = "overlord_module" - materials = list(MAT_GLASS = 1000, MAT_DIAMOND = 2000) + materials = list(/datum/material/glass = 1000, /datum/material/diamond = 2000) build_path = /obj/item/aiModule/core/full/overlord category = list("AI Modules") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -150,7 +150,7 @@ name = "Core Module Design (CEO)" desc = "Allows for the construction of a CEO AI Core Module." id = "ceo_module" - materials = list(MAT_GLASS = 1000, MAT_DIAMOND = 2000) + materials = list(/datum/material/glass = 1000, /datum/material/diamond = 2000) build_path = /obj/item/aiModule/core/full/ceo category = list("AI Modules") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -159,7 +159,7 @@ name = "Core Module Design (Default)" desc = "Allows for the construction of a Default AI Core Module." id = "default_module" - materials = list(MAT_GLASS = 1000, MAT_DIAMOND = 2000) + materials = list(/datum/material/glass = 1000, /datum/material/diamond = 2000) build_path = /obj/item/aiModule/core/full/custom category = list("AI Modules") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -168,7 +168,7 @@ name = "Core Module Design (Cowboy)" desc = "Allows for the construction of a Cowboy AI Core Module." id = "cowboy_module" - materials = list(MAT_GLASS = 1000, MAT_DIAMOND = 2000) + materials = list(/datum/material/glass = 1000, /datum/material/diamond = 2000) build_path = /obj/item/aiModule/core/full/cowboy category = list("AI Modules") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE diff --git a/code/modules/research/designs/autolathe_designs.dm b/code/modules/research/designs/autolathe_designs.dm index 5880ba80bb0b..11b816d34548 100644 --- a/code/modules/research/designs/autolathe_designs.dm +++ b/code/modules/research/designs/autolathe_designs.dm @@ -6,7 +6,7 @@ name = "Airlock scanner" id = "airlock_scanner" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 50, MAT_GLASS = 50) + materials = list(/datum/material/iron = 50, /datum/material/glass = 50) build_path = /obj/item/airlock_scanner category = list("initial","Tools","Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -15,7 +15,7 @@ name = "Bucket" id = "bucket" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 1000) + materials = list(/datum/material/iron = 1000) build_path = /obj/item/reagent_containers/glass/bucket category = list("initial","Tools","Service") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -24,7 +24,7 @@ name = "Mop" id = "mop" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 1000) + materials = list(/datum/material/iron = 1000) build_path = /obj/item/mop category = list("initial","Tools","Service") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -33,7 +33,7 @@ name = "Pocket Crowbar" id = "crowbar" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 50) + materials = list(/datum/material/iron = 50) build_path = /obj/item/crowbar category = list("initial","Tools","Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING | DEPARTMENTAL_FLAG_SCIENCE @@ -42,7 +42,7 @@ name = "Flashlight" id = "flashlight" build_type = AUTOLATHE - materials = list(MAT_METAL = 50, MAT_GLASS = 20) + materials = list(/datum/material/iron = 50, /datum/material/glass = 20) build_path = /obj/item/flashlight category = list("initial","Tools") @@ -50,7 +50,7 @@ name = "Fire Extinguisher" id = "extinguisher" build_type = AUTOLATHE - materials = list(MAT_METAL = 90) + materials = list(/datum/material/iron = 90) build_path = /obj/item/extinguisher category = list("initial","Tools") @@ -58,7 +58,7 @@ name = "Pocket Fire Extinguisher" id = "pocketfireextinguisher" build_type = AUTOLATHE - materials = list(MAT_METAL = 50, MAT_GLASS = 40) + materials = list(/datum/material/iron = 50, /datum/material/glass = 40) build_path = /obj/item/extinguisher/mini category = list("initial","Tools") @@ -66,7 +66,7 @@ name = "Multitool" id = "multitool" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 50, MAT_GLASS = 20) + materials = list(/datum/material/iron = 50, /datum/material/glass = 20) build_path = /obj/item/multitool category = list("initial","Tools","Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING | DEPARTMENTAL_FLAG_SCIENCE @@ -75,7 +75,7 @@ name = "Analyzer" id = "analyzer" build_type = AUTOLATHE - materials = list(MAT_METAL = 30, MAT_GLASS = 20) + materials = list(/datum/material/iron = 30, /datum/material/glass = 20) build_path = /obj/item/analyzer category = list("initial","Tools","Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -84,7 +84,7 @@ name = "T-Ray Scanner" id = "tscanner" build_type = AUTOLATHE - materials = list(MAT_METAL = 150) + materials = list(/datum/material/iron = 150) build_path = /obj/item/t_scanner category = list("initial","Tools","Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -93,7 +93,7 @@ name = "Welding Tool" id = "welding_tool" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 70, MAT_GLASS = 20) + materials = list(/datum/material/iron = 70, /datum/material/glass = 20) build_path = /obj/item/weldingtool category = list("initial","Tools","Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING | DEPARTMENTAL_FLAG_SCIENCE @@ -102,7 +102,7 @@ name = "Emergency Welding Tool" id = "mini_welding_tool" build_type = AUTOLATHE - materials = list(MAT_METAL = 30, MAT_GLASS = 10) + materials = list(/datum/material/iron = 30, /datum/material/glass = 10) build_path = /obj/item/weldingtool/mini category = list("initial","Tools") @@ -110,7 +110,7 @@ name = "Screwdriver" id = "screwdriver" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 75) + materials = list(/datum/material/iron = 75) build_path = /obj/item/screwdriver category = list("initial","Tools","Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING | DEPARTMENTAL_FLAG_SCIENCE @@ -119,7 +119,7 @@ name = "Wirecutters" id = "wirecutters" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 80) + materials = list(/datum/material/iron = 80) build_path = /obj/item/wirecutters category = list("initial","Tools","Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING | DEPARTMENTAL_FLAG_SCIENCE @@ -128,7 +128,7 @@ name = "Wrench" id = "wrench" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 150) + materials = list(/datum/material/iron = 150) build_path = /obj/item/wrench category = list("initial","Tools","Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING | DEPARTMENTAL_FLAG_SCIENCE @@ -137,7 +137,7 @@ name = "Welding Helmet" id = "welding_helmet" build_type = AUTOLATHE - materials = list(MAT_METAL = 1750, MAT_GLASS = 400) + materials = list(/datum/material/iron = 1750, /datum/material/glass = 400) build_path = /obj/item/clothing/head/welding category = list("initial","Tools") @@ -145,7 +145,7 @@ name = "Cable Coil" id = "cable_coil" build_type = AUTOLATHE - materials = list(MAT_METAL = 10, MAT_GLASS = 5) + materials = list(/datum/material/iron = 10, /datum/material/glass = 5) build_path = /obj/item/stack/cable_coil/random category = list("initial","Tools","Tool Designs") maxstack = MAXCOIL @@ -155,7 +155,7 @@ name = "Toolbox" id = "tool_box" build_type = AUTOLATHE - materials = list(MAT_METAL = 500) + materials = list(/datum/material/iron = 500) build_path = /obj/item/storage/toolbox category = list("initial","Tools") @@ -163,7 +163,7 @@ name = "APC Module" id = "power control" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 100, MAT_GLASS = 100) + materials = list(/datum/material/iron = 100, /datum/material/glass = 100) build_path = /obj/item/electronics/apc category = list("initial", "Electronics") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -172,7 +172,7 @@ name = "Airlock Electronics" id = "airlock_board" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 50, MAT_GLASS = 50) + materials = list(/datum/material/iron = 50, /datum/material/glass = 50) build_path = /obj/item/electronics/airlock category = list("initial", "Electronics") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -181,7 +181,7 @@ name = "Firelock Circuitry" id = "firelock_board" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 50, MAT_GLASS = 50) + materials = list(/datum/material/iron = 50, /datum/material/glass = 50) build_path = /obj/item/electronics/firelock category = list("initial", "Electronics") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -190,7 +190,7 @@ name = "Air Alarm Electronics" id = "airalarm_electronics" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 50, MAT_GLASS = 50) + materials = list(/datum/material/iron = 50, /datum/material/glass = 50) build_path = /obj/item/electronics/airalarm category = list("initial", "Electronics") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -199,7 +199,7 @@ name = "Airlock Controller Electronics" id = "aac_electronics" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 50, MAT_GLASS = 50) + materials = list(/datum/material/iron = 50, /datum/material/glass = 50) build_path = /obj/item/electronics/advanced_airlock_controller category = list("initial", "Electronics") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -208,7 +208,7 @@ name = "Fire Alarm Electronics" id = "firealarm_electronics" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 50, MAT_GLASS = 50) + materials = list(/datum/material/iron = 50, /datum/material/glass = 50) build_path = /obj/item/electronics/firealarm category = list("initial", "Electronics") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -217,7 +217,7 @@ name = "Camera" id = "camera" build_type = AUTOLATHE - materials = list(MAT_METAL = 50, MAT_GLASS = 100) + materials = list(/datum/material/iron = 50, /datum/material/glass = 100) build_path = /obj/item/camera category = list("initial", "Misc") @@ -225,7 +225,7 @@ name = "Camera Film Cartridge" id = "camera_film" build_type = AUTOLATHE - materials = list(MAT_METAL = 10, MAT_GLASS = 10) + materials = list(/datum/material/iron = 10, /datum/material/glass = 10) build_path = /obj/item/camera_film category = list("initial", "Misc") @@ -233,7 +233,7 @@ name = "Earmuffs" id = "earmuffs" build_type = AUTOLATHE - materials = list(MAT_METAL = 500, MAT_GLASS = 500) + materials = list(/datum/material/iron = 500, /datum/material/glass = 500) build_path = /obj/item/clothing/ears/earmuffs category = list("initial", "Misc") @@ -241,7 +241,7 @@ name = "Pipe Painter" id = "pipe_painter" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 5000, MAT_GLASS = 2000) + materials = list(/datum/material/iron = 5000, /datum/material/glass = 2000) build_path = /obj/item/pipe_painter category = list("initial","Tools","Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -250,7 +250,7 @@ name = "Airlock Painter" id = "airlock_painter" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 50, MAT_GLASS = 50) + materials = list(/datum/material/iron = 50, /datum/material/glass = 50) build_path = /obj/item/airlock_painter category = list("initial","Tools","Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -259,7 +259,7 @@ name = "Emergency Oxygen Tank" id = "emergency_oxygen" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 500) + materials = list(/datum/material/iron = 500) build_path = /obj/item/tank/internals/emergency_oxygen/empty category = list("initial","Misc","Equipment") @@ -267,7 +267,7 @@ name = "Extended-Capacity Emergency Oxygen Tank" id = "emergency_oxygen_engi" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 750) + materials = list(/datum/material/iron = 750) build_path = /obj/item/tank/internals/emergency_oxygen/engi/empty category = list("hacked","Misc","Equipment") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING | DEPARTMENTAL_FLAG_CARGO @@ -276,7 +276,7 @@ name = "Plasmaman Belt Tank" id = "plasmaman_tank_belt" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 800) + materials = list(/datum/material/iron = 800) build_path = /obj/item/tank/internals/plasmaman/belt/empty category = list("hacked","Misc","Equipment") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING | DEPARTMENTAL_FLAG_CARGO @@ -285,7 +285,7 @@ name = "Metal" id = "metal" build_type = AUTOLATHE - materials = list(MAT_METAL = MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/iron = MINERAL_MATERIAL_AMOUNT) build_path = /obj/item/stack/sheet/metal category = list("initial","Construction") maxstack = 50 @@ -294,7 +294,7 @@ name = "Glass" id = "glass" build_type = AUTOLATHE - materials = list(MAT_GLASS = MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/glass = MINERAL_MATERIAL_AMOUNT) build_path = /obj/item/stack/sheet/glass category = list("initial","Construction") maxstack = 50 @@ -303,7 +303,7 @@ name = "Reinforced Glass" id = "rglass" build_type = AUTOLATHE | SMELTER | PROTOLATHE - materials = list(MAT_METAL = 1000, MAT_GLASS = MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/iron = 1000, /datum/material/glass = MINERAL_MATERIAL_AMOUNT) build_path = /obj/item/stack/sheet/rglass category = list("initial","Construction","Stock Parts") maxstack = 50 @@ -312,7 +312,7 @@ name = "Metal Rod" id = "rods" build_type = AUTOLATHE - materials = list(MAT_METAL = 1000) + materials = list(/datum/material/iron = 1000) build_path = /obj/item/stack/rods category = list("initial","Construction") maxstack = 50 @@ -321,7 +321,7 @@ name = "Compressed Matter Cartridge" id = "rcd_ammo" build_type = AUTOLATHE - materials = list(MAT_METAL = 12000, MAT_GLASS=8000) + materials = list(/datum/material/iron = 12000, /datum/material/glass=8000) build_path = /obj/item/rcd_ammo category = list("initial","Construction") @@ -329,7 +329,7 @@ name = "Kitchen Knife" id = "kitchen_knife" build_type = AUTOLATHE - materials = list(MAT_METAL = 12000) + materials = list(/datum/material/iron = 12000) build_path = /obj/item/kitchen/knife category = list("initial","Dinnerware") @@ -337,7 +337,7 @@ name = "Fork" id = "fork" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 80) + materials = list(/datum/material/iron = 80) build_path = /obj/item/kitchen/fork category = list("initial","Dinnerware","Service") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -346,7 +346,7 @@ name = "Tray" id = "tray" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 3000) + materials = list(/datum/material/iron = 3000) build_path = /obj/item/storage/bag/tray category = list("initial","Dinnerware","Service") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -355,7 +355,7 @@ name = "Bowl" id = "bowl" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_GLASS = 500) + materials = list(/datum/material/glass = 500) build_path = /obj/item/reagent_containers/glass/bowl category = list("initial","Dinnerware","Service") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -364,7 +364,7 @@ name = "Mixing Bowl" id = "mixing_bowl" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 1750) + materials = list(/datum/material/iron = 1750) build_path = /obj/item/reagent_containers/glass/mixbowl category = list("initial","Dinnerware","Service") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -373,7 +373,7 @@ name = "Drinking Glass" id = "drinking_glass" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_GLASS = 500) + materials = list(/datum/material/glass = 500) build_path = /obj/item/reagent_containers/food/drinks/drinkingglass category = list("initial","Dinnerware","Service") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -382,7 +382,7 @@ name = "Shot Glass" id = "shot_glass" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_GLASS = 100) + materials = list(/datum/material/glass = 100) build_path = /obj/item/reagent_containers/food/drinks/drinkingglass/shotglass category = list("initial","Dinnerware","Service") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -391,7 +391,7 @@ name = "Shaker" id = "shaker" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 1500) + materials = list(/datum/material/iron = 1500) build_path = /obj/item/reagent_containers/food/drinks/shaker category = list("initial","Dinnerware","Service") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -400,7 +400,7 @@ name = "Cultivator" id = "cultivator" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL=50) + materials = list(/datum/material/iron=50) build_path = /obj/item/cultivator category = list("initial","Misc", "Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -409,7 +409,7 @@ name = "Plant Analyzer" id = "plant_analyzer" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 30, MAT_GLASS = 20) + materials = list(/datum/material/iron = 30, /datum/material/glass = 20) build_path = /obj/item/plant_analyzer category = list("initial","Misc", "Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -418,7 +418,7 @@ name = "Shovel" id = "shovel" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 50) + materials = list(/datum/material/iron = 50) build_path = /obj/item/shovel category = list("initial","Misc", "Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -427,7 +427,7 @@ name = "Spade" id = "spade" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 50) + materials = list(/datum/material/iron = 50) build_path = /obj/item/shovel/spade category = list("initial","Misc", "Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -436,7 +436,7 @@ name = "Hatchet" id = "hatchet" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 15000) + materials = list(/datum/material/iron = 15000) build_path = /obj/item/hatchet category = list("initial","Misc", "Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -445,7 +445,7 @@ name = "Tinfoil Hat" id = "tinfoil_hat" build_type = AUTOLATHE - materials = list(MAT_METAL = 5500) + materials = list(/datum/material/iron = 5500) build_path = /obj/item/clothing/head/foilhat category = list("hacked", "Misc") @@ -453,7 +453,7 @@ name = "Scalpel" id = "scalpel" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 4000, MAT_GLASS = 1000) + materials = list(/datum/material/iron = 4000, /datum/material/glass = 1000) build_path = /obj/item/scalpel category = list("initial", "Medical", "Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL | DEPARTMENTAL_FLAG_SCIENCE @@ -462,7 +462,7 @@ name = "Circular Saw" id = "circular_saw" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 10000, MAT_GLASS = 6000) + materials = list(/datum/material/iron = 10000, /datum/material/glass = 6000) build_path = /obj/item/circular_saw category = list("initial", "Medical", "Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL | DEPARTMENTAL_FLAG_SCIENCE @@ -471,7 +471,7 @@ name = "Surgical Drill" id = "surgicaldrill" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 10000, MAT_GLASS = 6000) + materials = list(/datum/material/iron = 10000, /datum/material/glass = 6000) build_path = /obj/item/surgicaldrill category = list("initial", "Medical", "Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL | DEPARTMENTAL_FLAG_SCIENCE @@ -480,7 +480,7 @@ name = "Retractor" id = "retractor" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 6000, MAT_GLASS = 3000) + materials = list(/datum/material/iron = 6000, /datum/material/glass = 3000) build_path = /obj/item/retractor category = list("initial", "Medical", "Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL | DEPARTMENTAL_FLAG_SCIENCE @@ -489,7 +489,7 @@ name = "Cautery" id = "cautery" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 2500, MAT_GLASS = 750) + materials = list(/datum/material/iron = 2500, /datum/material/glass = 750) build_path = /obj/item/cautery category = list("initial", "Medical", "Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL | DEPARTMENTAL_FLAG_SCIENCE @@ -498,7 +498,7 @@ name = "Hemostat" id = "hemostat" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 5000, MAT_GLASS = 2500) + materials = list(/datum/material/iron = 5000, /datum/material/glass = 2500) build_path = /obj/item/hemostat category = list("initial", "Medical", "Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL | DEPARTMENTAL_FLAG_SCIENCE @@ -507,7 +507,7 @@ name = "Beaker" id = "beaker" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_GLASS = 500) + materials = list(/datum/material/glass = 500) build_path = /obj/item/reagent_containers/glass/beaker category = list("initial", "Medical", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL | DEPARTMENTAL_FLAG_SERVICE @@ -516,7 +516,7 @@ name = "Large Beaker" id = "large_beaker" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_GLASS = 2500) + materials = list(/datum/material/glass = 2500) build_path = /obj/item/reagent_containers/glass/beaker/large category = list("initial", "Medical", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL | DEPARTMENTAL_FLAG_SERVICE @@ -525,7 +525,7 @@ name = "Health Analyzer" id = "healthanalyzer" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 500, MAT_GLASS = 50) + materials = list(/datum/material/iron = 500, /datum/material/glass = 50) build_path = /obj/item/healthanalyzer category = list("initial", "Medical", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -534,7 +534,7 @@ name = "Pill Bottle" id = "pillbottle" build_type = AUTOLATHE - materials = list(MAT_METAL = 20, MAT_GLASS = 100) + materials = list(/datum/material/iron = 20, /datum/material/glass = 100) build_path = /obj/item/storage/pill_bottle category = list("initial", "Medical", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -543,7 +543,7 @@ name = "Beanbag Slug" id = "beanbag_slug" build_type = AUTOLATHE - materials = list(MAT_METAL = 2000) + materials = list(/datum/material/iron = 2000) build_path = /obj/item/ammo_casing/shotgun/beanbag category = list("initial", "Security") @@ -551,7 +551,7 @@ name = "Rubber Shot" id = "rubber_shot" build_type = AUTOLATHE - materials = list(MAT_METAL = 4000) + materials = list(/datum/material/iron = 4000) build_path = /obj/item/ammo_casing/shotgun/rubbershot category = list("initial", "Security") @@ -559,7 +559,7 @@ name = "Speed Loader (.38)" id = "c38" build_type = AUTOLATHE - materials = list(MAT_METAL = 20000) + materials = list(/datum/material/iron = 20000) build_path = /obj/item/ammo_box/c38 category = list("initial", "Security") @@ -567,7 +567,7 @@ name = "Universal Recorder" id = "recorder" build_type = AUTOLATHE - materials = list(MAT_METAL = 60, MAT_GLASS = 30) + materials = list(/datum/material/iron = 60, /datum/material/glass = 30) build_path = /obj/item/taperecorder/empty category = list("initial", "Misc") @@ -575,7 +575,7 @@ name = "Tape" id = "tape" build_type = AUTOLATHE - materials = list(MAT_METAL = 20, MAT_GLASS = 5) + materials = list(/datum/material/iron = 20, /datum/material/glass = 5) build_path = /obj/item/tape/random category = list("initial", "Misc") @@ -583,7 +583,7 @@ name = "Igniter" id = "igniter" build_type = AUTOLATHE - materials = list(MAT_METAL = 500, MAT_GLASS = 50) + materials = list(/datum/material/iron = 500, /datum/material/glass = 50) build_path = /obj/item/assembly/igniter category = list("initial", "Misc") @@ -591,7 +591,7 @@ name = "Remote Signaling Device" id = "signaler" build_type = AUTOLATHE - materials = list(MAT_METAL = 400, MAT_GLASS = 120) + materials = list(/datum/material/iron = 400, /datum/material/glass = 120) build_path = /obj/item/assembly/signaler category = list("initial", "T-Comm") @@ -599,7 +599,7 @@ name = "Mousetrap" id = "mousetrap" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 100) + materials = list(/datum/material/iron = 100) build_path = /obj/item/assembly/mousetrap category = list("initial", "Misc") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -608,7 +608,7 @@ name = "Radio Headset" id = "radio_headset" build_type = AUTOLATHE - materials = list(MAT_METAL = 75) + materials = list(/datum/material/iron = 75) build_path = /obj/item/radio/headset category = list("initial", "T-Comm") @@ -616,7 +616,7 @@ name = "Station Bounced Radio" id = "bounced_radio" build_type = AUTOLATHE - materials = list(MAT_METAL = 75, MAT_GLASS = 25) + materials = list(/datum/material/iron = 75, /datum/material/glass = 25) build_path = /obj/item/radio/off category = list("initial", "T-Comm") @@ -624,7 +624,7 @@ name = "Intercom Frame" id = "intercom_frame" build_type = AUTOLATHE - materials = list(MAT_METAL = 75, MAT_GLASS = 25) + materials = list(/datum/material/iron = 75, /datum/material/glass = 25) build_path = /obj/item/wallframe/intercom category = list("initial", "T-Comm") @@ -632,7 +632,7 @@ name = "Infrared Emitter" id = "infrared_emitter" build_type = AUTOLATHE - materials = list(MAT_METAL = 1000, MAT_GLASS = 500) + materials = list(/datum/material/iron = 1000, /datum/material/glass = 500) build_path = /obj/item/assembly/infra category = list("initial", "Misc") @@ -640,7 +640,7 @@ name = "Health Sensor" id = "health_sensor" build_type = AUTOLATHE - materials = list(MAT_METAL = 800, MAT_GLASS = 200) + materials = list(/datum/material/iron = 800, /datum/material/glass = 200) build_path = /obj/item/assembly/health category = list("initial", "Medical") @@ -648,7 +648,7 @@ name = "Timer" id = "timer" build_type = AUTOLATHE - materials = list(MAT_METAL = 500, MAT_GLASS = 50) + materials = list(/datum/material/iron = 500, /datum/material/glass = 50) build_path = /obj/item/assembly/timer category = list("initial", "Misc") @@ -656,7 +656,7 @@ name = "Voice Analyser" id = "voice_analyser" build_type = AUTOLATHE - materials = list(MAT_METAL = 500, MAT_GLASS = 50) + materials = list(/datum/material/iron = 500, /datum/material/glass = 50) build_path = /obj/item/assembly/voice category = list("initial", "Misc") @@ -664,7 +664,7 @@ name = "Light Tube" id = "light_tube" build_type = AUTOLATHE - materials = list(MAT_GLASS = 100) + materials = list(/datum/material/glass = 100) build_path = /obj/item/light/tube category = list("initial", "Construction") @@ -672,7 +672,7 @@ name = "Light Bulb" id = "light_bulb" build_type = AUTOLATHE - materials = list(MAT_GLASS = 100) + materials = list(/datum/material/glass = 100) build_path = /obj/item/light/bulb category = list("initial", "Construction") @@ -680,7 +680,7 @@ name = "Camera Assembly" id = "camera_assembly" build_type = AUTOLATHE - materials = list(MAT_METAL = 400, MAT_GLASS = 250) + materials = list(/datum/material/iron = 400, /datum/material/glass = 250) build_path = /obj/item/wallframe/camera category = list("initial", "Construction") @@ -688,7 +688,7 @@ name = "Newscaster Frame" id = "newscaster_frame" build_type = AUTOLATHE - materials = list(MAT_METAL = 14000, MAT_GLASS = 8000) + materials = list(/datum/material/iron = 14000, /datum/material/glass = 8000) build_path = /obj/item/wallframe/newscaster category = list("initial", "Construction") @@ -696,7 +696,7 @@ name = "Bounty Board Frame" id = "bountyboard_frame" build_type = AUTOLATHE - materials = list(MAT_METAL = 14000, MAT_GLASS = 8000) + materials = list(/datum/material/iron = 14000, /datum/material/glass = 8000) build_path = /obj/item/wallframe/bounty_board category = list("initial", "Construction") @@ -704,7 +704,7 @@ name = "Syringe" id = "syringe" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 10, MAT_GLASS = 20) + materials = list(/datum/material/iron = 10, /datum/material/glass = 20) build_path = /obj/item/reagent_containers/syringe category = list("initial", "Medical", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -713,7 +713,7 @@ name = "Dropper" id = "dropper" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 30, MAT_GLASS = 10) + materials = list(/datum/material/iron = 30, /datum/material/glass = 10) build_path = /obj/item/reagent_containers/dropper category = list("initial", "Medical", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -722,7 +722,7 @@ name = "Proximity Sensor" id = "prox_sensor" build_type = AUTOLATHE - materials = list(MAT_METAL = 800, MAT_GLASS = 200) + materials = list(/datum/material/iron = 800, /datum/material/glass = 200) build_path = /obj/item/assembly/prox_sensor category = list("initial", "Misc") @@ -730,7 +730,7 @@ name = "Box of Foam Darts" id = "foam_dart" build_type = AUTOLATHE - materials = list(MAT_METAL = 500) + materials = list(/datum/material/iron = 500) build_path = /obj/item/ammo_box/foambox category = list("initial", "Misc") @@ -740,7 +740,7 @@ name = "Rapid Construction Device (RCD)" id = "rcd" build_type = AUTOLATHE - materials = list(MAT_METAL = 30000) + materials = list(/datum/material/iron = 30000) build_path = /obj/item/construction/rcd category = list("hacked", "Construction") @@ -748,7 +748,7 @@ name = "Rapid Pipe Dispenser (RPD)" id = "rpd" build_type = AUTOLATHE - materials = list(MAT_METAL = 45000, MAT_GLASS = 37500) + materials = list(/datum/material/iron = 45000, /datum/material/glass = 37500) build_path = /obj/item/pipe_dispenser category = list("hacked", "Construction") @@ -756,7 +756,7 @@ name = "Electropack" id = "electropack" build_type = AUTOLATHE - materials = list(MAT_METAL = 10000, MAT_GLASS = 2500) + materials = list(/datum/material/iron = 10000, /datum/material/glass = 2500) build_path = /obj/item/electropack category = list("hacked", "Tools") @@ -764,7 +764,7 @@ name = "Industrial Welding Tool" id = "large_welding_tool" build_type = AUTOLATHE - materials = list(MAT_METAL = 70, MAT_GLASS = 60) + materials = list(/datum/material/iron = 70, /datum/material/glass = 60) build_path = /obj/item/weldingtool/largetank category = list("hacked", "Tools") @@ -772,7 +772,7 @@ name = "Handcuffs" id = "handcuffs" build_type = AUTOLATHE - materials = list(MAT_METAL = 500) + materials = list(/datum/material/iron = 500) build_path = /obj/item/restraints/handcuffs category = list("hacked", "Security") @@ -780,7 +780,7 @@ name = "Modular Receiver" id = "receiver" build_type = AUTOLATHE - materials = list(MAT_METAL = 15000) + materials = list(/datum/material/iron = 15000) build_path = /obj/item/weaponcrafting/receiver category = list("hacked", "Security") @@ -788,7 +788,7 @@ name = "Shotgun Slug" id = "shotgun_slug" build_type = AUTOLATHE - materials = list(MAT_METAL = 4000) + materials = list(/datum/material/iron = 4000) build_path = /obj/item/ammo_casing/shotgun category = list("hacked", "Security") @@ -796,7 +796,7 @@ name = "Buckshot Shell" id = "buckshot_shell" build_type = AUTOLATHE - materials = list(MAT_METAL = 4000) + materials = list(/datum/material/iron = 4000) build_path = /obj/item/ammo_casing/shotgun/buckshot category = list("hacked", "Security") @@ -804,7 +804,7 @@ name = "Shotgun Dart" id = "shotgun_dart" build_type = AUTOLATHE - materials = list(MAT_METAL = 4000) + materials = list(/datum/material/iron = 4000) build_path = /obj/item/ammo_casing/shotgun/dart category = list("hacked", "Security") @@ -812,7 +812,7 @@ name = "Incendiary Slug" id = "incendiary_slug" build_type = AUTOLATHE - materials = list(MAT_METAL = 4000) + materials = list(/datum/material/iron = 4000) build_path = /obj/item/ammo_casing/shotgun/incendiary category = list("hacked", "Security") @@ -820,7 +820,7 @@ name = "Foam Riot Dart" id = "riot_dart" build_type = AUTOLATHE - materials = list(MAT_METAL = 1000) //Discount for making individually - no box = less metal! + materials = list(/datum/material/iron = 1000) //Discount for making individually - no box = less metal! build_path = /obj/item/ammo_casing/caseless/foam_dart/riot category = list("hacked", "Security") @@ -828,7 +828,7 @@ name = "Foam Riot Dart Box" id = "riot_darts" build_type = AUTOLATHE - materials = list(MAT_METAL = 50000) //Comes with 40 darts + materials = list(/datum/material/iron = 50000) //Comes with 40 darts build_path = /obj/item/ammo_box/foambox/riot category = list("hacked", "Security") @@ -836,7 +836,7 @@ name = ".357 Bullet" id = "a357" build_type = AUTOLATHE - materials = list(MAT_METAL = 4000) + materials = list(/datum/material/iron = 4000) build_path = /obj/item/ammo_casing/a357 category = list("hacked", "Security") @@ -844,7 +844,7 @@ name = "Ammo Box (10mm)" id = "c10mm" build_type = AUTOLATHE - materials = list(MAT_METAL = 30000) + materials = list(/datum/material/iron = 30000) build_path = /obj/item/ammo_box/c10mm category = list("hacked", "Security") @@ -852,7 +852,7 @@ name = "Ammo Box (.45)" id = "c45" build_type = AUTOLATHE - materials = list(MAT_METAL = 30000) + materials = list(/datum/material/iron = 30000) build_path = /obj/item/ammo_box/c45 category = list("hacked", "Security") @@ -860,7 +860,7 @@ name = "Ammo Box (9mm)" id = "c9mm" build_type = AUTOLATHE - materials = list(MAT_METAL = 30000) + materials = list(/datum/material/iron = 30000) build_path = /obj/item/ammo_box/c9mm category = list("hacked", "Security") @@ -868,7 +868,7 @@ name = "Butcher's Cleaver" id = "cleaver" build_type = AUTOLATHE - materials = list(MAT_METAL = 18000) + materials = list(/datum/material/iron = 18000) build_path = /obj/item/kitchen/knife/butcher category = list("hacked", "Dinnerware") @@ -876,7 +876,7 @@ name = "Spraycan" id = "spraycan" build_type = AUTOLATHE - materials = list(MAT_METAL = 100, MAT_GLASS = 100) + materials = list(/datum/material/iron = 100, /datum/material/glass = 100) build_path = /obj/item/toy/crayon/spraycan category = list("initial", "Tools") @@ -884,7 +884,7 @@ name = "Destination Tagger" id = "desttagger" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 250, MAT_GLASS = 125) + materials = list(/datum/material/iron = 250, /datum/material/glass = 125) build_path = /obj/item/destTagger category = list("initial", "Electronics") @@ -892,7 +892,7 @@ name = "Hand Labeler" id = "handlabel" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 150, MAT_GLASS = 125) + materials = list(/datum/material/iron = 150, /datum/material/glass = 125) build_path = /obj/item/hand_labeler category = list("initial", "Electronics") @@ -900,7 +900,7 @@ name = "Geiger Counter" id = "geigercounter" build_type = AUTOLATHE - materials = list(MAT_METAL = 150, MAT_GLASS = 150) + materials = list(/datum/material/iron = 150, /datum/material/glass = 150) build_path = /obj/item/geiger_counter category = list("initial", "Tools") @@ -908,7 +908,7 @@ name = "Turret Control Frame" id = "turret_control" build_type = AUTOLATHE - materials = list(MAT_METAL = 12000) + materials = list(/datum/material/iron = 12000) build_path = /obj/item/wallframe/turret_control category = list("initial", "Construction") @@ -916,7 +916,7 @@ name = "Conveyor Belt" id = "conveyor_belt" build_type = AUTOLATHE - materials = list(MAT_METAL = 3000) + materials = list(/datum/material/iron = 3000) build_path = /obj/item/stack/conveyor category = list("initial", "Construction") maxstack = 30 @@ -926,7 +926,7 @@ name = "Conveyor Belt Switch" id = "conveyor_switch" build_type = AUTOLATHE - materials = list(MAT_METAL = 450, MAT_GLASS = 190) + materials = list(/datum/material/iron = 450, /datum/material/glass = 190) build_path = /obj/item/conveyor_switch_construct category = list("initial", "Construction") @@ -934,7 +934,7 @@ name = "Laptop Frame" id = "laptop" build_type = AUTOLATHE - materials = list(MAT_METAL = 10000, MAT_GLASS = 1000) + materials = list(/datum/material/iron = 10000, /datum/material/glass = 1000) build_path = /obj/item/modular_computer/laptop/buildable category = list("initial","Misc") @@ -942,7 +942,7 @@ name = "Tablet Frame" id = "tablet" build_type = AUTOLATHE - materials = list(MAT_METAL = 2000, MAT_GLASS = 1000) + materials = list(/datum/material/iron = 2000, /datum/material/glass = 1000) build_path = /obj/item/modular_computer/tablet category = list("initial","Misc") @@ -950,7 +950,7 @@ name = "Slime Scanner" id = "slime_scanner" build_type = AUTOLATHE - materials = list(MAT_METAL = 300, MAT_GLASS = 200) + materials = list(/datum/material/iron = 300, /datum/material/glass = 200) build_path = /obj/item/slime_scanner category = list("initial", "Misc") @@ -958,7 +958,7 @@ name = "Pet Carrier" id = "pet_carrier" build_type = AUTOLATHE - materials = list(MAT_METAL = 7500, MAT_GLASS = 100) + materials = list(/datum/material/iron = 7500, /datum/material/glass = 100) build_path = /obj/item/pet_carrier category = list("initial", "Misc") @@ -966,7 +966,7 @@ name = "Light Fixture Battery" id = "miniature_power_cell" build_type = AUTOLATHE - materials = list(MAT_GLASS = 20) + materials = list(/datum/material/glass = 20) build_path = /obj/item/stock_parts/cell/emergency_light category = list("initial", "Electronics") @@ -974,7 +974,7 @@ name = "Package Wrapping" id = "packagewrap" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 200, MAT_GLASS = 200) + materials = list(/datum/material/iron = 200, /datum/material/glass = 200) build_path = /obj/item/stack/packageWrap category = list("initial", "Misc", "Equipment") maxstack = 30 @@ -983,7 +983,7 @@ name = "Holodisk" id = "holodisk" build_type = AUTOLATHE - materials = list(MAT_METAL = 100, MAT_GLASS = 100) + materials = list(/datum/material/iron = 100, /datum/material/glass = 100) build_path = /obj/item/disk/holodisk category = list("initial", "Misc") @@ -991,7 +991,7 @@ name = "Blue Circuit Tile" id = "circuit" build_type = AUTOLATHE - materials = list(MAT_METAL = 500, MAT_GLASS = 500) + materials = list(/datum/material/iron = 500, /datum/material/glass = 500) build_path = /obj/item/stack/tile/circuit category = list("initial", "Misc") maxstack = 50 @@ -1000,7 +1000,7 @@ name = "Green Circuit Tile" id = "circuitgreen" build_type = AUTOLATHE - materials = list(MAT_METAL = 500, MAT_GLASS = 500) + materials = list(/datum/material/iron = 500, /datum/material/glass = 500) build_path = /obj/item/stack/tile/circuit/green category = list("initial", "Misc") maxstack = 50 @@ -1009,7 +1009,7 @@ name = "Red Circuit Tile" id = "circuitred" build_type = AUTOLATHE - materials = list(MAT_METAL = 500, MAT_GLASS = 500) + materials = list(/datum/material/iron = 500, /datum/material/glass = 500) build_path = /obj/item/stack/tile/circuit/red category = list("initial", "Misc") maxstack = 50 @@ -1018,7 +1018,7 @@ name = "Penlight" id = "penlight" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 100, MAT_GLASS = 20) + materials = list(/datum/material/iron = 100, /datum/material/glass = 20) build_path = /obj/item/flashlight/pen category = list("initial", "Medical", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -1027,7 +1027,7 @@ name = "Stethoscope" id = "stethoscope" build_type = AUTOLATHE | PROTOLATHE - materials = list(MAT_METAL = 300) + materials = list(/datum/material/iron = 300) build_path = /obj/item/clothing/neck/stethoscope category = list("initial", "Medical", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -1036,7 +1036,7 @@ name = "Mounted Flash Frame" id = "wallframe/flasher" build_type = PROTOLATHE - materials = list(MAT_METAL = 10000, MAT_GLASS = 4000) + materials = list(/datum/material/iron = 10000, /datum/material/glass = 4000) build_path = /obj/item/wallframe/flasher category = list("Misc. Machinery") departmental_flags = DEPARTMENTAL_FLAG_SECURITY diff --git a/code/modules/research/designs/biogenerator_designs.dm b/code/modules/research/designs/biogenerator_designs.dm index 4cd85310c02c..5505bbc57eee 100644 --- a/code/modules/research/designs/biogenerator_designs.dm +++ b/code/modules/research/designs/biogenerator_designs.dm @@ -6,7 +6,7 @@ name = "10 Milk" id = "milk" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 20) + materials = list(/datum/material/biomass = 20) make_reagents = list(/datum/reagent/consumable/milk = 10) category = list("initial","Food") @@ -14,7 +14,7 @@ name = "10 Cream" id = "cream" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 30) + materials = list(/datum/material/biomass = 30) make_reagents = list(/datum/reagent/consumable/cream = 10) category = list("initial","Food") @@ -22,7 +22,7 @@ name = "Milk Carton" id = "milk_carton" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 100) + materials = list(/datum/material/biomass = 100) build_path = /obj/item/reagent_containers/food/condiment/milk category = list("initial","Food") @@ -30,7 +30,7 @@ name = "Cream Carton" id = "cream_carton" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 300) + materials = list(/datum/material/biomass = 300) build_path = /obj/item/reagent_containers/food/drinks/bottle/cream category = list("initial","Food") @@ -38,7 +38,7 @@ name = "10u Black Pepper" id = "black_pepper" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 25) + materials = list(/datum/material/biomass = 25) make_reagents = list(/datum/reagent/consumable/blackpepper = 10) category = list("initial","Food") @@ -46,7 +46,7 @@ name = "Pepper Mill" id = "pepper_mill" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 50) + materials = list(/datum/material/biomass = 50) build_path = /obj/item/reagent_containers/food/condiment/peppermill make_reagents = list() category = list("initial","Food") @@ -55,7 +55,7 @@ name = "10u Universal Enzyme" id = "enzyme" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 30) + materials = list(/datum/material/biomass = 30) make_reagents = list(/datum/reagent/consumable/enzyme = 10) category = list("initial","Food") @@ -63,7 +63,7 @@ name = "Flour Sack" id = "flour_sack" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 150) + materials = list(/datum/material/biomass = 150) build_path = /obj/item/reagent_containers/food/condiment/flour category = list("initial","Food") @@ -71,7 +71,7 @@ name = "Monkey Cube" id = "mcube" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 250) + materials = list(/datum/material/biomass = 250) build_path = /obj/item/reagent_containers/food/snacks/monkeycube category = list("initial", "Food") @@ -79,7 +79,7 @@ name = "E-Z Nutrient" id = "ez_nut" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 10) + materials = list(/datum/material/biomass = 10) build_path = /obj/item/reagent_containers/glass/bottle/nutrient/ez category = list("initial","Botany Chemicals") @@ -87,7 +87,7 @@ name = "Left 4 Zed" id = "l4z_nut" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 20) + materials = list(/datum/material/biomass = 20) build_path = /obj/item/reagent_containers/glass/bottle/nutrient/l4z category = list("initial","Botany Chemicals") @@ -95,7 +95,7 @@ name = "Robust Harvest" id = "rh_nut" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 25) + materials = list(/datum/material/biomass = 25) build_path = /obj/item/reagent_containers/glass/bottle/nutrient/rh category = list("initial","Botany Chemicals") @@ -103,7 +103,7 @@ name = "Weed Killer" id = "weed_killer" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 50) + materials = list(/datum/material/biomass = 50) build_path = /obj/item/reagent_containers/glass/bottle/killer/weedkiller category = list("initial","Botany Chemicals") @@ -111,7 +111,7 @@ name = "Pest Killer" id = "pest_spray" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 50) + materials = list(/datum/material/biomass = 50) build_path = /obj/item/reagent_containers/glass/bottle/killer/pestkiller category = list("initial","Botany Chemicals") @@ -119,7 +119,7 @@ name = "Empty Bottle" id = "botany_bottle" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 5) + materials = list(/datum/material/biomass = 5) build_path = /obj/item/reagent_containers/glass/bottle/nutrient/empty category = list("initial", "Botany Chemicals") @@ -127,15 +127,15 @@ name = "Rolling Papers" id = "rollingpapers" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 50) + materials = list(/datum/material/biomass = 50) build_path = /obj/item/storage/box/fancy/rollingpapers category = list("initial", "Organic Materials") - + /datum/design/cloth name = "Roll of Cloth" id = "cloth" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 50) + materials = list(/datum/material/biomass = 50) build_path = /obj/item/stack/sheet/cloth category = list("initial","Organic Materials") @@ -143,7 +143,7 @@ name = "Sheet of Cardboard" id = "cardboard" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 25) + materials = list(/datum/material/biomass = 25) build_path = /obj/item/stack/sheet/cardboard category = list("initial","Organic Materials") @@ -151,7 +151,7 @@ name = "Sheet of Leather" id = "leather" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 150) + materials = list(/datum/material/biomass = 150) build_path = /obj/item/stack/sheet/leather category = list("initial","Organic Materials") @@ -159,7 +159,7 @@ name = "Security Belt" id = "secbelt" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 300) + materials = list(/datum/material/biomass = 300) build_path = /obj/item/storage/belt/security category = list("initial","Organic Materials") @@ -167,7 +167,7 @@ name = "Medical Belt" id = "medbel" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 300) + materials = list(/datum/material/biomass = 300) build_path = /obj/item/storage/belt/medical category = list("initial","Organic Materials") @@ -175,7 +175,7 @@ name = "Janitorial Belt" id = "janibelt" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 300) + materials = list(/datum/material/biomass = 300) build_path = /obj/item/storage/belt/janitor category = list("initial","Organic Materials") @@ -183,7 +183,7 @@ name = "Shoulder Holster" id = "s_holster" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 400) + materials = list(/datum/material/biomass = 400) build_path = /obj/item/storage/belt/holster category = list("initial","Organic Materials") @@ -191,6 +191,6 @@ name = "Rice Hat" id = "rice_hat" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 300) + materials = list(/datum/material/biomass = 300) build_path = /obj/item/clothing/head/rice_hat category = list("initial","Organic Materials") diff --git a/code/modules/research/designs/bluespace_designs.dm b/code/modules/research/designs/bluespace_designs.dm index 3fde9049b239..d384456eee24 100644 --- a/code/modules/research/designs/bluespace_designs.dm +++ b/code/modules/research/designs/bluespace_designs.dm @@ -8,7 +8,7 @@ desc = "A bluespace tracking beacon." id = "beacon" build_type = PROTOLATHE - materials = list(MAT_METAL = 150, MAT_GLASS = 100) + materials = list(/datum/material/iron = 150, /datum/material/glass = 100) build_path = /obj/item/beacon category = list("Bluespace Designs") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING | DEPARTMENTAL_FLAG_CARGO | DEPARTMENTAL_FLAG_SECURITY @@ -18,7 +18,7 @@ desc = "A backpack that opens into a localized pocket of bluespace." id = "bag_holding" build_type = PROTOLATHE - materials = list(MAT_GOLD = 3000, MAT_DIAMOND = 1500, MAT_URANIUM = 250, MAT_BLUESPACE = 2000) + materials = list(/datum/material/gold = 3000, /datum/material/diamond = 1500, /datum/material/uranium = 250, /datum/material/bluespace = 2000) build_path = /obj/item/storage/backpack/holding category = list("Bluespace Designs") dangerous_construction = TRUE @@ -29,7 +29,7 @@ desc = "A small blue crystal with mystical properties." id = "bluespace_crystal" build_type = PROTOLATHE - materials = list(MAT_DIAMOND = 1500, MAT_PLASMA = 1500) + materials = list(/datum/material/diamond = 1500, /datum/material/plasma = 1500) build_path = /obj/item/stack/ore/bluespace_crystal/artificial category = list("Bluespace Designs") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -39,17 +39,17 @@ desc = "Little thingie that can track its position at all times." id = "telesci_gps" build_type = PROTOLATHE - materials = list(MAT_METAL = 500, MAT_GLASS = 1000) + materials = list(/datum/material/iron = 500, /datum/material/glass = 1000) build_path = /obj/item/gps category = list("Bluespace Designs") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING | DEPARTMENTAL_FLAG_CARGO - + /datum/design/desynchronizer name = "Desynchronizer" desc = "A device that can desynchronize the user from spacetime." id = "desynchronizer" build_type = PROTOLATHE - materials = list(MAT_METAL = 1000, MAT_GLASS = 500, MAT_SILVER = 1500, MAT_BLUESPACE = 1000) + materials = list(/datum/material/iron = 1000, /datum/material/glass = 500, /datum/material/silver = 1500, /datum/material/bluespace = 1000) build_path = /obj/item/desynchronizer category = list("Bluespace Designs") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -59,7 +59,7 @@ desc = "A mining satchel that can hold an infinite amount of ores." id = "minerbag_holding" build_type = PROTOLATHE - materials = list(MAT_GOLD = 250, MAT_URANIUM = 500) //quite cheap, for more convenience + materials = list(/datum/material/gold = 250, /datum/material/uranium = 500) //quite cheap, for more convenience build_path = /obj/item/storage/bag/ore/holding category = list("Bluespace Designs") departmental_flags = DEPARTMENTAL_FLAG_CARGO diff --git a/code/modules/research/designs/comp_board_designs.dm b/code/modules/research/designs/comp_board_designs.dm index f661526cafb1..83400fc18f2b 100644 --- a/code/modules/research/designs/comp_board_designs.dm +++ b/code/modules/research/designs/comp_board_designs.dm @@ -4,7 +4,7 @@ name = "Computer Design ( NULL ENTRY )" desc = "I promise this doesn't give you syndicate goodies!" build_type = IMPRINTER - materials = list(MAT_GLASS = 1000) + materials = list(/datum/material/glass = 1000) /datum/design/board/arcade_battle name = "Computer Design (Battle Arcade Machine)" diff --git a/code/modules/research/designs/computer_part_designs.dm b/code/modules/research/designs/computer_part_designs.dm index a8813b726d05..ab487b0aaa49 100644 --- a/code/modules/research/designs/computer_part_designs.dm +++ b/code/modules/research/designs/computer_part_designs.dm @@ -6,7 +6,7 @@ name = "Hard Disk Drive" id = "hdd_basic" build_type = PROTOLATHE - materials = list(MAT_METAL = 400, MAT_GLASS = 100) + materials = list(/datum/material/iron = 400, /datum/material/glass = 100) build_path = /obj/item/computer_hardware/hard_drive category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -15,7 +15,7 @@ name = "Advanced Hard Disk Drive" id = "hdd_advanced" build_type = PROTOLATHE - materials = list(MAT_METAL = 800, MAT_GLASS = 200) + materials = list(/datum/material/iron = 800, /datum/material/glass = 200) build_path = /obj/item/computer_hardware/hard_drive/advanced category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -24,7 +24,7 @@ name = "Super Hard Disk Drive" id = "hdd_super" build_type = PROTOLATHE - materials = list(MAT_METAL = 1600, MAT_GLASS = 400) + materials = list(/datum/material/iron = 1600, /datum/material/glass = 400) build_path = /obj/item/computer_hardware/hard_drive/super category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -33,7 +33,7 @@ name = "Cluster Hard Disk Drive" id = "hdd_cluster" build_type = PROTOLATHE - materials = list(MAT_METAL = 3200, MAT_GLASS = 800) + materials = list(/datum/material/iron = 3200, /datum/material/glass = 800) build_path = /obj/item/computer_hardware/hard_drive/cluster category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -42,7 +42,7 @@ name = "Solid State Drive" id = "ssd_small" build_type = PROTOLATHE - materials = list(MAT_METAL = 800, MAT_GLASS = 200) + materials = list(/datum/material/iron = 800, /datum/material/glass = 200) build_path = /obj/item/computer_hardware/hard_drive/small category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -51,7 +51,7 @@ name = "Micro Solid State Drive" id = "ssd_micro" build_type = PROTOLATHE - materials = list(MAT_METAL = 400, MAT_GLASS = 100) + materials = list(/datum/material/iron = 400, /datum/material/glass = 100) build_path = /obj/item/computer_hardware/hard_drive/micro category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -61,7 +61,7 @@ name = "Network Card" id = "netcard_basic" build_type = IMPRINTER - materials = list(MAT_METAL = 250, MAT_GLASS = 100) + materials = list(/datum/material/iron = 250, /datum/material/glass = 100) build_path = /obj/item/computer_hardware/network_card category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -70,7 +70,7 @@ name = "Advanced Network Card" id = "netcard_advanced" build_type = IMPRINTER - materials = list(MAT_METAL = 500, MAT_GLASS = 200) + materials = list(/datum/material/iron = 500, /datum/material/glass = 200) build_path = /obj/item/computer_hardware/network_card/advanced category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -79,7 +79,7 @@ name = "Wired Network Card" id = "netcard_wired" build_type = IMPRINTER - materials = list(MAT_METAL = 2500, MAT_GLASS = 400) + materials = list(/datum/material/iron = 2500, /datum/material/glass = 400) build_path = /obj/item/computer_hardware/network_card/wired category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -89,7 +89,7 @@ name = "Data Disk" id = "portadrive_basic" build_type = IMPRINTER - materials = list(MAT_GLASS = 800) + materials = list(/datum/material/glass = 800) build_path = /obj/item/computer_hardware/hard_drive/portable category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -98,7 +98,7 @@ name = "Advanced Data Disk" id = "portadrive_advanced" build_type = IMPRINTER - materials = list(MAT_GLASS = 1600) + materials = list(/datum/material/glass = 1600) build_path = /obj/item/computer_hardware/hard_drive/portable/advanced category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -107,7 +107,7 @@ name = "Super Data Disk" id = "portadrive_super" build_type = IMPRINTER - materials = list(MAT_GLASS = 3200) + materials = list(/datum/material/glass = 3200) build_path = /obj/item/computer_hardware/hard_drive/portable/super category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -117,7 +117,7 @@ name = "ID Card Slot" id = "cardslot" build_type = PROTOLATHE - materials = list(MAT_METAL = 600) + materials = list(/datum/material/iron = 600) build_path = /obj/item/computer_hardware/card_slot category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -127,7 +127,7 @@ name = "Intellicard Slot" id = "aislot" build_type = PROTOLATHE - materials = list(MAT_METAL = 600) + materials = list(/datum/material/iron = 600) build_path = /obj/item/computer_hardware/ai_slot category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -137,7 +137,7 @@ name = "Miniprinter" id = "miniprinter" build_type = PROTOLATHE - materials = list(MAT_METAL = 600) + materials = list(/datum/material/iron = 600) build_path = /obj/item/computer_hardware/printer/mini category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -147,7 +147,7 @@ name = "Area Power Connector" id = "APClink" build_type = PROTOLATHE - materials = list(MAT_METAL = 2000) + materials = list(/datum/material/iron = 2000) build_path = /obj/item/computer_hardware/recharger/APC category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -157,7 +157,7 @@ name = "Power Cell Controller" id = "bat_control" build_type = PROTOLATHE - materials = list(MAT_METAL = 400) + materials = list(/datum/material/iron = 400) build_path = /obj/item/computer_hardware/battery category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -166,7 +166,7 @@ name = "Battery Module" id = "bat_normal" build_type = PROTOLATHE - materials = list(MAT_METAL = 400) + materials = list(/datum/material/iron = 400) build_path = /obj/item/stock_parts/cell/computer category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -175,7 +175,7 @@ name = "Advanced Battery Module" id = "bat_advanced" build_type = PROTOLATHE - materials = list(MAT_METAL = 800) + materials = list(/datum/material/iron = 800) build_path = /obj/item/stock_parts/cell/computer/advanced category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -184,7 +184,7 @@ name = "Super Battery Module" id = "bat_super" build_type = PROTOLATHE - materials = list(MAT_METAL = 1600) + materials = list(/datum/material/iron = 1600) build_path = /obj/item/stock_parts/cell/computer/super category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -193,7 +193,7 @@ name = "Nano Battery Module" id = "bat_nano" build_type = PROTOLATHE - materials = list(MAT_METAL = 200) + materials = list(/datum/material/iron = 200) build_path = /obj/item/stock_parts/cell/computer/nano category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -202,7 +202,7 @@ name = "Micro Battery Module" id = "bat_micro" build_type = PROTOLATHE - materials = list(MAT_METAL = 400) + materials = list(/datum/material/iron = 400) build_path = /obj/item/stock_parts/cell/computer/micro category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -212,7 +212,7 @@ name = "Processor Board" id = "cpu_normal" build_type = IMPRINTER - materials = list(MAT_GLASS = 1600) + materials = list(/datum/material/glass = 1600) build_path = /obj/item/computer_hardware/processor_unit category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -221,7 +221,7 @@ name = "Microprocessor" id = "cpu_small" build_type = IMPRINTER - materials = list(MAT_GLASS = 800) + materials = list(/datum/material/glass = 800) build_path = /obj/item/computer_hardware/processor_unit/small category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -230,7 +230,7 @@ name = "Photonic Processor Board" id = "pcpu_normal" build_type = IMPRINTER - materials = list(MAT_GLASS= 6400, MAT_GOLD = 2000) + materials = list(/datum/material/glass= 6400, /datum/material/gold = 2000) build_path = /obj/item/computer_hardware/processor_unit/photonic category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -239,7 +239,7 @@ name = "Photonic Microprocessor" id = "pcpu_small" build_type = IMPRINTER - materials = list(MAT_GLASS = 3200, MAT_GOLD = 1000) + materials = list(/datum/material/glass = 3200, /datum/material/gold = 1000) build_path = /obj/item/computer_hardware/processor_unit/photonic/small category = list("Computer Parts") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING diff --git a/code/modules/research/designs/electronics_designs.dm b/code/modules/research/designs/electronics_designs.dm index 94766529208f..fe7268e3bcdb 100644 --- a/code/modules/research/designs/electronics_designs.dm +++ b/code/modules/research/designs/electronics_designs.dm @@ -8,7 +8,7 @@ desc = "Allows for the construction of an intellicard." id = "intellicard" build_type = PROTOLATHE - materials = list(MAT_GLASS = 1000, MAT_GOLD = 200) + materials = list(/datum/material/glass = 1000, /datum/material/gold = 200) build_path = /obj/item/aicard category = list("Electronics") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -18,7 +18,7 @@ desc = "Allows for the construction of a pAI Card." id = "paicard" build_type = PROTOLATHE - materials = list(MAT_GLASS = 500, MAT_METAL = 500) + materials = list(/datum/material/glass = 500, /datum/material/iron = 500) build_path = /obj/item/paicard category = list("Electronics") departmental_flags = DEPARTMENTAL_FLAG_ALL @@ -28,7 +28,7 @@ desc = "A software package that will allow an artificial intelligence to 'hear' from its cameras via lip reading." id = "ai_cam_upgrade" build_type = PROTOLATHE - materials = list(MAT_METAL = 5000, MAT_GLASS = 5000, MAT_GOLD = 15000, MAT_SILVER = 15000, MAT_DIAMOND = 20000, MAT_PLASMA = 10000) + materials = list(/datum/material/iron = 5000, /datum/material/glass = 5000, /datum/material/gold = 15000, /datum/material/silver = 15000, /datum/material/diamond = 20000, /datum/material/plasma = 10000) build_path = /obj/item/surveillance_upgrade category = list("Electronics") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -41,7 +41,7 @@ desc = "Allows for the construction of a nanite remote." id = "nanite_remote" build_type = PROTOLATHE - materials = list(MAT_GLASS = 500, MAT_METAL = 500) + materials = list(/datum/material/glass = 500, /datum/material/iron = 500) build_path = /obj/item/nanite_remote category = list("Electronics") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -51,7 +51,7 @@ desc = "Allows for the construction of a nanite communication remote." id = "nanite_comm_remote" build_type = PROTOLATHE - materials = list(MAT_GLASS = 500, MAT_METAL = 500) + materials = list(/datum/material/glass = 500, /datum/material/iron = 500) build_path = /obj/item/nanite_remote/comm category = list("Electronics") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -61,7 +61,7 @@ desc = "Allows for the construction of a nanite scanner." id = "nanite_scanner" build_type = PROTOLATHE - materials = list(MAT_GLASS = 500, MAT_METAL = 500) + materials = list(/datum/material/glass = 500, /datum/material/iron = 500) build_path = /obj/item/nanite_scanner category = list("Electronics") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -75,7 +75,7 @@ desc = "Produce additional disks for storing device designs." id = "design_disk" build_type = PROTOLATHE | AUTOLATHE - materials = list(MAT_METAL = 300, MAT_GLASS = 100) + materials = list(/datum/material/iron = 300, /datum/material/glass = 100) build_path = /obj/item/disk/design_disk category = list("Electronics") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -85,7 +85,7 @@ desc = "Produce additional disks for storing device designs." id = "design_disk_adv" build_type = PROTOLATHE - materials = list(MAT_METAL = 300, MAT_GLASS = 100, MAT_SILVER=50) + materials = list(/datum/material/iron = 300, /datum/material/glass = 100, /datum/material/silver=50) build_path = /obj/item/disk/design_disk/adv category = list("Electronics") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -95,7 +95,7 @@ desc = "Produce additional disks for storing technology data." id = "tech_disk" build_type = PROTOLATHE | AUTOLATHE - materials = list(MAT_METAL = 300, MAT_GLASS = 100) + materials = list(/datum/material/iron = 300, /datum/material/glass = 100) build_path = /obj/item/disk/tech_disk category = list("Electronics") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -105,7 +105,7 @@ desc = "Stores nanite programs." id = "nanite_disk" build_type = PROTOLATHE - materials = list(MAT_METAL = 300, MAT_GLASS = 100) + materials = list(/datum/material/iron = 300, /datum/material/glass = 100) build_path = /obj/item/disk/nanite_program category = list("Electronics") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE diff --git a/code/modules/research/designs/machine_designs.dm b/code/modules/research/designs/machine_designs.dm index 5c1b6c05b917..4dacff75deb4 100644 --- a/code/modules/research/designs/machine_designs.dm +++ b/code/modules/research/designs/machine_designs.dm @@ -430,7 +430,7 @@ name = "Machine Design (Weapon Recharger Board)" desc = "The circuit board for a Weapon Recharger." id = "recharger" - materials = list(MAT_GLASS = 1000, MAT_GOLD = 2000) + materials = list(/datum/material/glass = 1000, /datum/material/gold = 2000) build_path = /obj/item/circuitboard/machine/recharger category = list("Misc. Machinery") departmental_flags = DEPARTMENTAL_FLAG_ALL diff --git a/code/modules/research/designs/mecha_designs.dm b/code/modules/research/designs/mecha_designs.dm index 2b339031c6d6..26969c2edf0b 100644 --- a/code/modules/research/designs/mecha_designs.dm +++ b/code/modules/research/designs/mecha_designs.dm @@ -110,7 +110,7 @@ name = "\"Phazon\" Central Control module" desc = "Allows for the construction of a \"Phazon\" Central Control module." id = "phazon_main" - materials = list(MAT_GLASS = 1000, MAT_BLUESPACE = 100) + materials = list(/datum/material/glass = 1000, /datum/material/bluespace = 100) build_path = /obj/item/circuitboard/mecha/phazon/main category = list("Exosuit Modules") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -119,7 +119,7 @@ name = "\"Phazon\" Peripherals Control module" desc = "Allows for the construction of a \"Phazon\" Peripheral Control module." id = "phazon_peri" - materials = list(MAT_GLASS = 1000, MAT_BLUESPACE = 100) + materials = list(/datum/material/glass = 1000, /datum/material/bluespace = 100) build_path = /obj/item/circuitboard/mecha/phazon/peripherals category = list("Exosuit Modules") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -128,7 +128,7 @@ name = "\"Phazon\" Weapons & Targeting Control module" desc = "Allows for the construction of a \"Phazon\" Weapons & Targeting Control module." id = "phazon_targ" - materials = list(MAT_GLASS = 1000, MAT_BLUESPACE = 100) + materials = list(/datum/material/glass = 1000, /datum/material/bluespace = 100) build_path = /obj/item/circuitboard/mecha/phazon/targeting category = list("Exosuit Modules") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -143,7 +143,7 @@ id = "mech_scattershot" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/weapon/ballistic/scattershot - materials = list(MAT_METAL=10000) + materials = list(/datum/material/iron=10000) construction_time = 100 category = list("Exosuit Equipment") @@ -153,7 +153,7 @@ id = "mech_scattershot_ammo" build_type = PROTOLATHE | MECHFAB build_path = /obj/item/mecha_ammo/scattershot - materials = list(MAT_METAL=6000) + materials = list(/datum/material/iron=6000) construction_time = 20 category = list("Exosuit Ammunition", "Ammo") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -164,7 +164,7 @@ id = "mech_carbine" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/weapon/ballistic/carbine - materials = list(MAT_METAL=10000) + materials = list(/datum/material/iron=10000) construction_time = 100 category = list("Exosuit Equipment") @@ -174,7 +174,7 @@ id = "mech_carbine_ammo" build_type = PROTOLATHE | MECHFAB build_path = /obj/item/mecha_ammo/incendiary - materials = list(MAT_METAL=6000) + materials = list(/datum/material/iron=6000) construction_time = 20 category = list("Exosuit Ammunition", "Ammo") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -185,7 +185,7 @@ id = "mech_ion" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/weapon/energy/ion - materials = list(MAT_METAL=20000,MAT_SILVER=6000,MAT_URANIUM=2000) + materials = list(/datum/material/iron=20000,/datum/material/silver=6000,/datum/material/uranium=2000) construction_time = 100 category = list("Exosuit Equipment") @@ -195,7 +195,7 @@ id = "mech_tesla" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/weapon/energy/tesla - materials = list(MAT_METAL=20000,MAT_SILVER=8000) + materials = list(/datum/material/iron=20000,/datum/material/silver=8000) construction_time = 100 category = list("Exosuit Equipment") @@ -205,7 +205,7 @@ id = "mech_laser" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/weapon/energy/laser - materials = list(MAT_METAL=10000) + materials = list(/datum/material/iron=10000) construction_time = 100 category = list("Exosuit Equipment") @@ -215,7 +215,7 @@ id = "mech_laser_heavy" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/weapon/energy/laser/heavy - materials = list(MAT_METAL=10000) + materials = list(/datum/material/iron=10000) construction_time = 100 category = list("Exosuit Equipment") @@ -225,7 +225,7 @@ id = "mech_xray" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/weapon/energy/laser/xray - materials = list(MAT_METAL=10000,MAT_GOLD = 6000,MAT_URANIUM = 5000,MAT_TITANIUM = 3000,MAT_BLUESPACE = 3000) + materials = list(/datum/material/iron=10000,/datum/material/gold = 6000,/datum/material/uranium = 5000,/datum/material/titanium = 3000,/datum/material/bluespace = 3000) construction_time = 100 category = list("Exosuit Equipment") @@ -235,7 +235,7 @@ id = "mech_disabler" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/weapon/energy/disabler - materials = list(MAT_METAL=10000) + materials = list(/datum/material/iron=10000) construction_time = 100 category = list("Exosuit Equipment") @@ -245,7 +245,7 @@ id = "mech_grenade_launcher" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/weapon/ballistic/launcher/flashbang - materials = list(MAT_METAL=22000,MAT_GOLD=6000,MAT_SILVER=8000) + materials = list(/datum/material/iron=22000,/datum/material/gold=6000,/datum/material/silver=8000) construction_time = 100 category = list("Exosuit Equipment") @@ -255,7 +255,7 @@ id = "mech_grenade_launcher_ammo" build_type = PROTOLATHE | MECHFAB build_path = /obj/item/mecha_ammo/flashbang - materials = list(MAT_METAL=4000,MAT_GOLD=500,MAT_SILVER=500) + materials = list(/datum/material/iron=4000,/datum/material/gold=500,/datum/material/silver=500) construction_time = 20 category = list("Exosuit Ammunition", "Ammo") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -266,7 +266,7 @@ id = "mech_missile_rack" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/weapon/ballistic/missile_rack/breaching - materials = list(MAT_METAL=22000,MAT_GOLD=6000,MAT_SILVER=8000) + materials = list(/datum/material/iron=22000,/datum/material/gold=6000,/datum/material/silver=8000) construction_time = 100 category = list("Exosuit Equipment") @@ -276,18 +276,18 @@ id = "mech_missile_rack_ammo" build_type = PROTOLATHE | MECHFAB build_path = /obj/item/mecha_ammo/missiles_br - materials = list(MAT_METAL=8000,MAT_GOLD=500,MAT_SILVER=500) + materials = list(/datum/material/iron=8000,/datum/material/gold=500,/datum/material/silver=500) construction_time = 20 category = list("Exosuit Ammunition", "Ammo") departmental_flags = DEPARTMENTAL_FLAG_SECURITY /datum/design/clusterbang_launcher - name = "Exosuit Module (SOB-3 Clusterbang Launcher)" + name = "Exosuit Weapon (SOB-3 Clusterbang Launcher)" desc = "A weapon that violates the Geneva Convention at 3 rounds per minute." id = "clusterbang_launcher" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/weapon/ballistic/launcher/flashbang/clusterbang - materials = list(MAT_METAL=20000,MAT_GOLD=10000,MAT_URANIUM=10000) + materials = list(/datum/material/iron=20000,/datum/material/gold=10000,/datum/material/uranium=10000) construction_time = 100 category = list("Exosuit Equipment") @@ -297,7 +297,7 @@ id = "clusterbang_launcher_ammo" build_type = PROTOLATHE | MECHFAB build_path = /obj/item/mecha_ammo/clusterbang - materials = list(MAT_METAL=6000,MAT_GOLD=1500,MAT_URANIUM=1500) + materials = list(/datum/material/iron=6000,/datum/material/gold=1500,/datum/material/uranium=1500) construction_time = 20 category = list("Exosuit Ammunition", "Ammo") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -308,7 +308,7 @@ id = "mech_wormhole_gen" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/wormhole_generator - materials = list(MAT_METAL=10000) + materials = list(/datum/material/iron=10000) construction_time = 100 category = list("Exosuit Equipment") @@ -318,7 +318,7 @@ id = "mech_teleporter" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/teleporter - materials = list(MAT_METAL=10000,MAT_DIAMOND=10000) + materials = list(/datum/material/iron=10000,/datum/material/diamond=10000) construction_time = 100 category = list("Exosuit Equipment") @@ -328,7 +328,7 @@ id = "mech_rcd" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/rcd - materials = list(MAT_METAL=30000,MAT_GOLD=20000,MAT_PLASMA=25000,MAT_SILVER=20000) + materials = list(/datum/material/iron=30000,/datum/material/gold=20000,/datum/material/plasma=25000,/datum/material/silver=20000) construction_time = 1200 category = list("Exosuit Equipment") @@ -338,7 +338,7 @@ id = "mech_gravcatapult" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/gravcatapult - materials = list(MAT_METAL=10000) + materials = list(/datum/material/iron=10000) construction_time = 100 category = list("Exosuit Equipment") @@ -348,7 +348,7 @@ id = "mech_repair_droid" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/repair_droid - materials = list(MAT_METAL=10000,MAT_GLASS=5000,MAT_GOLD=1000,MAT_SILVER=2000) + materials = list(/datum/material/iron=10000,/datum/material/glass=5000,/datum/material/gold=1000,/datum/material/silver=2000) construction_time = 100 category = list("Exosuit Equipment") @@ -358,7 +358,7 @@ id = "mech_energy_relay" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/tesla_energy_relay - materials = list(MAT_METAL=10000,MAT_GLASS=2000,MAT_GOLD=2000,MAT_SILVER=3000) + materials = list(/datum/material/iron=10000,/datum/material/glass=2000,/datum/material/gold=2000,/datum/material/silver=3000) construction_time = 100 category = list("Exosuit Equipment") @@ -368,7 +368,7 @@ id = "mech_ccw_armor" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/anticcw_armor_booster - materials = list(MAT_METAL=20000,MAT_SILVER=5000) + materials = list(/datum/material/iron=20000,/datum/material/silver=5000) construction_time = 100 category = list("Exosuit Equipment") @@ -378,17 +378,17 @@ id = "mech_proj_armor" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/antiproj_armor_booster - materials = list(MAT_METAL=20000,MAT_GOLD=5000) + materials = list(/datum/material/iron=20000,/datum/material/gold=5000) construction_time = 100 category = list("Exosuit Equipment") /datum/design/mech_diamond_drill - name = "Exosuit Module (Diamond Mining Drill)" + name = "Exosuit Mining (Diamond Mining Drill)" desc = "An upgraded version of the standard drill." id = "mech_diamond_drill" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/drill/diamonddrill - materials = list(MAT_METAL=10000,MAT_DIAMOND=6500) + materials = list(/datum/material/iron=10000,/datum/material/diamond=6500) construction_time = 100 category = list("Exosuit Equipment") @@ -398,17 +398,17 @@ id = "mech_generator_nuclear" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/generator/nuclear - materials = list(MAT_METAL=10000,MAT_GLASS=1000,MAT_SILVER=500) + materials = list(/datum/material/iron=10000,/datum/material/glass=1000,/datum/material/silver=500) construction_time = 100 category = list("Exosuit Equipment") /datum/design/mech_plasma_cutter - name = "Exosuit Module Design (217-D Heavy Plasma Cutter)" + name = "Exosuit Mining Design (217-D Heavy Plasma Cutter)" desc = "A device that shoots resonant plasma bursts at extreme velocity. The blasts are capable of crushing rock and demolishing solid obstacles." id = "mech_plasma_cutter" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/weapon/energy/plasma - materials = list(MAT_METAL = 8000, MAT_GLASS = 1000, MAT_PLASMA = 2000) + materials = list(/datum/material/iron = 8000, /datum/material/glass = 1000, /datum/material/plasma = 2000) construction_time = 100 category = list("Exosuit Equipment") @@ -418,7 +418,7 @@ id = "mech_lmg" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/weapon/ballistic/lmg - materials = list(MAT_METAL=10000) + materials = list(/datum/material/iron=10000) construction_time = 100 category = list("Exosuit Equipment") @@ -428,28 +428,28 @@ id = "mech_lmg_ammo" build_type = PROTOLATHE | MECHFAB build_path = /obj/item/mecha_ammo/lmg - materials = list(MAT_METAL=4000) + materials = list(/datum/material/iron=4000) construction_time = 20 category = list("Exosuit Ammunition", "Ammo") departmental_flags = DEPARTMENTAL_FLAG_SECURITY /datum/design/mech_sleeper - name = "Exosuit Medical Equipment (Mounted Sleeper)" + name = "Exosuit Medical (Mounted Sleeper)" desc = "Equipment for medical exosuits. A mounted sleeper that stabilizes patients and can inject reagents in the exosuit's reserves." id = "mech_sleeper" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/medical/sleeper - materials = list(MAT_METAL=5000,MAT_GLASS=10000) + materials = list(/datum/material/iron=5000,/datum/material/glass=10000) construction_time = 100 category = list("Exosuit Equipment") /datum/design/mech_syringe_gun - name = "Exosuit Medical Equipment (Syringe Gun)" + name = "Exosuit Medical (Syringe Gun)" desc = "Equipment for medical exosuits. A chem synthesizer with a syringe gun. Reagents inside are held in stasis, so no reactions will occur." id = "mech_syringe_gun" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/medical/syringe_gun - materials = list(MAT_METAL=3000,MAT_GLASS=2000) + materials = list(/datum/material/iron=3000,/datum/material/glass=2000) construction_time = 200 category = list("Exosuit Equipment") @@ -458,7 +458,7 @@ desc = "Equipment for medical exosuits. A mounted medical nanite projector which will treat patients with a focused beam." id = "mech_medi_beam" build_type = MECHFAB - materials = list(MAT_METAL = 15000, MAT_GLASS = 8000, MAT_PLASMA = 3000, MAT_GOLD = 8000, MAT_DIAMOND = 2000) + materials = list(/datum/material/iron = 15000, /datum/material/glass = 8000, /datum/material/plasma = 3000, /datum/material/gold = 8000, /datum/material/diamond = 2000) construction_time = 250 build_path = /obj/item/mecha_parts/mecha_equipment/medical/mechmedbeam category = list("Exosuit Equipment") diff --git a/code/modules/research/designs/mechfabricator_designs.dm b/code/modules/research/designs/mechfabricator_designs.dm index 4ad97a4a7641..6f29be719474 100644 --- a/code/modules/research/designs/mechfabricator_designs.dm +++ b/code/modules/research/designs/mechfabricator_designs.dm @@ -4,7 +4,7 @@ id = "borg_suit" build_type = MECHFAB build_path = /obj/item/robot_suit - materials = list(MAT_METAL=15000) + materials = list(/datum/material/iron=15000) construction_time = 500 category = list("Cyborg") @@ -13,7 +13,7 @@ id = "borg_chest" build_type = MECHFAB build_path = /obj/item/bodypart/chest/robot - materials = list(MAT_METAL=40000) + materials = list(/datum/material/iron=40000) construction_time = 350 category = list("Cyborg") @@ -22,7 +22,7 @@ id = "borg_head" build_type = MECHFAB build_path = /obj/item/bodypart/head/robot - materials = list(MAT_METAL=5000) + materials = list(/datum/material/iron=5000) construction_time = 350 category = list("Cyborg") @@ -31,7 +31,7 @@ id = "borg_l_arm" build_type = MECHFAB build_path = /obj/item/bodypart/l_arm/robot - materials = list(MAT_METAL=10000) + materials = list(/datum/material/iron=10000) construction_time = 200 category = list("Cyborg") @@ -40,7 +40,7 @@ id = "borg_r_arm" build_type = MECHFAB build_path = /obj/item/bodypart/r_arm/robot - materials = list(MAT_METAL=10000) + materials = list(/datum/material/iron=10000) construction_time = 200 category = list("Cyborg") @@ -49,7 +49,7 @@ id = "borg_l_leg" build_type = MECHFAB build_path = /obj/item/bodypart/l_leg/robot - materials = list(MAT_METAL=10000) + materials = list(/datum/material/iron=10000) construction_time = 200 category = list("Cyborg") @@ -58,7 +58,7 @@ id = "borg_r_leg" build_type = MECHFAB build_path = /obj/item/bodypart/r_leg/robot - materials = list(MAT_METAL=10000) + materials = list(/datum/material/iron=10000) construction_time = 200 category = list("Cyborg") @@ -68,7 +68,7 @@ id = "ripley_chassis" build_type = MECHFAB build_path = /obj/item/mecha_parts/chassis/ripley - materials = list(MAT_METAL=20000) + materials = list(/datum/material/iron=20000) construction_time = 100 category = list("Ripley") @@ -78,7 +78,7 @@ id = "firefighter_chassis" build_type = MECHFAB build_path = /obj/item/mecha_parts/chassis/firefighter - materials = list(MAT_METAL=20000) + materials = list(/datum/material/iron=20000) construction_time = 100 category = list("Firefighter") @@ -87,7 +87,7 @@ id = "ripley_torso" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/ripley_torso - materials = list(MAT_METAL=20000, MAT_GLASS=7500) + materials = list(/datum/material/iron=20000, /datum/material/glass=7500) construction_time = 200 category = list("Ripley","Firefighter") @@ -96,7 +96,7 @@ id = "ripley_left_arm" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/ripley_left_arm - materials = list(MAT_METAL=15000) + materials = list(/datum/material/iron=15000) construction_time = 150 category = list("Ripley","Firefighter") @@ -105,7 +105,7 @@ id = "ripley_right_arm" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/ripley_right_arm - materials = list(MAT_METAL=15000) + materials = list(/datum/material/iron=15000) construction_time = 150 category = list("Ripley","Firefighter") @@ -114,7 +114,7 @@ id = "ripley_left_leg" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/ripley_left_leg - materials = list(MAT_METAL=15000) + materials = list(/datum/material/iron=15000) construction_time = 150 category = list("Ripley","Firefighter") @@ -123,7 +123,7 @@ id = "ripley_right_leg" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/ripley_right_leg - materials = list(MAT_METAL=15000) + materials = list(/datum/material/iron=15000) construction_time = 150 category = list("Ripley","Firefighter") @@ -133,7 +133,7 @@ id = "odysseus_chassis" build_type = MECHFAB build_path = /obj/item/mecha_parts/chassis/odysseus - materials = list(MAT_METAL=20000) + materials = list(/datum/material/iron=20000) construction_time = 100 category = list("Odysseus") @@ -142,7 +142,7 @@ id = "odysseus_torso" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/odysseus_torso - materials = list(MAT_METAL=12000) + materials = list(/datum/material/iron=12000) construction_time = 180 category = list("Odysseus") @@ -151,7 +151,7 @@ id = "odysseus_head" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/odysseus_head - materials = list(MAT_METAL=6000,MAT_GLASS=10000) + materials = list(/datum/material/iron=6000,/datum/material/glass=10000) construction_time = 100 category = list("Odysseus") @@ -160,7 +160,7 @@ id = "odysseus_left_arm" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/odysseus_left_arm - materials = list(MAT_METAL=6000) + materials = list(/datum/material/iron=6000) construction_time = 120 category = list("Odysseus") @@ -169,7 +169,7 @@ id = "odysseus_right_arm" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/odysseus_right_arm - materials = list(MAT_METAL=6000) + materials = list(/datum/material/iron=6000) construction_time = 120 category = list("Odysseus") @@ -178,7 +178,7 @@ id = "odysseus_left_leg" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/odysseus_left_leg - materials = list(MAT_METAL=7000) + materials = list(/datum/material/iron=7000) construction_time = 130 category = list("Odysseus") @@ -187,7 +187,7 @@ id = "odysseus_right_leg" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/odysseus_right_leg - materials = list(MAT_METAL=7000) + materials = list(/datum/material/iron=7000) construction_time = 130 category = list("Odysseus") @@ -197,7 +197,7 @@ id = "gygax_chassis" build_type = MECHFAB build_path = /obj/item/mecha_parts/chassis/gygax - materials = list(MAT_METAL=20000) + materials = list(/datum/material/iron=20000) construction_time = 100 category = list("Gygax") @@ -206,7 +206,7 @@ id = "gygax_torso" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/gygax_torso - materials = list(MAT_METAL=20000,MAT_GLASS=10000,MAT_DIAMOND=2000) + materials = list(/datum/material/iron=20000,/datum/material/glass=10000,/datum/material/diamond=2000) construction_time = 300 category = list("Gygax") @@ -215,7 +215,7 @@ id = "gygax_head" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/gygax_head - materials = list(MAT_METAL=10000,MAT_GLASS=5000, MAT_DIAMOND=2000) + materials = list(/datum/material/iron=10000,/datum/material/glass=5000, /datum/material/diamond=2000) construction_time = 200 category = list("Gygax") @@ -224,7 +224,7 @@ id = "gygax_left_arm" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/gygax_left_arm - materials = list(MAT_METAL=15000, MAT_DIAMOND=1000) + materials = list(/datum/material/iron=15000, /datum/material/diamond=1000) construction_time = 200 category = list("Gygax") @@ -233,7 +233,7 @@ id = "gygax_right_arm" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/gygax_right_arm - materials = list(MAT_METAL=15000, MAT_DIAMOND=1000) + materials = list(/datum/material/iron=15000, /datum/material/diamond=1000) construction_time = 200 category = list("Gygax") @@ -242,7 +242,7 @@ id = "gygax_left_leg" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/gygax_left_leg - materials = list(MAT_METAL=15000, MAT_DIAMOND=2000) + materials = list(/datum/material/iron=15000, /datum/material/diamond=2000) construction_time = 200 category = list("Gygax") @@ -251,7 +251,7 @@ id = "gygax_right_leg" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/gygax_right_leg - materials = list(MAT_METAL=15000, MAT_DIAMOND=2000) + materials = list(/datum/material/iron=15000, /datum/material/diamond=2000) construction_time = 200 category = list("Gygax") @@ -260,7 +260,7 @@ id = "gygax_armor" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/gygax_armor - materials = list(MAT_METAL=15000,MAT_DIAMOND=10000,MAT_TITANIUM=10000) + materials = list(/datum/material/iron=15000,/datum/material/diamond=10000,/datum/material/titanium=10000) construction_time = 600 category = list("Gygax") @@ -270,7 +270,7 @@ id = "durand_chassis" build_type = MECHFAB build_path = /obj/item/mecha_parts/chassis/durand - materials = list(MAT_METAL=25000) + materials = list(/datum/material/iron=25000) construction_time = 100 category = list("Durand") @@ -279,7 +279,7 @@ id = "durand_torso" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/durand_torso - materials = list(MAT_METAL=25000,MAT_GLASS=10000,MAT_SILVER=10000) + materials = list(/datum/material/iron=25000,/datum/material/glass=10000,/datum/material/silver=10000) construction_time = 300 category = list("Durand") @@ -288,7 +288,7 @@ id = "durand_head" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/durand_head - materials = list(MAT_METAL=10000,MAT_GLASS=15000,MAT_SILVER=2000) + materials = list(/datum/material/iron=10000,/datum/material/glass=15000,/datum/material/silver=2000) construction_time = 200 category = list("Durand") @@ -297,7 +297,7 @@ id = "durand_left_arm" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/durand_left_arm - materials = list(MAT_METAL=10000,MAT_SILVER=4000) + materials = list(/datum/material/iron=10000,/datum/material/silver=4000) construction_time = 200 category = list("Durand") @@ -306,7 +306,7 @@ id = "durand_right_arm" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/durand_right_arm - materials = list(MAT_METAL=10000,MAT_SILVER=4000) + materials = list(/datum/material/iron=10000,/datum/material/silver=4000) construction_time = 200 category = list("Durand") @@ -315,7 +315,7 @@ id = "durand_left_leg" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/durand_left_leg - materials = list(MAT_METAL=15000,MAT_SILVER=4000) + materials = list(/datum/material/iron=15000,/datum/material/silver=4000) construction_time = 200 category = list("Durand") @@ -324,7 +324,7 @@ id = "durand_right_leg" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/durand_right_leg - materials = list(MAT_METAL=15000,MAT_SILVER=4000) + materials = list(/datum/material/iron=15000,/datum/material/silver=4000) construction_time = 200 category = list("Durand") @@ -333,7 +333,7 @@ id = "durand_armor" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/durand_armor - materials = list(MAT_METAL=30000,MAT_URANIUM=25000,MAT_TITANIUM=20000) + materials = list(/datum/material/iron=30000,/datum/material/uranium=25000,/datum/material/titanium=20000) construction_time = 600 category = list("Durand") @@ -343,7 +343,7 @@ id = "honk_chassis" build_type = MECHFAB build_path = /obj/item/mecha_parts/chassis/honker - materials = list(MAT_METAL=20000) + materials = list(/datum/material/iron=20000) construction_time = 100 category = list("H.O.N.K") @@ -352,7 +352,7 @@ id = "honk_torso" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/honker_torso - materials = list(MAT_METAL=20000,MAT_GLASS=10000,MAT_BANANIUM=10000) + materials = list(/datum/material/iron=20000,/datum/material/glass=10000,/datum/material/bananium=10000) construction_time = 300 category = list("H.O.N.K") @@ -361,7 +361,7 @@ id = "honk_head" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/honker_head - materials = list(MAT_METAL=10000,MAT_GLASS=5000,MAT_BANANIUM=5000) + materials = list(/datum/material/iron=10000,/datum/material/glass=5000,/datum/material/bananium=5000) construction_time = 200 category = list("H.O.N.K") @@ -370,7 +370,7 @@ id = "honk_left_arm" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/honker_left_arm - materials = list(MAT_METAL=15000,MAT_BANANIUM=5000) + materials = list(/datum/material/iron=15000,/datum/material/bananium=5000) construction_time = 200 category = list("H.O.N.K") @@ -379,7 +379,7 @@ id = "honk_right_arm" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/honker_right_arm - materials = list(MAT_METAL=15000,MAT_BANANIUM=5000) + materials = list(/datum/material/iron=15000,/datum/material/bananium=5000) construction_time = 200 category = list("H.O.N.K") @@ -388,7 +388,7 @@ id = "honk_left_leg" build_type = MECHFAB build_path =/obj/item/mecha_parts/part/honker_left_leg - materials = list(MAT_METAL=20000,MAT_BANANIUM=5000) + materials = list(/datum/material/iron=20000,/datum/material/bananium=5000) construction_time = 200 category = list("H.O.N.K") @@ -397,7 +397,7 @@ id = "honk_right_leg" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/honker_right_leg - materials = list(MAT_METAL=20000,MAT_BANANIUM=5000) + materials = list(/datum/material/iron=20000,/datum/material/bananium=5000) construction_time = 200 category = list("H.O.N.K") @@ -408,7 +408,7 @@ id = "phazon_chassis" build_type = MECHFAB build_path = /obj/item/mecha_parts/chassis/phazon - materials = list(MAT_METAL=20000) + materials = list(/datum/material/iron=20000) construction_time = 100 category = list("Phazon") @@ -417,7 +417,7 @@ id = "phazon_torso" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/phazon_torso - materials = list(MAT_METAL=35000,MAT_GLASS=10000,MAT_PLASMA=20000) + materials = list(/datum/material/iron=35000,/datum/material/glass=10000,/datum/material/plasma=20000) construction_time = 300 category = list("Phazon") @@ -426,7 +426,7 @@ id = "phazon_head" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/phazon_head - materials = list(MAT_METAL=15000,MAT_GLASS=5000,MAT_PLASMA=10000) + materials = list(/datum/material/iron=15000,/datum/material/glass=5000,/datum/material/plasma=10000) construction_time = 200 category = list("Phazon") @@ -435,7 +435,7 @@ id = "phazon_left_arm" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/phazon_left_arm - materials = list(MAT_METAL=20000,MAT_PLASMA=10000) + materials = list(/datum/material/iron=20000,/datum/material/plasma=10000) construction_time = 200 category = list("Phazon") @@ -444,7 +444,7 @@ id = "phazon_right_arm" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/phazon_right_arm - materials = list(MAT_METAL=20000,MAT_PLASMA=10000) + materials = list(/datum/material/iron=20000,/datum/material/plasma=10000) construction_time = 200 category = list("Phazon") @@ -453,7 +453,7 @@ id = "phazon_left_leg" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/phazon_left_leg - materials = list(MAT_METAL=20000,MAT_PLASMA=10000) + materials = list(/datum/material/iron=20000,/datum/material/plasma=10000) construction_time = 200 category = list("Phazon") @@ -462,7 +462,7 @@ id = "phazon_right_leg" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/phazon_right_leg - materials = list(MAT_METAL=20000,MAT_PLASMA=10000) + materials = list(/datum/material/iron=20000,/datum/material/plasma=10000) construction_time = 200 category = list("Phazon") @@ -471,53 +471,53 @@ id = "phazon_armor" build_type = MECHFAB build_path = /obj/item/mecha_parts/part/phazon_armor - materials = list(MAT_METAL=25000,MAT_PLASMA=20000,MAT_TITANIUM=20000) + materials = list(/datum/material/iron=25000,/datum/material/plasma=20000,/datum/material/titanium=20000) construction_time = 300 category = list("Phazon") //Exosuit Equipment /datum/design/ripleyupgrade - name = "Ripley MK-1 to MK-II conversion kit" + name = "Ripley MK-I to MK-II conversion kit" id = "ripleyupgrade" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/ripleyupgrade - materials = list(MAT_METAL=10000,MAT_PLASMA=10000) + materials = list(/datum/material/iron=10000,/datum/material/plasma=10000) construction_time = 100 category = list("Exosuit Equipment") /datum/design/mech_hydraulic_clamp - name = "Exosuit Engineering Equipment (Hydraulic Clamp)" + name = "Exosuit Engineering (Hydraulic Clamp)" id = "mech_hydraulic_clamp" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/hydraulic_clamp - materials = list(MAT_METAL=10000) + materials = list(/datum/material/iron=10000) construction_time = 100 category = list("Exosuit Equipment") /datum/design/mech_drill - name = "Exosuit Engineering Equipment (Drill)" + name = "Exosuit Mining (Mining Drill)" id = "mech_drill" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/drill - materials = list(MAT_METAL=10000) + materials = list(/datum/material/iron=10000) construction_time = 100 category = list("Exosuit Equipment") /datum/design/mech_mining_scanner - name = "Exosuit Engineering Equipment (Mining Scanner)" + name = "Exosuit Mining (Mining Scanner)" id = "mech_mscanner" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/mining_scanner - materials = list(MAT_METAL=5000,MAT_GLASS=2500) + materials = list(/datum/material/iron=5000,/datum/material/glass=2500) construction_time = 50 category = list("Exosuit Equipment") /datum/design/mech_extinguisher - name = "Exosuit Engineering Equipment (Extinguisher)" + name = "Exosuit Engineering (Extinguisher)" id = "mech_extinguisher" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/extinguisher - materials = list(MAT_METAL=10000) + materials = list(/datum/material/iron=10000) construction_time = 100 category = list("Exosuit Equipment") @@ -526,52 +526,52 @@ id = "mech_cable_layer" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/cable_layer - materials = list(MAT_METAL=10000) + materials = list(/datum/material/iron=10000) construction_time = 100 category = list("Exosuit Equipment") /datum/design/mech_generator - name = "Exosuit Equipment (Plasma Generator)" + name = "Exosuit Module (Plasma Generator)" id = "mech_generator" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/generator - materials = list(MAT_METAL=10000,MAT_GLASS=1000,MAT_SILVER=2000,MAT_PLASMA=5000) + materials = list(/datum/material/iron=10000,/datum/material/glass=1000,/datum/material/silver=2000,/datum/material/plasma=5000) construction_time = 100 category = list("Exosuit Equipment") /datum/design/mech_mousetrap_mortar - name = "H.O.N.K Mousetrap Mortar" + name = "H.O.N.K Weapon (Mousetrap Mortar)" id = "mech_mousetrap_mortar" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/weapon/ballistic/launcher/mousetrap_mortar - materials = list(MAT_METAL=20000,MAT_BANANIUM=5000) + materials = list(/datum/material/iron=20000,/datum/material/bananium=5000) construction_time = 300 category = list("Exosuit Equipment") /datum/design/mech_banana_mortar - name = "H.O.N.K Banana Mortar" + name = "H.O.N.K Weapon (Banana Mortar)" id = "mech_banana_mortar" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/weapon/ballistic/launcher/banana_mortar - materials = list(MAT_METAL=20000,MAT_BANANIUM=5000) + materials = list(/datum/material/iron=20000,/datum/material/bananium=5000) construction_time = 300 category = list("Exosuit Equipment") /datum/design/mech_honker - name = "HoNkER BlAsT 5000" + name = "H.O.N.K Weapon (HoNkER BlAsT 5000)" id = "mech_honker" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/weapon/honker - materials = list(MAT_METAL=20000,MAT_BANANIUM=10000) + materials = list(/datum/material/iron=20000,/datum/material/bananium=10000) construction_time = 500 category = list("Exosuit Equipment") /datum/design/mech_punching_glove - name = "Oingo Boingo Punch-face" + name = "H.O.N.K Weapon (Oingo Boingo Punch-face)" id = "mech_punching_face" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_equipment/weapon/ballistic/launcher/punching_glove - materials = list(MAT_METAL=20000,MAT_BANANIUM=7500) + materials = list(/datum/material/iron=20000,/datum/material/bananium=7500) construction_time = 400 category = list("Exosuit Equipment") @@ -584,7 +584,7 @@ id = "borg_upgrade_rename" build_type = MECHFAB build_path = /obj/item/borg/upgrade/rename - materials = list(MAT_METAL = 5000) + materials = list(/datum/material/iron = 5000) construction_time = 120 category = list("Cyborg Upgrade Modules") @@ -593,7 +593,7 @@ id = "borg_upgrade_restart" build_type = MECHFAB build_path = /obj/item/borg/upgrade/restart - materials = list(MAT_METAL = 20000 , MAT_GLASS = 5000) + materials = list(/datum/material/iron = 20000 , /datum/material/glass = 5000) construction_time = 120 category = list("Cyborg Upgrade Modules") @@ -602,7 +602,7 @@ id = "borg_upgrade_vtec" build_type = MECHFAB build_path = /obj/item/borg/upgrade/vtec - materials = list(MAT_METAL= 35000 , MAT_GLASS = 12000 , MAT_URANIUM = 10000) + materials = list(/datum/material/iron= 35000 , /datum/material/glass = 12000 , /datum/material/uranium = 10000) construction_time = 80 category = list("Cyborg Upgrade Modules") @@ -611,7 +611,7 @@ id = "borg_upgrade_thrusters" build_type = MECHFAB build_path = /obj/item/borg/upgrade/thrusters - materials = list(MAT_METAL = 10000, MAT_GLASS = 6000, MAT_PLASMA = 5000, MAT_URANIUM = 6000) + materials = list(/datum/material/iron = 10000, /datum/material/glass = 6000, /datum/material/plasma = 5000, /datum/material/uranium = 6000) construction_time = 120 category = list("Cyborg Upgrade Modules") @@ -620,7 +620,7 @@ id = "borg_upgrade_disablercooler" build_type = MECHFAB build_path = /obj/item/borg/upgrade/disablercooler - materials = list(MAT_METAL = 20000 , MAT_GLASS = 6000, MAT_GOLD = 2000, MAT_DIAMOND = 2000) + materials = list(/datum/material/iron = 20000 , /datum/material/glass = 6000, /datum/material/gold = 2000, /datum/material/diamond = 2000) construction_time = 120 category = list("Cyborg Upgrade Modules") @@ -629,7 +629,7 @@ id = "borg_upgrade_diamonddrill" build_type = MECHFAB build_path = /obj/item/borg/upgrade/ddrill - materials = list(MAT_METAL=10000, MAT_GLASS = 6000, MAT_DIAMOND = 2000) + materials = list(/datum/material/iron=10000, /datum/material/glass = 6000, /datum/material/diamond = 2000) construction_time = 80 category = list("Cyborg Upgrade Modules") @@ -638,7 +638,7 @@ id = "borg_upgrade_holding" build_type = MECHFAB build_path = /obj/item/borg/upgrade/soh - materials = list(MAT_METAL = 10000, MAT_GOLD = 2000, MAT_URANIUM = 1000) + materials = list(/datum/material/iron = 10000, /datum/material/gold = 2000, /datum/material/uranium = 1000) construction_time = 40 category = list("Cyborg Upgrade Modules") @@ -647,7 +647,7 @@ id = "borg_upgrade_lavaproof" build_type = MECHFAB build_path = /obj/item/borg/upgrade/lavaproof - materials = list(MAT_METAL = 10000, MAT_PLASMA = 4000, MAT_TITANIUM = 5000) + materials = list(/datum/material/iron = 10000, /datum/material/plasma = 4000, /datum/material/titanium = 5000) construction_time = 120 category = list("Cyborg Upgrade Modules") @@ -656,7 +656,7 @@ id = "borg_upgrade_plasmacutter" build_type = MECHFAB build_path = /obj/item/borg/upgrade/plasmacutter - materials = list(MAT_METAL = 3000, MAT_GLASS = 1000, MAT_PLASMA = 2000, MAT_GOLD = 500) + materials = list(/datum/material/iron = 3000, /datum/material/glass = 1000, /datum/material/plasma = 2000, /datum/material/gold = 500) construction_time = 80 category = list("Cyborg Upgrade Modules") @@ -665,7 +665,7 @@ id = "borg_syndicate_module" build_type = MECHFAB build_path = /obj/item/borg/upgrade/syndicate - materials = list(MAT_METAL = 15000, MAT_GLASS = 15000, MAT_DIAMOND = 10000) + materials = list(/datum/material/iron = 15000, /datum/material/glass = 15000, /datum/material/diamond = 10000) construction_time = 120 category = list("Cyborg Upgrade Modules") @@ -674,7 +674,7 @@ id = "borg_transform_clown" build_type = MECHFAB build_path = /obj/item/borg/upgrade/transform/clown - materials = list(MAT_METAL = 15000, MAT_GLASS = 15000, MAT_BANANIUM = 1000) + materials = list(/datum/material/iron = 15000, /datum/material/glass = 15000, /datum/material/bananium = 1000) construction_time = 120 category = list("Cyborg Upgrade Modules") @@ -683,7 +683,7 @@ id = "borg_transform_security" build_type = MECHFAB build_path = /obj/item/borg/upgrade/transform/security - materials = list(MAT_METAL = 15000, MAT_GLASS = 15000, MAT_URANIUM = 3000) + materials = list(/datum/material/iron = 15000, /datum/material/glass = 15000, /datum/material/uranium = 3000) construction_time = 120 category = list("Cyborg Upgrade Modules") @@ -692,7 +692,7 @@ id = "borg_upgrade_selfrepair" build_type = MECHFAB build_path = /obj/item/borg/upgrade/selfrepair - materials = list(MAT_METAL = 15000, MAT_GLASS = 15000) + materials = list(/datum/material/iron = 15000, /datum/material/glass = 15000) construction_time = 80 category = list("Cyborg Upgrade Modules") @@ -701,7 +701,7 @@ id = "borg_upgrade_expandedsynthesiser" build_type = MECHFAB build_path = /obj/item/borg/upgrade/hypospray/expanded - materials = list(MAT_METAL = 15000, MAT_GLASS = 15000, MAT_PLASMA = 8000, MAT_URANIUM = 8000) + materials = list(/datum/material/iron = 15000, /datum/material/glass = 15000, /datum/material/plasma = 8000, /datum/material/uranium = 8000) construction_time = 80 category = list("Cyborg Upgrade Modules") @@ -710,7 +710,7 @@ id = "borg_upgrade_piercinghypospray" build_type = MECHFAB build_path = /obj/item/borg/upgrade/piercing_hypospray - materials = list(MAT_METAL = 15000, MAT_GLASS = 15000, MAT_TITANIUM = 5000, MAT_DIAMOND = 3000) + materials = list(/datum/material/iron = 15000, /datum/material/glass = 15000, /datum/material/titanium = 5000, /datum/material/diamond = 3000) construction_time = 80 category = list("Cyborg Upgrade Modules") @@ -719,7 +719,7 @@ id = "borg_upgrade_defibrillator" build_type = MECHFAB build_path = /obj/item/borg/upgrade/defib - materials = list(MAT_METAL = 8000, MAT_GLASS = 5000, MAT_SILVER = 4000, MAT_GOLD = 3000) + materials = list(/datum/material/iron = 8000, /datum/material/glass = 5000, /datum/material/silver = 4000, /datum/material/gold = 3000) construction_time = 80 category = list("Cyborg Upgrade Modules") @@ -728,7 +728,7 @@ id = "borg_upgrade_surgicalprocessor" build_type = MECHFAB build_path = /obj/item/borg/upgrade/processor - materials = list(MAT_METAL = 5000, MAT_GLASS = 4000, MAT_SILVER = 4000) + materials = list(/datum/material/iron = 5000, /datum/material/glass = 4000, /datum/material/silver = 4000) construction_time = 40 category = list("Cyborg Upgrade Modules") @@ -737,7 +737,7 @@ id = "borg_upgrade_trashofholding" build_type = MECHFAB build_path = /obj/item/borg/upgrade/tboh - materials = list(MAT_GOLD = 2000, MAT_URANIUM = 1000) + materials = list(/datum/material/gold = 2000, /datum/material/uranium = 1000) construction_time = 40 category = list("Cyborg Upgrade Modules") @@ -746,7 +746,7 @@ id = "borg_upgrade_advancedmop" build_type = MECHFAB build_path = /obj/item/borg/upgrade/amop - materials = list(MAT_METAL = 2000, MAT_GLASS = 2000) + materials = list(/datum/material/iron = 2000, /datum/material/glass = 2000) construction_time = 40 category = list("Cyborg Upgrade Modules") @@ -755,7 +755,7 @@ id = "borg_upgrade_expand" build_type = MECHFAB build_path = /obj/item/borg/upgrade/expand - materials = list(MAT_METAL = 200000, MAT_TITANIUM = 5000) + materials = list(/datum/material/iron = 200000, /datum/material/titanium = 5000) construction_time = 120 category = list("Cyborg Upgrade Modules") @@ -764,16 +764,17 @@ id = "borg_ai_control" build_type = MECHFAB build_path = /obj/item/borg/upgrade/ai - materials = list(MAT_METAL = 1200, MAT_GLASS = 1500, MAT_GOLD = 200) + materials = list(/datum/material/iron = 1200, /datum/material/glass = 1500, /datum/material/gold = 200) construction_time = 50 - category = list("Misc") + category = list("Control Interfaces") + search_metadata = "boris" /datum/design/borg_upgrade_rped name = "Cyborg Upgrade (RPED)" id = "borg_upgrade_rped" build_type = MECHFAB build_path = /obj/item/borg/upgrade/rped - materials = list(MAT_METAL = 10000, MAT_GLASS = 5000) + materials = list(/datum/material/iron = 10000, /datum/material/glass = 5000) construction_time = 120 category = list("Cyborg Upgrade Modules") @@ -782,35 +783,35 @@ id = "borg_upgrade_pinpointer" build_type = MECHFAB build_path = /obj/item/borg/upgrade/pinpointer - materials = list(MAT_METAL = 1000, MAT_GLASS = 500) + materials = list(/datum/material/iron = 1000, /datum/material/glass = 500) construction_time = 120 category = list("Cyborg Upgrade Modules") //Misc /datum/design/mecha_tracking - name = "Exosuit Tracking Beacon" + name = "Exosuit Tracker (Exosuit Tracking Beacon)" id = "mecha_tracking" build_type = MECHFAB build_path =/obj/item/mecha_parts/mecha_tracking - materials = list(MAT_METAL=500) + materials = list(/datum/material/iron=500) construction_time = 50 - category = list("Misc") + category = list("Exosuit Equipment") /datum/design/mecha_tracking_ai_control name = "AI Control Beacon" id = "mecha_tracking_ai_control" build_type = MECHFAB build_path = /obj/item/mecha_parts/mecha_tracking/ai_control - materials = list(MAT_METAL = 1000, MAT_GLASS = 500, MAT_SILVER = 200) + materials = list(/datum/material/iron = 1000, /datum/material/glass = 500, /datum/material/silver = 200) construction_time = 50 - category = list("Misc") + category = list("Control Interfaces") /datum/design/synthetic_flash name = "Flash" desc = "When a problem arises, SCIENCE is the solution." id = "sflash" build_type = MECHFAB - materials = list(MAT_METAL = 750, MAT_GLASS = 750) + materials = list(/datum/material/iron = 750, /datum/material/glass = 750) construction_time = 100 build_path = /obj/item/assembly/flash/handheld - category = list("Misc") + category = list("Misc") \ No newline at end of file diff --git a/code/modules/research/designs/medical_designs.dm b/code/modules/research/designs/medical_designs.dm index e80d33b666a2..98766b9913ff 100644 --- a/code/modules/research/designs/medical_designs.dm +++ b/code/modules/research/designs/medical_designs.dm @@ -7,10 +7,10 @@ desc = "The warrior's bland acronym, MMI, obscures the true horror of this monstrosity." id = "mmi" build_type = PROTOLATHE | MECHFAB - materials = list(MAT_METAL = 1000, MAT_GLASS = 500) + materials = list(/datum/material/iron = 1000, /datum/material/glass = 500) construction_time = 75 build_path = /obj/item/mmi - category = list("Misc","Medical Designs") + category = list("Control Interfaces", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL | DEPARTMENTAL_FLAG_SCIENCE /datum/design/posibrain @@ -18,10 +18,10 @@ desc = "The latest in Artificial Intelligence." id = "mmi_posi" build_type = PROTOLATHE | MECHFAB - materials = list(MAT_METAL = 1700, MAT_GLASS = 1350, MAT_GOLD = 500) //Gold, because SWAG. + materials = list(/datum/material/iron = 1700, /datum/material/glass = 1350, /datum/material/gold = 500) //Gold, because SWAG. construction_time = 75 build_path = /obj/item/mmi/posibrain - category = list("Misc", "Medical Designs") + category = list("Control Interfaces", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL | DEPARTMENTAL_FLAG_SCIENCE /datum/design/bluespacebeaker @@ -29,7 +29,7 @@ desc = "A bluespace beaker, powered by experimental bluespace technology and Element Cuban combined with the Compound Pete. Can hold up to 300 units." id = "bluespacebeaker" build_type = PROTOLATHE - materials = list(MAT_GLASS = 5000, MAT_PLASMA = 3000, MAT_DIAMOND = 1000, MAT_BLUESPACE = 1000) + materials = list(/datum/material/glass = 5000, /datum/material/plasma = 3000, /datum/material/diamond = 1000, /datum/material/bluespace = 1000) build_path = /obj/item/reagent_containers/glass/beaker/bluespace category = list("Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL | DEPARTMENTAL_FLAG_SCIENCE @@ -39,7 +39,7 @@ desc = "A cryostasis beaker that allows for chemical storage without reactions. Can hold up to 50 units." id = "splitbeaker" build_type = PROTOLATHE - materials = list(MAT_METAL = 3000) + materials = list(/datum/material/iron = 3000) build_path = /obj/item/reagent_containers/glass/beaker/noreact category = list("Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -49,7 +49,7 @@ id = "xlarge_beaker" build_type = PROTOLATHE departmental_flags = DEPARTMENTAL_FLAG_MEDICAL - materials = list(MAT_GLASS = 2500, MAT_PLASTIC = 3000) + materials = list(/datum/material/glass = 2500, /datum/material/plastic = 3000) build_path = /obj/item/reagent_containers/glass/beaker/plastic category = list("Medical Designs") @@ -58,7 +58,7 @@ id = "meta_beaker" build_type = PROTOLATHE departmental_flags = DEPARTMENTAL_FLAG_MEDICAL - materials = list(MAT_GLASS = 2500, MAT_PLASTIC = 3000, MAT_GOLD = 1000, MAT_TITANIUM = 1000) + materials = list(/datum/material/glass = 2500, /datum/material/plastic = 3000, /datum/material/gold = 1000, /datum/material/titanium = 1000) build_path = /obj/item/reagent_containers/glass/beaker/meta category = list("Medical Designs") @@ -67,7 +67,7 @@ desc = "An advanced syringe that can hold 60 units of chemicals." id = "bluespacesyringe" build_type = PROTOLATHE - materials = list(MAT_GLASS = 2000, MAT_PLASMA = 1000, MAT_DIAMOND = 1000, MAT_BLUESPACE = 500) + materials = list(/datum/material/glass = 2000, /datum/material/plasma = 1000, /datum/material/diamond = 1000, /datum/material/bluespace = 500) build_path = /obj/item/reagent_containers/syringe/bluespace category = list("Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL | DEPARTMENTAL_FLAG_SCIENCE @@ -77,7 +77,7 @@ desc = "Produce additional disks for storing genetic data." id = "cloning_disk" build_type = PROTOLATHE - materials = list(MAT_METAL = 300, MAT_GLASS = 100, MAT_SILVER = 50) + materials = list(/datum/material/iron = 300, /datum/material/glass = 100, /datum/material/silver = 50) build_path = /obj/item/disk/data category = list("Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL | DEPARTMENTAL_FLAG_SCIENCE @@ -87,7 +87,7 @@ desc = "An advanced syringe that stops reagents inside from reacting. It can hold up to 20 units." id = "noreactsyringe" build_type = PROTOLATHE - materials = list(MAT_GLASS = 2000, MAT_GOLD = 1000) + materials = list(/datum/material/glass = 2000, /datum/material/gold = 1000) build_path = /obj/item/reagent_containers/syringe/noreact category = list("Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -97,7 +97,7 @@ desc = "A diamond-tipped syringe that pierces armor when launched at high velocity. It can hold up to 10 units." id = "piercesyringe" build_type = PROTOLATHE - materials = list(MAT_GLASS = 2000, MAT_DIAMOND = 1000) + materials = list(/datum/material/glass = 2000, /datum/material/diamond = 1000) build_path = /obj/item/reagent_containers/syringe/piercing category = list("Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -107,7 +107,7 @@ desc = "A bluespace body bag, powered by experimental bluespace technology. It can hold loads of bodies and the largest of creatures." id = "bluespacebodybag" build_type = PROTOLATHE - materials = list(MAT_METAL = 3000, MAT_PLASMA = 2000, MAT_DIAMOND = 500, MAT_BLUESPACE = 500) + materials = list(/datum/material/iron = 3000, /datum/material/plasma = 2000, /datum/material/diamond = 500, /datum/material/bluespace = 500) build_path = /obj/item/bodybag/bluespace category = list("Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL | DEPARTMENTAL_FLAG_SCIENCE @@ -117,7 +117,7 @@ desc = "A refill pack for the auto-extinguisher on Plasma-man suits." id = "plasmarefiller" //Why did this have no plasmatech build_type = PROTOLATHE - materials = list(MAT_METAL = 4000, MAT_PLASMA = 1000) + materials = list(/datum/material/iron = 4000, /datum/material/plasma = 1000) build_path = /obj/item/extinguisher_refill category = list("Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_ALL @@ -127,7 +127,7 @@ desc = "Allows tracking of someone's location if their suit sensors are turned to tracking beacon." id = "crewpinpointer" build_type = PROTOLATHE - materials = list(MAT_METAL = 3000, MAT_GLASS = 1500, MAT_GOLD = 200) + materials = list(/datum/material/iron = 3000, /datum/material/glass = 1500, /datum/material/gold = 200) build_path = /obj/item/pinpointer/crew category = list("Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -138,7 +138,7 @@ id = "defibrillator" build_type = PROTOLATHE build_path = /obj/item/defibrillator - materials = list(MAT_METAL = 8000, MAT_GLASS = 4000, MAT_SILVER = 3000, MAT_GOLD = 1500) + materials = list(/datum/material/iron = 8000, /datum/material/glass = 4000, /datum/material/silver = 3000, /datum/material/gold = 1500) category = list("Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -147,7 +147,7 @@ desc = "An all-in-one mounted frame for holding defibrillators, complete with ID-locked clamps and recharging cables." id = "defibmount" build_type = PROTOLATHE - materials = list(MAT_METAL = 2000, MAT_GLASS = 1000) + materials = list(/datum/material/iron = 2000, /datum/material/glass = 1000) build_path = /obj/item/wallframe/defib_mount category = list("Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -158,7 +158,7 @@ id = "defibrillator_compact" build_type = PROTOLATHE build_path = /obj/item/defibrillator/compact - materials = list(MAT_METAL = 16000, MAT_GLASS = 8000, MAT_SILVER = 6000, MAT_GOLD = 3000) + materials = list(/datum/material/iron = 16000, /datum/material/glass = 8000, /datum/material/silver = 6000, /datum/material/gold = 3000) category = list("Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -168,7 +168,7 @@ id = "genescanner" build_path = /obj/item/sequence_scanner build_type = PROTOLATHE - materials = list(MAT_METAL = 1000, MAT_GLASS = 500) + materials = list(/datum/material/iron = 1000, /datum/material/glass = 500) category = list("Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -178,7 +178,7 @@ id = "healthanalyzer_advanced" build_path = /obj/item/healthanalyzer/advanced build_type = PROTOLATHE - materials = list(MAT_METAL = 5000, MAT_GLASS = 2500, MAT_SILVER = 2000, MAT_GOLD = 1500) + materials = list(/datum/material/iron = 5000, /datum/material/glass = 2500, /datum/material/silver = 2000, /datum/material/gold = 1500) category = list("Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -188,7 +188,7 @@ id = "medspray" build_path = /obj/item/reagent_containers/medspray build_type = PROTOLATHE - materials = list(MAT_METAL = 2500, MAT_GLASS = 500) + materials = list(/datum/material/iron = 2500, /datum/material/glass = 500) category = list("Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -196,7 +196,7 @@ name = "Surgical Drapes" id = "surgical_drapes" build_type = PROTOLATHE - materials = list(MAT_PLASTIC = 2000) + materials = list(/datum/material/plastic = 2000) build_path = /obj/item/surgical_drapes category = list("Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL | DEPARTMENTAL_FLAG_SCIENCE @@ -207,7 +207,7 @@ id = "laserscalpel" build_path = /obj/item/scalpel/advanced build_type = PROTOLATHE - materials = list(MAT_METAL = 6000, MAT_GLASS = 1500, MAT_SILVER = 2000, MAT_GOLD = 1500, MAT_DIAMOND = 200, MAT_TITANIUM = 4000) + materials = list(/datum/material/iron = 6000, /datum/material/glass = 1500, /datum/material/silver = 2000, /datum/material/gold = 1500, /datum/material/diamond = 200, /datum/material/titanium = 4000) category = list("Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL | DEPARTMENTAL_FLAG_SCIENCE @@ -217,7 +217,7 @@ id = "mechanicalpinches" build_path = /obj/item/retractor/advanced build_type = PROTOLATHE - materials = list(MAT_METAL = 12000, MAT_GLASS = 4000, MAT_SILVER = 4000, MAT_TITANIUM = 5000) + materials = list(/datum/material/iron = 12000, /datum/material/glass = 4000, /datum/material/silver = 4000, /datum/material/titanium = 5000) category = list("Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL | DEPARTMENTAL_FLAG_SCIENCE @@ -227,7 +227,7 @@ id = "searingtool" build_path = /obj/item/cautery/advanced build_type = PROTOLATHE - materials = list(MAT_METAL = 4000, MAT_GLASS = 2000, MAT_PLASMA = 2000, MAT_URANIUM = 3000, MAT_TITANIUM = 3000) + materials = list(/datum/material/iron = 4000, /datum/material/glass = 2000, /datum/material/plasma = 2000, /datum/material/uranium = 3000, /datum/material/titanium = 3000) category = list("Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL | DEPARTMENTAL_FLAG_SCIENCE @@ -241,9 +241,9 @@ id = "ci-welding" build_type = PROTOLATHE | MECHFAB construction_time = 40 - materials = list(MAT_METAL = 600, MAT_GLASS = 400) + materials = list(/datum/material/iron = 600, /datum/material/glass = 400) build_path = /obj/item/organ/eyes/robotic/shield - category = list("Misc", "Medical Designs") + category = list("Implants", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL /datum/design/cyberimp_gloweyes @@ -252,9 +252,9 @@ id = "ci-gloweyes" build_type = PROTOLATHE | MECHFAB construction_time = 40 - materials = list(MAT_METAL = 600, MAT_GLASS = 1000) + materials = list(/datum/material/iron = 600, /datum/material/glass = 1000) build_path = /obj/item/organ/eyes/robotic/glow - category = list("Misc", "Medical Designs") + category = list("Implants", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL /datum/design/cyberimp_breather @@ -263,9 +263,9 @@ id = "ci-breather" build_type = PROTOLATHE | MECHFAB construction_time = 35 - materials = list(MAT_METAL = 600, MAT_GLASS = 250) + materials = list(/datum/material/iron = 600, /datum/material/glass = 250) build_path = /obj/item/organ/cyberimp/mouth/breathing_tube - category = list("Misc", "Medical Designs") + category = list("Implants", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL /datum/design/cyberimp_surgical @@ -273,10 +273,10 @@ desc = "A set of surgical tools hidden behind a concealed panel on the user's arm." id = "ci-surgery" build_type = PROTOLATHE | MECHFAB - materials = list (MAT_METAL = 2500, MAT_GLASS = 1500, MAT_SILVER = 1500) + materials = list (/datum/material/iron = 2500, /datum/material/glass = 1500, /datum/material/silver = 1500) construction_time = 200 build_path = /obj/item/organ/cyberimp/arm/surgery - category = list("Misc", "Medical Designs") + category = list("Implants", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL /datum/design/cyberimp_toolset @@ -284,10 +284,10 @@ desc = "A stripped-down version of the engineering cyborg toolset, designed to be installed on the subject's arm." id = "ci-toolset" build_type = PROTOLATHE | MECHFAB - materials = list (MAT_METAL = 2500, MAT_GLASS = 1500, MAT_SILVER = 1500) + materials = list (/datum/material/iron = 2500, /datum/material/glass = 1500, /datum/material/silver = 1500) construction_time = 200 build_path = /obj/item/organ/cyberimp/arm/toolset - category = list("Misc", "Medical Designs") + category = list("Implants", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL /datum/design/cyberimp_medical_hud @@ -296,9 +296,9 @@ id = "ci-medhud" build_type = PROTOLATHE | MECHFAB construction_time = 50 - materials = list(MAT_METAL = 600, MAT_GLASS = 600, MAT_SILVER = 500, MAT_GOLD = 500) + materials = list(/datum/material/iron = 600, /datum/material/glass = 600, /datum/material/silver = 500, /datum/material/gold = 500) build_path = /obj/item/organ/cyberimp/eyes/hud/medical - category = list("Misc", "Medical Designs") + category = list("Implants", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL /datum/design/cyberimp_security_hud @@ -307,9 +307,9 @@ id = "ci-sechud" build_type = PROTOLATHE | MECHFAB construction_time = 50 - materials = list(MAT_METAL = 600, MAT_GLASS = 600, MAT_SILVER = 750, MAT_GOLD = 750) + materials = list(/datum/material/iron = 600, /datum/material/glass = 600, /datum/material/silver = 750, /datum/material/gold = 750) build_path = /obj/item/organ/cyberimp/eyes/hud/security - category = list("Misc", "Medical Designs") + category = list("Implants", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL /datum/design/cyberimp_diagnostic_hud @@ -318,9 +318,9 @@ id = "ci-diaghud" build_type = PROTOLATHE | MECHFAB construction_time = 50 - materials = list(MAT_METAL = 600, MAT_GLASS = 600, MAT_SILVER = 600, MAT_GOLD = 600) + materials = list(/datum/material/iron = 600, /datum/material/glass = 600, /datum/material/silver = 600, /datum/material/gold = 600) build_path = /obj/item/organ/cyberimp/eyes/hud/diagnostic - category = list("Misc", "Medical Designs") + category = list("Implants", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL /datum/design/cyberimp_xray @@ -329,9 +329,9 @@ id = "ci-xray" build_type = PROTOLATHE | MECHFAB construction_time = 60 - materials = list(MAT_METAL = 600, MAT_GLASS = 600, MAT_SILVER = 600, MAT_GOLD = 600, MAT_PLASMA = 1000, MAT_URANIUM = 1000, MAT_DIAMOND = 1000, MAT_BLUESPACE = 1000) + materials = list(/datum/material/iron = 600, /datum/material/glass = 600, /datum/material/silver = 600, /datum/material/gold = 600, /datum/material/plasma = 1000, /datum/material/uranium = 1000, /datum/material/diamond = 1000, /datum/material/bluespace = 1000) build_path = /obj/item/organ/eyes/robotic/xray - category = list("Misc", "Medical Designs") + category = list("Implants", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL /datum/design/cyberimp_thermals @@ -340,9 +340,9 @@ id = "ci-thermals" build_type = PROTOLATHE | MECHFAB construction_time = 60 - materials = list(MAT_METAL = 600, MAT_GLASS = 600, MAT_SILVER = 600, MAT_GOLD = 600, MAT_PLASMA = 1000, MAT_DIAMOND = 2000) + materials = list(/datum/material/iron = 600, /datum/material/glass = 600, /datum/material/silver = 600, /datum/material/gold = 600, /datum/material/plasma = 1000, /datum/material/diamond = 2000) build_path = /obj/item/organ/eyes/robotic/thermals - category = list("Misc", "Medical Designs") + category = list("Implants", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL /datum/design/cyberimp_antidrop @@ -351,9 +351,9 @@ id = "ci-antidrop" build_type = PROTOLATHE | MECHFAB construction_time = 60 - materials = list(MAT_METAL = 600, MAT_GLASS = 600, MAT_SILVER = 400, MAT_GOLD = 400) + materials = list(/datum/material/iron = 600, /datum/material/glass = 600, /datum/material/silver = 400, /datum/material/gold = 400) build_path = /obj/item/organ/cyberimp/brain/anti_drop - category = list("Misc", "Medical Designs") + category = list("Implants", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL /datum/design/cyberimp_antistun @@ -362,9 +362,9 @@ id = "ci-antistun" build_type = PROTOLATHE | MECHFAB construction_time = 60 - materials = list(MAT_METAL = 600, MAT_GLASS = 600, MAT_SILVER = 500, MAT_GOLD = 1000) + materials = list(/datum/material/iron = 600, /datum/material/glass = 600, /datum/material/silver = 500, /datum/material/gold = 1000) build_path = /obj/item/organ/cyberimp/brain/anti_stun - category = list("Misc", "Medical Designs") + category = list("Implants", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL /datum/design/cyberimp_nutriment @@ -373,9 +373,9 @@ id = "ci-nutriment" build_type = PROTOLATHE | MECHFAB construction_time = 40 - materials = list(MAT_METAL = 500, MAT_GLASS = 500, MAT_GOLD = 500) + materials = list(/datum/material/iron = 500, /datum/material/glass = 500, /datum/material/gold = 500) build_path = /obj/item/organ/cyberimp/chest/nutriment - category = list("Misc", "Medical Designs") + category = list("Implants", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL /datum/design/cyberimp_nutriment_plus @@ -384,9 +384,9 @@ id = "ci-nutrimentplus" build_type = PROTOLATHE | MECHFAB construction_time = 50 - materials = list(MAT_METAL = 600, MAT_GLASS = 600, MAT_GOLD = 500, MAT_URANIUM = 750) + materials = list(/datum/material/iron = 600, /datum/material/glass = 600, /datum/material/gold = 500, /datum/material/uranium = 750) build_path = /obj/item/organ/cyberimp/chest/nutriment/plus - category = list("Misc", "Medical Designs") + category = list("Implants", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL /datum/design/cyberimp_reviver @@ -395,9 +395,9 @@ id = "ci-reviver" build_type = PROTOLATHE | MECHFAB construction_time = 60 - materials = list(MAT_METAL = 800, MAT_GLASS = 800, MAT_GOLD = 300, MAT_URANIUM = 500) + materials = list(/datum/material/iron = 800, /datum/material/glass = 800, /datum/material/gold = 300, /datum/material/uranium = 500) build_path = /obj/item/organ/cyberimp/chest/reviver - category = list("Misc", "Medical Designs") + category = list("Implants", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL /datum/design/cyberimp_thrusters @@ -406,9 +406,9 @@ id = "ci-thrusters" build_type = PROTOLATHE | MECHFAB construction_time = 80 - materials = list(MAT_METAL = 4000, MAT_GLASS = 2000, MAT_SILVER = 1000, MAT_DIAMOND = 1000) + materials = list(/datum/material/iron = 4000, /datum/material/glass = 2000, /datum/material/silver = 1000, /datum/material/diamond = 1000) build_path = /obj/item/organ/cyberimp/chest/thrusters - category = list("Misc", "Medical Designs") + category = list("Implants", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL ///////////////////////////////////////// @@ -420,7 +420,7 @@ desc = "A sterile automatic implant injector." id = "implanter" build_type = PROTOLATHE - materials = list(MAT_METAL = 600, MAT_GLASS = 200) + materials = list(/datum/material/iron = 600, /datum/material/glass = 200) build_path = /obj/item/implanter category = list("Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_SECURITY | DEPARTMENTAL_FLAG_MEDICAL @@ -430,7 +430,7 @@ desc = "A glass case for containing an implant." id = "implantcase" build_type = PROTOLATHE - materials = list(MAT_GLASS = 500) + materials = list(/datum/material/glass = 500) build_path = /obj/item/implantcase category = list("Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_SECURITY | DEPARTMENTAL_FLAG_MEDICAL @@ -440,7 +440,7 @@ desc = "Makes death amusing." id = "implant_trombone" build_type = PROTOLATHE - materials = list(MAT_GLASS = 500, MAT_BANANIUM = 500) + materials = list(/datum/material/glass = 500, /datum/material/bananium = 500) build_path = /obj/item/implantcase/sad_trombone category = list("Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_ALL //if you get bananium you get the sad trombones. @@ -450,7 +450,7 @@ desc = "A glass case containing an implant." id = "implant_chem" build_type = PROTOLATHE - materials = list(MAT_GLASS = 700) + materials = list(/datum/material/glass = 700) build_path = /obj/item/implantcase/chem category = list("Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_SECURITY | DEPARTMENTAL_FLAG_MEDICAL @@ -460,7 +460,7 @@ desc = "A glass case containing an implant." id = "implant_tracking" build_type = PROTOLATHE - materials = list(MAT_METAL = 500, MAT_GLASS = 500) + materials = list(/datum/material/iron = 500, /datum/material/glass = 500) build_path = /obj/item/implantcase/tracking category = list("Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_SECURITY | DEPARTMENTAL_FLAG_MEDICAL @@ -473,9 +473,9 @@ id = "cybernetic_liver" build_type = PROTOLATHE | MECHFAB construction_time = 40 - materials = list(MAT_METAL = 500, MAT_GLASS = 500) + materials = list(/datum/material/iron = 500, /datum/material/glass = 500) build_path = /obj/item/organ/liver/cybernetic - category = list("Misc", "Medical Designs") + category = list("Cybernetics", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL /datum/design/cybernetic_liver_u @@ -484,9 +484,9 @@ id = "cybernetic_liver_u" build_type = PROTOLATHE | MECHFAB construction_time = 50 - materials = list(MAT_METAL = 500, MAT_GLASS = 500, MAT_SILVER=500, MAT_GOLD=200) + materials = list(/datum/material/iron = 500, /datum/material/glass = 500, /datum/material/silver=500, /datum/material/gold=200) build_path = /obj/item/organ/liver/cybernetic/upgraded - category = list("Misc", "Medical Designs") + category = list("Cybernetics", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL /datum/design/cybernetic_heart @@ -495,9 +495,9 @@ id = "cybernetic_heart" build_type = PROTOLATHE | MECHFAB construction_time = 40 - materials = list(MAT_METAL = 500, MAT_GLASS = 500) + materials = list(/datum/material/iron = 500, /datum/material/glass = 500) build_path = /obj/item/organ/heart/cybernetic - category = list("Misc", "Medical Designs") + category = list("Cybernetics", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL /datum/design/cybernetic_heart_u @@ -506,9 +506,9 @@ id = "cybernetic_heart_u" build_type = PROTOLATHE | MECHFAB construction_time = 50 - materials = list(MAT_METAL = 500, MAT_GLASS = 500, MAT_SILVER=500, MAT_GOLD=200) + materials = list(/datum/material/iron = 500, /datum/material/glass = 500, /datum/material/silver=500, /datum/material/gold=200) build_path = /obj/item/organ/heart/cybernetic/upgraded - category = list("Misc", "Medical Designs") + category = list("Cybernetics", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL /datum/design/cybernetic_lungs @@ -517,9 +517,9 @@ id = "cybernetic_lungs" build_type = PROTOLATHE | MECHFAB construction_time = 40 - materials = list(MAT_METAL = 500, MAT_GLASS = 500) + materials = list(/datum/material/iron = 500, /datum/material/glass = 500) build_path = /obj/item/organ/lungs/cybernetic - category = list("Misc", "Medical Designs") + category = list("Cybernetics", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL /datum/design/cybernetic_lungs_u @@ -528,9 +528,9 @@ id = "cybernetic_lungs_u" build_type = PROTOLATHE | MECHFAB construction_time = 50 - materials = list(MAT_METAL = 500, MAT_GLASS = 500, MAT_SILVER = 500, MAT_GOLD=200) + materials = list(/datum/material/iron = 500, /datum/material/glass = 500, /datum/material/silver = 500, /datum/material/gold=200) build_path = /obj/item/organ/lungs/cybernetic/upgraded - category = list("Misc", "Medical Designs") + category = list("Cybernetics", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL /datum/design/cybernetic_appendix @@ -539,9 +539,9 @@ id = "cybernetic_appendix" build_type = PROTOLATHE | MECHFAB construction_time = 50 - materials = list(MAT_METAL = 200, MAT_GLASS = 200) + materials = list(/datum/material/iron = 200, /datum/material/glass = 200) build_path = /obj/item/organ/appendix/cybernetic - category = list("Misc", "Medical Designs") + category = list("Cybernetics", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL ///////////////////// @@ -696,4 +696,4 @@ desc = "An experimental surgical procedure that stimulates the growth of a Romerol tumor inside the patient's brain. Requires zombie powder or rezadone." id = "surgery_zombie" surgery = /datum/surgery/advanced/necrotic_revival - research_icon_state = "surgery_head" + research_icon_state = "surgery_head" \ No newline at end of file diff --git a/code/modules/research/designs/mining_designs.dm b/code/modules/research/designs/mining_designs.dm index 6b168bcc6a19..4caac4df4808 100644 --- a/code/modules/research/designs/mining_designs.dm +++ b/code/modules/research/designs/mining_designs.dm @@ -7,7 +7,7 @@ desc = "Allows for the construction of circuit boards used to build an Express Supply Console."//who? id = "cargoexpress"//the coder reading this build_type = IMPRINTER - materials = list(MAT_GLASS = 1000) + materials = list(/datum/material/glass = 1000) build_path = /obj/item/circuitboard/computer/cargo/express category = list("Mining Designs") departmental_flags = DEPARTMENTAL_FLAG_CARGO @@ -17,7 +17,7 @@ desc = "Allows the Cargo Express Console to call down the Bluespace Drop Pod, greatly increasing user safety."//who? id = "bluespace_pod"//the coder reading this build_type = PROTOLATHE - materials = list(MAT_GLASS = 1000) + materials = list(/datum/material/glass = 1000) build_path = /obj/item/disk/cargo/bluespace_pod category = list("Mining Designs") departmental_flags = DEPARTMENTAL_FLAG_CARGO @@ -27,7 +27,7 @@ desc = "Yours is the drill that will pierce through the rock walls." id = "drill" build_type = PROTOLATHE - materials = list(MAT_METAL = 6000, MAT_GLASS = 1000) //expensive, but no need for miners. + materials = list(/datum/material/iron = 6000, /datum/material/glass = 1000) //expensive, but no need for miners. build_path = /obj/item/pickaxe/drill category = list("Mining Designs") departmental_flags = DEPARTMENTAL_FLAG_CARGO @@ -37,7 +37,7 @@ desc = "Yours is the drill that will pierce the heavens!" id = "drill_diamond" build_type = PROTOLATHE - materials = list(MAT_METAL = 6000, MAT_GLASS = 1000, MAT_DIAMOND = 2000) //Yes, a whole diamond is needed. + materials = list(/datum/material/iron = 6000, /datum/material/glass = 1000, /datum/material/diamond = 2000) //Yes, a whole diamond is needed. build_path = /obj/item/pickaxe/drill/diamonddrill category = list("Mining Designs") departmental_flags = DEPARTMENTAL_FLAG_CARGO @@ -47,7 +47,7 @@ desc = "You could use it to cut limbs off of xenos! Or, you know, mine stuff." id = "plasmacutter" build_type = PROTOLATHE - materials = list(MAT_METAL = 1500, MAT_GLASS = 500, MAT_PLASMA = 1000, MAT_SILVER = 1000, MAT_URANIUM = 800) + materials = list(/datum/material/iron = 1500, /datum/material/glass = 500, /datum/material/plasma = 1000, /datum/material/silver = 1000, /datum/material/uranium = 800) build_path = /obj/item/gun/energy/plasmacutter category = list("Mining Designs") departmental_flags = DEPARTMENTAL_FLAG_CARGO @@ -57,7 +57,7 @@ desc = "It's an advanced plasma cutter, oh my god." id = "plasmacutter_adv" build_type = PROTOLATHE - materials = list(MAT_METAL = 3000, MAT_GLASS = 1000, MAT_PLASMA = 2000, MAT_GOLD = 2000, MAT_URANIUM = 3000, MAT_DIAMOND = 2000) + materials = list(/datum/material/iron = 3000, /datum/material/glass = 1000, /datum/material/plasma = 2000, /datum/material/gold = 2000, /datum/material/uranium = 3000, /datum/material/diamond = 2000) build_path = /obj/item/gun/energy/plasmacutter/adv category = list("Mining Designs") departmental_flags = DEPARTMENTAL_FLAG_CARGO @@ -67,7 +67,7 @@ desc = "Essentially a handheld planet-cracker. Can drill through walls with ease as well." id = "jackhammer" build_type = PROTOLATHE - materials = list(MAT_METAL = 6000, MAT_GLASS = 2000, MAT_SILVER = 2000, MAT_DIAMOND = 6000) + materials = list(/datum/material/iron = 6000, /datum/material/glass = 2000, /datum/material/silver = 2000, /datum/material/diamond = 6000) build_path = /obj/item/pickaxe/drill/jackhammer category = list("Mining Designs") departmental_flags = DEPARTMENTAL_FLAG_CARGO @@ -77,7 +77,7 @@ desc = "An upgraded version of the resonator that allows more fields to be active at once." id = "superresonator" build_type = PROTOLATHE - materials = list(MAT_METAL = 4000, MAT_GLASS = 1500, MAT_SILVER = 1000, MAT_URANIUM = 1000) + materials = list(/datum/material/iron = 4000, /datum/material/glass = 1500, /datum/material/silver = 1000, /datum/material/uranium = 1000) build_path = /obj/item/resonator/upgraded category = list("Mining Designs") departmental_flags = DEPARTMENTAL_FLAG_CARGO @@ -87,7 +87,7 @@ desc = "A device which allows kinetic accelerators to be wielded by any organism." id = "triggermod" build_type = PROTOLATHE - materials = list(MAT_METAL = 2000, MAT_GLASS = 1500, MAT_GOLD = 1500, MAT_URANIUM = 1000) + materials = list(/datum/material/iron = 2000, /datum/material/glass = 1500, /datum/material/gold = 1500, /datum/material/uranium = 1000) build_path = /obj/item/borg/upgrade/modkit/trigger_guard category = list("Mining Designs") departmental_flags = DEPARTMENTAL_FLAG_CARGO @@ -97,7 +97,7 @@ desc = "A device which allows kinetic accelerators to deal more damage." id = "damagemod" build_type = PROTOLATHE | MECHFAB - materials = list(MAT_METAL = 2000, MAT_GLASS = 1500, MAT_GOLD = 1500, MAT_URANIUM = 1000) + materials = list(/datum/material/iron = 2000, /datum/material/glass = 1500, /datum/material/gold = 1500, /datum/material/uranium = 1000) build_path = /obj/item/borg/upgrade/modkit/damage category = list("Mining Designs", "Cyborg Upgrade Modules") departmental_flags = DEPARTMENTAL_FLAG_CARGO @@ -107,7 +107,7 @@ desc = "A device which decreases the cooldown of a Kinetic Accelerator." id = "cooldownmod" build_type = PROTOLATHE | MECHFAB - materials = list(MAT_METAL = 2000, MAT_GLASS = 1500, MAT_GOLD = 1500, MAT_URANIUM = 1000) + materials = list(/datum/material/iron = 2000, /datum/material/glass = 1500, /datum/material/gold = 1500, /datum/material/uranium = 1000) build_path = /obj/item/borg/upgrade/modkit/cooldown category = list("Mining Designs", "Cyborg Upgrade Modules") departmental_flags = DEPARTMENTAL_FLAG_CARGO @@ -117,7 +117,7 @@ desc = "A device which allows kinetic accelerators to fire at a further range." id = "rangemod" build_type = PROTOLATHE | MECHFAB - materials = list(MAT_METAL = 2000, MAT_GLASS = 1500, MAT_GOLD = 1500, MAT_URANIUM = 1000) + materials = list(/datum/material/iron = 2000, /datum/material/glass = 1500, /datum/material/gold = 1500, /datum/material/uranium = 1000) build_path = /obj/item/borg/upgrade/modkit/range category = list("Mining Designs", "Cyborg Upgrade Modules") departmental_flags = DEPARTMENTAL_FLAG_CARGO @@ -127,7 +127,7 @@ desc = "A modification kit for Kinetic Accelerators which causes it to fire AoE blasts that destroy rock." id = "hypermod" build_type = PROTOLATHE | MECHFAB - materials = list(MAT_METAL = 8000, MAT_GLASS = 1500, MAT_SILVER = 2000, MAT_GOLD = 2000, MAT_DIAMOND = 2000) + materials = list(/datum/material/iron = 8000, /datum/material/glass = 1500, /datum/material/silver = 2000, /datum/material/gold = 2000, /datum/material/diamond = 2000) build_path = /obj/item/borg/upgrade/modkit/aoe/turfs category = list("Mining Designs", "Cyborg Upgrade Modules") departmental_flags = DEPARTMENTAL_FLAG_CARGO @@ -137,7 +137,7 @@ desc = "A camera worn around the neck, that can be viewed from a miner camera console." id = "minercam" build_type = PROTOLATHE - materials = list(MAT_METAL = 1000, MAT_GLASS = 1000, MAT_GOLD = 500) + materials = list(/datum/material/iron = 1000, /datum/material/glass = 1000, /datum/material/gold = 500) build_path = /obj/item/clothing/neck/bodycam/miner category = list("Mining Designs","Equipment") departmental_flags = DEPARTMENTAL_FLAG_CARGO \ No newline at end of file diff --git a/code/modules/research/designs/misc_designs.dm b/code/modules/research/designs/misc_designs.dm index da3c9672c434..d1b1fd6f2a6f 100644 --- a/code/modules/research/designs/misc_designs.dm +++ b/code/modules/research/designs/misc_designs.dm @@ -8,7 +8,7 @@ desc = "A heads-up display that scans the humans in view and provides accurate data about their health status." id = "health_hud" build_type = PROTOLATHE - materials = list(MAT_METAL = 500, MAT_GLASS = 500) + materials = list(/datum/material/iron = 500, /datum/material/glass = 500) build_path = /obj/item/clothing/glasses/hud/health category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -18,7 +18,7 @@ desc = "An advanced medical heads-up display that allows doctors to find patients in complete darkness." id = "health_hud_night" build_type = PROTOLATHE - materials = list(MAT_METAL = 600, MAT_GLASS = 600, MAT_URANIUM = 1000, MAT_SILVER = 350) + materials = list(/datum/material/iron = 600, /datum/material/glass = 600, /datum/material/uranium = 1000, /datum/material/silver = 350) build_path = /obj/item/clothing/glasses/hud/health/night category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -28,7 +28,7 @@ desc = "An upgraded version of the Health Scanner HUD, functions the same and in addition allows the user to see basic structural and terrain layouts through walls." id = "health_hud_meson" build_type = PROTOLATHE - materials = list(MAT_METAL = 500, MAT_GLASS = 500, MAT_PLASMA = 100) + materials = list(/datum/material/iron = 500, /datum/material/glass = 500, /datum/material/plasma = 100) build_path = /obj/item/clothing/glasses/hud/health/meson category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -38,7 +38,7 @@ desc = "A heads-up display that scans the humans in view and provides accurate data about their ID status." id = "security_hud" build_type = PROTOLATHE - materials = list(MAT_METAL = 500, MAT_GLASS = 500) + materials = list(/datum/material/iron = 500, /datum/material/glass = 500) build_path = /obj/item/clothing/glasses/hud/security category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -48,7 +48,7 @@ desc = "A heads-up display which provides ID data and vision in complete darkness." id = "security_hud_night" build_type = PROTOLATHE - materials = list(MAT_METAL = 600, MAT_GLASS = 600, MAT_URANIUM = 1000, MAT_GOLD = 350) + materials = list(/datum/material/iron = 600, /datum/material/glass = 600, /datum/material/uranium = 1000, /datum/material/gold = 350) build_path = /obj/item/clothing/glasses/hud/security/night category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -58,7 +58,7 @@ desc = "A HUD used to analyze and determine faults within robotic machinery." id = "diagnostic_hud" build_type = PROTOLATHE - materials = list(MAT_METAL = 500, MAT_GLASS = 500) + materials = list(/datum/material/iron = 500, /datum/material/glass = 500) build_path = /obj/item/clothing/glasses/hud/diagnostic category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -68,7 +68,7 @@ desc = "An upgraded version of the diagnostic HUD, designed to function during a power failure." id = "diagnostic_hud_night" build_type = PROTOLATHE - materials = list(MAT_METAL = 600, MAT_GLASS = 600, MAT_URANIUM = 1000, MAT_PLASMA = 300) + materials = list(/datum/material/iron = 600, /datum/material/glass = 600, /datum/material/uranium = 1000, /datum/material/plasma = 300) build_path = /obj/item/clothing/glasses/hud/diagnostic/night category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -82,7 +82,7 @@ desc = "A gas mask with built in welding goggles and face shield. Looks like a skull, clearly designed by a nerd." id = "weldingmask" build_type = PROTOLATHE - materials = list(MAT_METAL = 3000, MAT_GLASS = 1000) + materials = list(/datum/material/iron = 3000, /datum/material/glass = 1000) build_path = /obj/item/clothing/mask/gas/welding category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -92,7 +92,7 @@ desc = "For the enterprising botanist on the go. Less efficient than the stationary model, it creates one seed per plant." id = "portaseeder" build_type = PROTOLATHE - materials = list(MAT_METAL = 1000, MAT_GLASS = 400) + materials = list(/datum/material/iron = 1000, /datum/material/glass = 400) build_path = /obj/item/storage/bag/plants/portaseeder category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -102,7 +102,7 @@ desc = "Damn son, where'd you find this?" id = "air_horn" build_type = PROTOLATHE - materials = list(MAT_METAL = 4000, MAT_BANANIUM = 1000) + materials = list(/datum/material/iron = 4000, /datum/material/bananium = 1000) build_path = /obj/item/bikehorn/airhorn category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_ALL //HONK! @@ -112,7 +112,7 @@ desc = "Used by engineering and mining staff to see basic structural and terrain layouts through walls, regardless of lighting condition." id = "mesons" build_type = PROTOLATHE - materials = list(MAT_METAL = 500, MAT_GLASS = 500) + materials = list(/datum/material/iron = 500, /datum/material/glass = 500) build_path = /obj/item/clothing/glasses/meson category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_CARGO | DEPARTMENTAL_FLAG_ENGINEERING @@ -122,7 +122,7 @@ desc = "Goggles used by engineers. The Meson Scanner mode lets you see basic structural and terrain layouts through walls, regardless of lighting condition. The T-ray Scanner mode lets you see underfloor objects such as cables and pipes." id = "engine_goggles" build_type = PROTOLATHE - materials = list(MAT_METAL = 500, MAT_GLASS = 500, MAT_PLASMA = 100) + materials = list(/datum/material/iron = 500, /datum/material/glass = 500, /datum/material/plasma = 100) build_path = /obj/item/clothing/glasses/meson/engine category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -132,7 +132,7 @@ desc = "Used by engineering staff to see underfloor objects such as cables and pipes." id = "tray_goggles" build_type = PROTOLATHE - materials = list(MAT_METAL = 500, MAT_GLASS = 500) + materials = list(/datum/material/iron = 500, /datum/material/glass = 500) build_path = /obj/item/clothing/glasses/meson/engine/tray category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -142,7 +142,7 @@ desc = "Prototype meson scanners fitted with an extra sensor which amplifies the visible light spectrum and overlays it to the HUD display." id = "nvgmesons" build_type = PROTOLATHE - materials = list(MAT_METAL = 600, MAT_GLASS = 600, MAT_PLASMA = 350, MAT_URANIUM = 1000) + materials = list(/datum/material/iron = 600, /datum/material/glass = 600, /datum/material/plasma = 350, /datum/material/uranium = 1000) build_path = /obj/item/clothing/glasses/meson/night category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING | DEPARTMENTAL_FLAG_CARGO @@ -152,7 +152,7 @@ desc = "Goggles that let you see through darkness unhindered." id = "night_visision_goggles" build_type = PROTOLATHE - materials = list(MAT_METAL = 600, MAT_GLASS = 600, MAT_PLASMA = 350, MAT_URANIUM = 1000) + materials = list(/datum/material/iron = 600, /datum/material/glass = 600, /datum/material/plasma = 350, /datum/material/uranium = 1000) build_path = /obj/item/clothing/glasses/night category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_SECURITY @@ -162,7 +162,7 @@ desc = "Magnetic boots, often used during extravehicular activity to ensure the user remains safely attached to the vehicle." id = "magboots" build_type = PROTOLATHE - materials = list(MAT_METAL = 4500, MAT_SILVER = 1500, MAT_GOLD = 2500) + materials = list(/datum/material/iron = 4500, /datum/material/silver = 1500, /datum/material/gold = 2500) build_path = /obj/item/clothing/shoes/magboots category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -172,7 +172,7 @@ desc = "A device which can project temporary forcefields to seal off an area." id = "forcefield_projector" build_type = PROTOLATHE - materials = list(MAT_METAL = 2500, MAT_GLASS = 1000) + materials = list(/datum/material/iron = 2500, /datum/material/glass = 1000) build_path = /obj/item/forcefield_projector category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -182,7 +182,7 @@ desc = "Goggles fitted with a portable analyzer, capable of determining the research worth of an item or components of a machine." id = "scigoggles" build_type = PROTOLATHE - materials = list(MAT_METAL = 500, MAT_GLASS = 500) + materials = list(/datum/material/iron = 500, /datum/material/glass = 500) build_path = /obj/item/clothing/glasses/science category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -192,7 +192,7 @@ desc = "A disk for storing plant genetic data." id = "diskplantgene" build_type = PROTOLATHE - materials = list(MAT_METAL=200, MAT_GLASS=100) + materials = list(/datum/material/iron=200, /datum/material/glass=100) build_path = /obj/item/disk/plantgene category = list("Electronics") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -202,7 +202,7 @@ desc = "A roasting stick for cooking sausages in exotic ovens." id = "roastingstick" build_type = PROTOLATHE - materials = list(MAT_METAL=1000, MAT_GLASS=500, MAT_BLUESPACE = 250) + materials = list(/datum/material/iron=1000, /datum/material/glass=500, /datum/material/bluespace = 250) build_path = /obj/item/melee/roastingstick category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -212,7 +212,7 @@ desc = "Used to track portable teleportation beacons and targets with embedded tracking implants." id = "locator" build_type = PROTOLATHE - materials = list(MAT_METAL=1000, MAT_GLASS=500, MAT_SILVER = 500) + materials = list(/datum/material/iron=1000, /datum/material/glass=500, /datum/material/silver = 500) build_path = /obj/item/locator category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -222,7 +222,7 @@ desc = "Allows for the construction of a quantum keycard." id = "quantum_keycard" build_type = PROTOLATHE - materials = list(MAT_GLASS = 500, MAT_METAL = 500, MAT_SILVER = 500, MAT_BLUESPACE = 1000) + materials = list(/datum/material/glass = 500, /datum/material/iron = 500, /datum/material/silver = 500, /datum/material/bluespace = 1000) build_path = /obj/item/quantum_keycard category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -232,7 +232,7 @@ desc = "An advanced tool capable of instantly neutralizing anomalies, designed to capture the fleeting aberrations created by the engine." id = "anomaly_neutralizer" build_type = PROTOLATHE - materials = list(MAT_METAL = 2000, MAT_GOLD = 2000, MAT_PLASMA = 5000, MAT_URANIUM = 2000) + materials = list(/datum/material/iron = 2000, /datum/material/gold = 2000, /datum/material/plasma = 5000, /datum/material/uranium = 2000) build_path = /obj/item/anomaly_neutralizer category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -242,7 +242,7 @@ desc = "A refill canister for Donksoft Toy Vendors." id = "donksoft_refill" build_type = PROTOLATHE - materials = list(MAT_METAL = 25000, MAT_GLASS = 15000, MAT_PLASMA = 20000, MAT_GOLD = 10000, MAT_SILVER = 10000) + materials = list(/datum/material/iron = 25000, /datum/material/glass = 15000, /datum/material/plasma = 20000, /datum/material/gold = 10000, /datum/material/silver = 10000) build_path = /obj/item/vending_refill/donksoft category = list("Equipment") @@ -251,7 +251,7 @@ desc = "An empty oxygen tank." id = "oxygen_tank" build_type = PROTOLATHE - materials = list(MAT_METAL = 2000) + materials = list(/datum/material/iron = 2000) build_path = /obj/item/tank/internals/oxygen/empty category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING | DEPARTMENTAL_FLAG_SCIENCE @@ -261,7 +261,7 @@ desc = "An empty plasma tank." id = "plasma_tank" build_type = PROTOLATHE - materials = list(MAT_METAL = 2000) + materials = list(/datum/material/iron = 2000) build_path = /obj/item/tank/internals/plasma/empty category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING | DEPARTMENTAL_FLAG_SCIENCE @@ -271,7 +271,7 @@ desc = "A camera worn around the neck, meant to keep you safe." id = "bodycam" build_type = PROTOLATHE - materials = list(MAT_METAL = 1000, MAT_GLASS = 1000, MAT_GOLD = 500) + materials = list(/datum/material/iron = 1000, /datum/material/glass = 1000, /datum/material/gold = 500) build_path = /obj/item/clothing/neck/bodycam/ category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -281,7 +281,7 @@ desc = "A remote for operating a ticket machine (sold seperately)" id = "ticket_remote" build_type = PROTOLATHE - materials = list(MAT_METAL = 1000, MAT_GLASS = 500) + materials = list(/datum/material/iron = 1000, /datum/material/glass = 500) build_path = /obj/item/ticket_machine_remote category = list ("Electronics") departmental_flags = DEPARTMENTAL_FLAG_SERVICE | DEPARTMENTAL_FLAG_CARGO | DEPARTMENTAL_FLAG_MEDICAL @@ -295,7 +295,7 @@ desc = "An upgraded mop with a large internal capacity for holding water or other cleaning chemicals." id = "advmop" build_type = PROTOLATHE - materials = list(MAT_METAL = 2500, MAT_GLASS = 200) + materials = list(/datum/material/iron = 2500, /datum/material/glass = 200) build_path = /obj/item/mop/advanced category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -305,7 +305,7 @@ desc = "An advanced trash bag with bluespace properties; capable of holding a plethora of garbage." id = "blutrash" build_type = PROTOLATHE - materials = list(MAT_GOLD = 1500, MAT_URANIUM = 250, MAT_PLASMA = 1500) + materials = list(/datum/material/gold = 1500, /datum/material/uranium = 250, /datum/material/plasma = 1500) build_path = /obj/item/storage/bag/trash/bluespace category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -315,7 +315,7 @@ desc = "A floor buffer that can be attached to vehicular janicarts." id = "buffer" build_type = PROTOLATHE - materials = list(MAT_METAL = 3000, MAT_GLASS = 200) + materials = list(/datum/material/iron = 3000, /datum/material/glass = 200) build_path = /obj/item/janiupgrade category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -325,7 +325,7 @@ desc = "A spray bottle, with an unscrewable top." id = "spraybottle" build_type = PROTOLATHE - materials = list(MAT_METAL = 3000, MAT_GLASS = 200) + materials = list(/datum/material/iron = 3000, /datum/material/glass = 200) build_path = /obj/item/reagent_containers/spray category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -335,7 +335,7 @@ desc = "A trap used to catch space bears and other legged creatures." id = "beartrap" build_type = PROTOLATHE - materials = list(MAT_METAL = 5000, MAT_TITANIUM = 1000) + materials = list(/datum/material/iron = 5000, /datum/material/titanium = 1000) build_path = /obj/item/restraints/legcuffs/beartrap category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -349,7 +349,7 @@ desc = "A holograpic projector used to project various warning signs." id = "holosign" build_type = PROTOLATHE - materials = list(MAT_METAL = 2000, MAT_GLASS = 1000) + materials = list(/datum/material/iron = 2000, /datum/material/glass = 1000) build_path = /obj/item/holosign_creator category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -359,7 +359,7 @@ desc = "A holograpic projector used to project hard light wet floor barriers." id = "holobarrier_jani" build_type = PROTOLATHE - materials = list(MAT_METAL = 2000, MAT_GLASS = 1000, MAT_SILVER = 1000) + materials = list(/datum/material/iron = 2000, /datum/material/glass = 1000, /datum/material/silver = 1000) build_path = /obj/structure/holosign/barrier/wetsign category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -369,7 +369,7 @@ desc = "A holographic projector that creates holographic security barriers." id = "holosignsec" build_type = PROTOLATHE - materials = list(MAT_METAL = 5000, MAT_GLASS = 1000, MAT_GOLD = 1000, MAT_SILVER = 1000) + materials = list(/datum/material/iron = 5000, /datum/material/glass = 1000, /datum/material/gold = 1000, /datum/material/silver = 1000) build_path = /obj/item/holosign_creator/security category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -379,7 +379,7 @@ desc = "A holographic projector that creates holographic engineering barriers." id = "holosignengi" build_type = PROTOLATHE - materials = list(MAT_METAL = 5000, MAT_GLASS = 1000, MAT_GOLD = 1000, MAT_SILVER = 1000) + materials = list(/datum/material/iron = 5000, /datum/material/glass = 1000, /datum/material/gold = 1000, /datum/material/silver = 1000) build_path = /obj/item/holosign_creator/engineering category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -389,7 +389,7 @@ desc = "A holographic projector that creates holographic barriers that prevent changes in atmospheric conditions." id = "holosignatmos" build_type = PROTOLATHE - materials = list(MAT_METAL = 5000, MAT_GLASS = 1000, MAT_GOLD = 1000, MAT_SILVER = 1000) + materials = list(/datum/material/iron = 5000, /datum/material/glass = 1000, /datum/material/gold = 1000, /datum/material/silver = 1000) build_path = /obj/item/holosign_creator/atmos category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -399,7 +399,7 @@ desc = "PENLITE holobarriers, a device that halts individuals with malicious diseases." build_type = PROTOLATHE build_path = /obj/item/holosign_creator/medical - materials = list(MAT_METAL = 500, MAT_GLASS = 500, MAT_SILVER = 100) //a hint of silver since it can troll 2 antags (bad viros and sentient disease) + materials = list(/datum/material/iron = 500, /datum/material/glass = 500, /datum/material/silver = 100) //a hint of silver since it can troll 2 antags (bad viros and sentient disease) id = "holobarrier_med" category = list("Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -413,7 +413,7 @@ desc = "An experimental suit of armour capable of utilizing an implanted anomaly core to protect the user." id = "reactive_armour" build_type = PROTOLATHE - materials = list(MAT_METAL = 10000, MAT_DIAMOND = 5000, MAT_URANIUM = 8000, MAT_SILVER = 4500, MAT_GOLD = 5000) + materials = list(/datum/material/iron = 10000, /datum/material/diamond = 5000, /datum/material/uranium = 8000, /datum/material/silver = 4500, /datum/material/gold = 5000) build_path = /obj/item/reactive_armour_shell category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -427,7 +427,7 @@ desc = "A robust flashlight used by security." id = "seclite" build_type = PROTOLATHE - materials = list(MAT_METAL = 2500) + materials = list(/datum/material/iron = 2500) build_path = /obj/item/flashlight/seclite category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -437,7 +437,7 @@ desc = "Used to remotely scan objects and biomass for DNA and fingerprints. Can print a report of the findings." id = "detective_scanner" build_type = PROTOLATHE - materials = list(MAT_METAL = 5000, MAT_GLASS = 1000, MAT_GOLD = 2500, MAT_SILVER = 2000) + materials = list(/datum/material/iron = 5000, /datum/material/glass = 1000, /datum/material/gold = 2500, /datum/material/silver = 2000) build_path = /obj/item/detective_scanner category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -447,7 +447,7 @@ desc = "Processes data much quicker at the cost of not being able to scan far remotely. Gives more detailed reports. Scan from 2 tiles away to avoid leaving prints on the scene of the crime!" id = "detective_scanner_advanced" build_type = PROTOLATHE - materials = list(MAT_TITANIUM = 5000, MAT_GLASS = 1000, MAT_GOLD = 2500, MAT_SILVER = 3000) // made of titanium instead of metal + extra silver + materials = list(/datum/material/titanium = 5000, /datum/material/glass = 1000, /datum/material/gold = 2500, /datum/material/silver = 3000) // made of titanium instead of metal + extra silver build_path = /obj/item/detective_scanner/advanced category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -457,7 +457,7 @@ desc = "Manufactured by UhangInc, used to blind and down an opponent quickly. Printed pepper sprays do not contain reagents." id = "pepperspray" build_type = PROTOLATHE - materials = list(MAT_METAL = 5000, MAT_GLASS = 1000) + materials = list(/datum/material/iron = 5000, /datum/material/glass = 1000) build_path = /obj/item/reagent_containers/spray/pepper/empty category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -467,7 +467,7 @@ desc = "A specialized hard-light bola designed to ensnare fleeing criminals and aid in arrests." id = "bola_energy" build_type = PROTOLATHE - materials = list(MAT_SILVER = 500, MAT_PLASMA = 500, MAT_TITANIUM = 500) + materials = list(/datum/material/silver = 500, /datum/material/plasma = 500, /datum/material/titanium = 500) build_path = /obj/item/restraints/legcuffs/bola/energy category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -477,7 +477,7 @@ desc = "Plastic, disposable zipties that can be used to restrain temporarily but are destroyed after use." id = "zipties" build_type = PROTOLATHE - materials = list(MAT_PLASTIC = 250) + materials = list(/datum/material/plastic = 250) build_path = /obj/item/restraints/handcuffs/cable/zipties category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -487,7 +487,7 @@ desc = "An empty evidence bag." id = "evidencebag" build_type = PROTOLATHE - materials = list(MAT_PLASTIC = 100) + materials = list(/datum/material/plastic = 100) build_path = /obj/item/evidencebag category = list("Equipment") departmental_flags = DEPARTMENTAL_FLAG_SECURITY diff --git a/code/modules/research/designs/power_designs.dm b/code/modules/research/designs/power_designs.dm index 9def198276ca..fdbeab1968fe 100644 --- a/code/modules/research/designs/power_designs.dm +++ b/code/modules/research/designs/power_designs.dm @@ -7,7 +7,7 @@ desc = "A basic power cell that holds 1 MJ of energy." id = "basic_cell" build_type = PROTOLATHE | AUTOLATHE |MECHFAB - materials = list(MAT_METAL = 700, MAT_GLASS = 50) + materials = list(/datum/material/iron = 700, /datum/material/glass = 50) construction_time=100 build_path = /obj/item/stock_parts/cell/empty category = list("Misc","Power Designs","Machinery","initial") @@ -18,7 +18,7 @@ desc = "A power cell that holds 10 MJ of energy." id = "high_cell" build_type = PROTOLATHE | AUTOLATHE | MECHFAB - materials = list(MAT_METAL = 700, MAT_GLASS = 60) + materials = list(/datum/material/iron = 700, /datum/material/glass = 60) construction_time=100 build_path = /obj/item/stock_parts/cell/high/empty category = list("Misc","Power Designs") @@ -29,7 +29,7 @@ desc = "A power cell that holds 20 MJ of energy." id = "super_cell" build_type = PROTOLATHE | MECHFAB - materials = list(MAT_METAL = 700, MAT_GLASS = 70) + materials = list(/datum/material/iron = 700, /datum/material/glass = 70) construction_time=100 build_path = /obj/item/stock_parts/cell/super/empty category = list("Misc","Power Designs") @@ -40,7 +40,7 @@ desc = "A power cell that holds 30 MJ of energy." id = "hyper_cell" build_type = PROTOLATHE | MECHFAB - materials = list(MAT_METAL = 700, MAT_GOLD = 150, MAT_SILVER = 150, MAT_GLASS = 80) + materials = list(/datum/material/iron = 700, /datum/material/gold = 150, /datum/material/silver = 150, /datum/material/glass = 80) construction_time=100 build_path = /obj/item/stock_parts/cell/hyper/empty category = list("Misc","Power Designs") @@ -51,7 +51,7 @@ desc = "A power cell that holds 40 MJ of energy." id = "bluespace_cell" build_type = PROTOLATHE | MECHFAB - materials = list(MAT_METAL = 800, MAT_GOLD = 120, MAT_GLASS = 160, MAT_DIAMOND = 160, MAT_TITANIUM = 300, MAT_BLUESPACE = 100) + materials = list(/datum/material/iron = 800, /datum/material/gold = 120, /datum/material/glass = 160, /datum/material/diamond = 160, /datum/material/titanium = 300, /datum/material/bluespace = 100) construction_time=100 build_path = /obj/item/stock_parts/cell/bluespace/empty category = list("Misc","Power Designs") @@ -62,7 +62,7 @@ desc = "A device to automatically replace lights. Refill with working light bulbs." id = "light_replacer" build_type = PROTOLATHE - materials = list(MAT_METAL = 1500, MAT_SILVER = 150, MAT_GLASS = 3000) + materials = list(/datum/material/iron = 1500, /datum/material/silver = 150, /datum/material/glass = 3000) build_path = /obj/item/lightreplacer category = list("Power Designs") departmental_flags = DEPARTMENTAL_FLAG_SERVICE | DEPARTMENTAL_FLAG_ENGINEERING @@ -72,7 +72,7 @@ desc = "The NT-75 Electromagnetic Power Inducer can wirelessly induce electric charge in an object, allowing you to recharge power cells without having to remove them." id = "inducer" build_type = PROTOLATHE - materials = list(MAT_METAL = 3000, MAT_GLASS = 1000) + materials = list(/datum/material/iron = 3000, /datum/material/glass = 1000) build_path = /obj/item/inducer/sci category = list("Power Designs") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING diff --git a/code/modules/research/designs/smelting_designs.dm b/code/modules/research/designs/smelting_designs.dm index f52bc500498a..35f40fb422ff 100644 --- a/code/modules/research/designs/smelting_designs.dm +++ b/code/modules/research/designs/smelting_designs.dm @@ -4,7 +4,7 @@ name = "Plasma + Iron alloy" id = "plasteel" build_type = SMELTER | PROTOLATHE - materials = list(MAT_METAL = MINERAL_MATERIAL_AMOUNT, MAT_PLASMA = MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/iron = MINERAL_MATERIAL_AMOUNT, /datum/material/plasma = MINERAL_MATERIAL_AMOUNT) build_path = /obj/item/stack/sheet/plasteel category = list("initial", "Stock Parts") departmental_flags = DEPARTMENTAL_FLAG_CARGO | DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -15,7 +15,7 @@ name = "Plasma + Titanium alloy" id = "plastitanium" build_type = SMELTER | PROTOLATHE - materials = list(MAT_TITANIUM = MINERAL_MATERIAL_AMOUNT, MAT_PLASMA = MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/titanium = MINERAL_MATERIAL_AMOUNT, /datum/material/plasma = MINERAL_MATERIAL_AMOUNT) build_path = /obj/item/stack/sheet/mineral/plastitanium category = list("initial", "Stock Parts") departmental_flags = DEPARTMENTAL_FLAG_CARGO | DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -25,7 +25,7 @@ name = "Plasma + Glass alloy" id = "plasmaglass" build_type = SMELTER | PROTOLATHE - materials = list(MAT_PLASMA = MINERAL_MATERIAL_AMOUNT * 0.5, MAT_GLASS = MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/plasma = MINERAL_MATERIAL_AMOUNT * 0.5, /datum/material/glass = MINERAL_MATERIAL_AMOUNT) build_path = /obj/item/stack/sheet/plasmaglass category = list("initial", "Stock Parts") departmental_flags = DEPARTMENTAL_FLAG_CARGO | DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -35,7 +35,7 @@ name = "Plasma + Metal + Glass alloy" id = "plasmareinforcedglass" build_type = SMELTER | PROTOLATHE - materials = list(MAT_PLASMA = MINERAL_MATERIAL_AMOUNT * 0.5, MAT_METAL = MINERAL_MATERIAL_AMOUNT * 0.5, MAT_GLASS = MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/plasma = MINERAL_MATERIAL_AMOUNT * 0.5, /datum/material/iron = MINERAL_MATERIAL_AMOUNT * 0.5, /datum/material/glass = MINERAL_MATERIAL_AMOUNT) build_path = /obj/item/stack/sheet/plasmarglass category = list("initial", "Stock Parts") departmental_flags = DEPARTMENTAL_FLAG_CARGO | DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -45,7 +45,7 @@ name = "Titanium + Glass alloy" id = "titaniumglass" build_type = SMELTER | PROTOLATHE - materials = list(MAT_TITANIUM = MINERAL_MATERIAL_AMOUNT * 0.5, MAT_GLASS = MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/titanium = MINERAL_MATERIAL_AMOUNT * 0.5, /datum/material/glass = MINERAL_MATERIAL_AMOUNT) build_path = /obj/item/stack/sheet/titaniumglass category = list("initial", "Stock Parts") departmental_flags = DEPARTMENTAL_FLAG_CARGO | DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -55,7 +55,7 @@ name = "Plasma + Titanium + Glass alloy" id = "plastitaniumglass" build_type = SMELTER | PROTOLATHE - materials = list(MAT_PLASMA = MINERAL_MATERIAL_AMOUNT * 0.5, MAT_TITANIUM = MINERAL_MATERIAL_AMOUNT * 0.5, MAT_GLASS = MINERAL_MATERIAL_AMOUNT) + materials = list(/datum/material/plasma = MINERAL_MATERIAL_AMOUNT * 0.5, /datum/material/titanium = MINERAL_MATERIAL_AMOUNT * 0.5, /datum/material/glass = MINERAL_MATERIAL_AMOUNT) build_path = /obj/item/stack/sheet/plastitaniumglass category = list("initial", "Stock Parts") departmental_flags = DEPARTMENTAL_FLAG_CARGO | DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -66,7 +66,7 @@ desc = "A sheet of reverse-engineered alien alloy." id = "alienalloy" build_type = PROTOLATHE | SMELTER - materials = list(MAT_METAL = 4000, MAT_PLASMA = 4000) + materials = list(/datum/material/iron = 4000, /datum/material/plasma = 4000) build_path = /obj/item/stack/sheet/mineral/abductor category = list("Stock Parts") departmental_flags = DEPARTMENTAL_FLAG_CARGO | DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING diff --git a/code/modules/research/designs/stock_parts_designs.dm b/code/modules/research/designs/stock_parts_designs.dm index 2ae56d4ecdad..305aadc7e995 100644 --- a/code/modules/research/designs/stock_parts_designs.dm +++ b/code/modules/research/designs/stock_parts_designs.dm @@ -7,7 +7,7 @@ desc = "Special mechanical module made to store, sort, and apply standard machine parts." id = "rped" build_type = PROTOLATHE - materials = list(MAT_METAL = 10000, MAT_GLASS = 5000) //hardcore + materials = list(/datum/material/iron = 10000, /datum/material/glass = 5000) //hardcore build_path = /obj/item/storage/part_replacer category = list("Stock Parts") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING | DEPARTMENTAL_FLAG_SCIENCE @@ -17,7 +17,7 @@ desc = "Powered by bluespace technology, this RPED variant can upgrade buildings from a distance, without needing to remove the panel first." id = "bs_rped" build_type = PROTOLATHE - materials = list(MAT_METAL = 15000, MAT_GLASS = 5000, MAT_SILVER = 2500) //hardcore + materials = list(/datum/material/iron = 15000, /datum/material/glass = 5000, /datum/material/silver = 2500) //hardcore build_path = /obj/item/storage/part_replacer/bluespace category = list("Stock Parts") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING | DEPARTMENTAL_FLAG_SCIENCE @@ -28,7 +28,7 @@ desc = "A stock part used in the construction of various devices." id = "basic_capacitor" build_type = PROTOLATHE | AUTOLATHE - materials = list(MAT_METAL = 100, MAT_GLASS = 100) + materials = list(/datum/material/iron = 100, /datum/material/glass = 100) build_path = /obj/item/stock_parts/capacitor category = list("Stock Parts","Machinery","initial") lathe_time_factor = 0.2 @@ -39,7 +39,7 @@ desc = "A stock part used in the construction of various devices." id = "adv_capacitor" build_type = PROTOLATHE - materials = list(MAT_METAL = 150, MAT_GLASS = 150) + materials = list(/datum/material/iron = 150, /datum/material/glass = 150) build_path = /obj/item/stock_parts/capacitor/adv category = list("Stock Parts") lathe_time_factor = 0.2 @@ -50,7 +50,7 @@ desc = "A stock part used in the construction of various devices." id = "super_capacitor" build_type = PROTOLATHE - materials = list(MAT_METAL = 200, MAT_GLASS = 200, MAT_GOLD = 100) + materials = list(/datum/material/iron = 200, /datum/material/glass = 200, /datum/material/gold = 100) build_path = /obj/item/stock_parts/capacitor/super category = list("Stock Parts") lathe_time_factor = 0.2 @@ -61,7 +61,7 @@ desc = "A stock part used in the construction of various devices." id = "quadratic_capacitor" build_type = PROTOLATHE - materials = list(MAT_METAL = 200, MAT_GLASS = 200, MAT_GOLD = 100, MAT_DIAMOND = 100) + materials = list(/datum/material/iron = 200, /datum/material/glass = 200, /datum/material/gold = 100, /datum/material/diamond = 100) build_path = /obj/item/stock_parts/capacitor/quadratic category = list("Stock Parts") lathe_time_factor = 0.2 @@ -73,7 +73,7 @@ desc = "A stock part used in the construction of various devices." id = "basic_scanning" build_type = PROTOLATHE | AUTOLATHE - materials = list(MAT_METAL = 100, MAT_GLASS = 50) + materials = list(/datum/material/iron = 100, /datum/material/glass = 50) build_path = /obj/item/stock_parts/scanning_module category = list("Stock Parts","Machinery","initial") lathe_time_factor = 0.2 @@ -84,7 +84,7 @@ desc = "A stock part used in the construction of various devices." id = "adv_scanning" build_type = PROTOLATHE - materials = list(MAT_METAL = 150, MAT_GLASS = 100) + materials = list(/datum/material/iron = 150, /datum/material/glass = 100) build_path = /obj/item/stock_parts/scanning_module/adv category = list("Stock Parts") lathe_time_factor = 0.2 @@ -95,7 +95,7 @@ desc = "A stock part used in the construction of various devices." id = "phasic_scanning" build_type = PROTOLATHE - materials = list(MAT_METAL = 200, MAT_GLASS = 150, MAT_SILVER = 60) + materials = list(/datum/material/iron = 200, /datum/material/glass = 150, /datum/material/silver = 60) build_path = /obj/item/stock_parts/scanning_module/phasic category = list("Stock Parts") lathe_time_factor = 0.2 @@ -106,7 +106,7 @@ desc = "A stock part used in the construction of various devices." id = "triphasic_scanning" build_type = PROTOLATHE - materials = list(MAT_METAL = 200, MAT_GLASS = 200, MAT_DIAMOND = 30, MAT_BLUESPACE = 30) + materials = list(/datum/material/iron = 200, /datum/material/glass = 200, /datum/material/diamond = 30, /datum/material/bluespace = 30) build_path = /obj/item/stock_parts/scanning_module/triphasic category = list("Stock Parts") lathe_time_factor = 0.2 @@ -118,7 +118,7 @@ desc = "A stock part used in the construction of various devices." id = "micro_mani" build_type = PROTOLATHE | AUTOLATHE - materials = list(MAT_METAL = 100) + materials = list(/datum/material/iron = 100) build_path = /obj/item/stock_parts/manipulator category = list("Stock Parts","Machinery","initial") lathe_time_factor = 0.2 @@ -129,7 +129,7 @@ desc = "A stock part used in the construction of various devices." id = "nano_mani" build_type = PROTOLATHE - materials = list(MAT_METAL = 150) + materials = list(/datum/material/iron = 150) build_path = /obj/item/stock_parts/manipulator/nano category = list("Stock Parts") lathe_time_factor = 0.2 @@ -140,7 +140,7 @@ desc = "A stock part used in the construction of various devices." id = "pico_mani" build_type = PROTOLATHE - materials = list(MAT_METAL = 200) + materials = list(/datum/material/iron = 200) build_path = /obj/item/stock_parts/manipulator/pico category = list("Stock Parts") lathe_time_factor = 0.2 @@ -151,7 +151,7 @@ desc = "A stock part used in the construction of various devices." id = "femto_mani" build_type = PROTOLATHE - materials = list(MAT_METAL = 200, MAT_DIAMOND = 30, MAT_TITANIUM = 30) + materials = list(/datum/material/iron = 200, /datum/material/diamond = 30, /datum/material/titanium = 30) build_path = /obj/item/stock_parts/manipulator/femto category = list("Stock Parts") lathe_time_factor = 0.2 @@ -163,7 +163,7 @@ desc = "A stock part used in the construction of various devices." id = "basic_micro_laser" build_type = PROTOLATHE | AUTOLATHE - materials = list(MAT_METAL = 100, MAT_GLASS = 50) + materials = list(/datum/material/iron = 100, /datum/material/glass = 50) build_path = /obj/item/stock_parts/micro_laser category = list("Stock Parts","Machinery","initial") lathe_time_factor = 0.2 @@ -174,7 +174,7 @@ desc = "A stock part used in the construction of various devices." id = "high_micro_laser" build_type = PROTOLATHE - materials = list(MAT_METAL = 150, MAT_GLASS = 100) + materials = list(/datum/material/iron = 150, /datum/material/glass = 100) build_path = /obj/item/stock_parts/micro_laser/high category = list("Stock Parts") lathe_time_factor = 0.2 @@ -185,7 +185,7 @@ desc = "A stock part used in the construction of various devices." id = "ultra_micro_laser" build_type = PROTOLATHE - materials = list(MAT_METAL = 200, MAT_GLASS = 150, MAT_URANIUM = 60) + materials = list(/datum/material/iron = 200, /datum/material/glass = 150, /datum/material/uranium = 60) build_path = /obj/item/stock_parts/micro_laser/ultra category = list("Stock Parts") lathe_time_factor = 0.2 @@ -196,7 +196,7 @@ desc = "A stock part used in the construction of various devices." id = "quadultra_micro_laser" build_type = PROTOLATHE - materials = list(MAT_METAL = 200, MAT_GLASS = 200, MAT_URANIUM = 100, MAT_DIAMOND = 60) + materials = list(/datum/material/iron = 200, /datum/material/glass = 200, /datum/material/uranium = 100, /datum/material/diamond = 60) build_path = /obj/item/stock_parts/micro_laser/quadultra category = list("Stock Parts") lathe_time_factor = 0.2 @@ -207,7 +207,7 @@ desc = "A stock part used in the construction of various devices." id = "basic_matter_bin" build_type = PROTOLATHE | AUTOLATHE - materials = list(MAT_METAL = 100) + materials = list(/datum/material/iron = 100) build_path = /obj/item/stock_parts/matter_bin category = list("Stock Parts","Machinery","initial") lathe_time_factor = 0.2 @@ -218,7 +218,7 @@ desc = "A stock part used in the construction of various devices." id = "adv_matter_bin" build_type = PROTOLATHE - materials = list(MAT_METAL = 150) + materials = list(/datum/material/iron = 150) build_path = /obj/item/stock_parts/matter_bin/adv category = list("Stock Parts") lathe_time_factor = 0.2 @@ -229,7 +229,7 @@ desc = "A stock part used in the construction of various devices." id = "super_matter_bin" build_type = PROTOLATHE - materials = list(MAT_METAL = 200) + materials = list(/datum/material/iron = 200) build_path = /obj/item/stock_parts/matter_bin/super category = list("Stock Parts") lathe_time_factor = 0.2 @@ -240,7 +240,7 @@ desc = "A stock part used in the construction of various devices." id = "bluespace_matter_bin" build_type = PROTOLATHE - materials = list(MAT_METAL = 250, MAT_DIAMOND = 100, MAT_BLUESPACE = 100) + materials = list(/datum/material/iron = 250, /datum/material/diamond = 100, /datum/material/bluespace = 100) build_path = /obj/item/stock_parts/matter_bin/bluespace category = list("Stock Parts") lathe_time_factor = 0.2 @@ -252,7 +252,7 @@ desc = "A compact module capable of sensing extradimensional activity." id = "s-ansible" build_type = PROTOLATHE - materials = list(MAT_METAL = 100, MAT_SILVER = 100) + materials = list(/datum/material/iron = 100, /datum/material/silver = 100) build_path = /obj/item/stock_parts/subspace/ansible category = list("Stock Parts") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING | DEPARTMENTAL_FLAG_SCIENCE @@ -262,7 +262,7 @@ desc = "A tiny device capable of filtering and converting super-intense radiowaves." id = "s-filter" build_type = PROTOLATHE - materials = list(MAT_METAL = 100, MAT_SILVER = 100) + materials = list(/datum/material/iron = 100, /datum/material/silver = 100) build_path = /obj/item/stock_parts/subspace/filter category = list("Stock Parts") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING | DEPARTMENTAL_FLAG_SCIENCE @@ -272,7 +272,7 @@ desc = "A compact micro-machine capable of amplifying weak subspace transmissions." id = "s-amplifier" build_type = PROTOLATHE - materials = list(MAT_METAL = 100, MAT_GOLD = 100, MAT_URANIUM = 100) + materials = list(/datum/material/iron = 100, /datum/material/gold = 100, /datum/material/uranium = 100) build_path = /obj/item/stock_parts/subspace/amplifier category = list("Stock Parts") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING | DEPARTMENTAL_FLAG_SCIENCE @@ -282,7 +282,7 @@ desc = "A compact micro-machine capable of stretching out hyper-compressed radio waves." id = "s-treatment" build_type = PROTOLATHE - materials = list(MAT_METAL = 100, MAT_SILVER = 200) + materials = list(/datum/material/iron = 100, /datum/material/silver = 200) build_path = /obj/item/stock_parts/subspace/treatment category = list("Stock Parts") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING | DEPARTMENTAL_FLAG_SCIENCE @@ -292,7 +292,7 @@ desc = "A sophisticated analyzer capable of analyzing cryptic subspace wavelengths." id = "s-analyzer" build_type = PROTOLATHE - materials = list(MAT_METAL = 100, MAT_GOLD = 100) + materials = list(/datum/material/iron = 100, /datum/material/gold = 100) build_path = /obj/item/stock_parts/subspace/analyzer category = list("Stock Parts") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING | DEPARTMENTAL_FLAG_SCIENCE @@ -302,7 +302,7 @@ desc = "A sophisticated analyzer capable of analyzing cryptic subspace wavelengths." id = "s-crystal" build_type = PROTOLATHE - materials = list(MAT_GLASS = 800, MAT_SILVER = 100, MAT_GOLD = 100) + materials = list(/datum/material/glass = 800, /datum/material/silver = 100, /datum/material/gold = 100) build_path = /obj/item/stock_parts/subspace/crystal category = list("Stock Parts") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING | DEPARTMENTAL_FLAG_SCIENCE @@ -312,7 +312,7 @@ desc = "A large piece of equipment used to open a window into the subspace dimension." id = "s-transmitter" build_type = PROTOLATHE - materials = list(MAT_GLASS = 100, MAT_SILVER = 100, MAT_URANIUM = 100) + materials = list(/datum/material/glass = 100, /datum/material/silver = 100, /datum/material/uranium = 100) build_path = /obj/item/stock_parts/subspace/transmitter category = list("Stock Parts") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING | DEPARTMENTAL_FLAG_SCIENCE diff --git a/code/modules/research/designs/tool_designs.dm b/code/modules/research/designs/tool_designs.dm index 2a008185ec2b..5235ae8712b8 100644 --- a/code/modules/research/designs/tool_designs.dm +++ b/code/modules/research/designs/tool_designs.dm @@ -8,7 +8,7 @@ desc = "A small electric hand drill with an interchangeable screwdriver and bolt bit" id = "handdrill" build_type = PROTOLATHE - materials = list(MAT_METAL = 3500, MAT_SILVER = 1500, MAT_TITANIUM = 2500) + materials = list(/datum/material/iron = 3500, /datum/material/silver = 1500, /datum/material/titanium = 2500) build_path = /obj/item/handdrill category = list("Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -19,7 +19,7 @@ id = "jawsoflife" // added one more requirment since the Jaws of Life are a bit OP build_path = /obj/item/jawsoflife build_type = PROTOLATHE - materials = list(MAT_METAL = 4500, MAT_SILVER = 2500, MAT_TITANIUM = 3500) + materials = list(/datum/material/iron = 4500, /datum/material/silver = 2500, /datum/material/titanium = 3500) category = list("Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -28,7 +28,7 @@ desc = "An experimental welder capable of self-fuel generation." id = "exwelder" build_type = PROTOLATHE - materials = list(MAT_METAL = 1000, MAT_GLASS = 500, MAT_PLASMA = 1500, MAT_URANIUM = 200) + materials = list(/datum/material/iron = 1000, /datum/material/glass = 500, /datum/material/plasma = 1500, /datum/material/uranium = 200) build_path = /obj/item/weldingtool/experimental category = list("Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING @@ -38,7 +38,7 @@ desc = "Adds computer and machine frame designs to the RCD." id = "rcd_upgrade" build_type = PROTOLATHE - materials = list(MAT_METAL = 5000, MAT_GLASS = 2500, MAT_SILVER = 1500, MAT_TITANIUM = 2000) + materials = list(/datum/material/iron = 5000, /datum/material/glass = 2500, /datum/material/silver = 1500, /datum/material/titanium = 2000) build_path = /obj/item/rcd_upgrade category = list("Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -53,7 +53,7 @@ id = "alien_wrench" build_path = /obj/item/wrench/abductor build_type = PROTOLATHE - materials = list(MAT_METAL = 5000, MAT_SILVER = 2500, MAT_PLASMA = 1000, MAT_TITANIUM = 2000, MAT_DIAMOND = 2000) + materials = list(/datum/material/iron = 5000, /datum/material/silver = 2500, /datum/material/plasma = 1000, /datum/material/titanium = 2000, /datum/material/diamond = 2000) category = list("Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -63,7 +63,7 @@ id = "alien_wirecutters" build_path = /obj/item/wirecutters/abductor build_type = PROTOLATHE - materials = list(MAT_METAL = 5000, MAT_SILVER = 2500, MAT_PLASMA = 1000, MAT_TITANIUM = 2000, MAT_DIAMOND = 2000) + materials = list(/datum/material/iron = 5000, /datum/material/silver = 2500, /datum/material/plasma = 1000, /datum/material/titanium = 2000, /datum/material/diamond = 2000) category = list("Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -73,7 +73,7 @@ id = "alien_screwdriver" build_path = /obj/item/screwdriver/abductor build_type = PROTOLATHE - materials = list(MAT_METAL = 5000, MAT_SILVER = 2500, MAT_PLASMA = 1000, MAT_TITANIUM = 2000, MAT_DIAMOND = 2000) + materials = list(/datum/material/iron = 5000, /datum/material/silver = 2500, /datum/material/plasma = 1000, /datum/material/titanium = 2000, /datum/material/diamond = 2000) category = list("Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -83,7 +83,7 @@ id = "alien_crowbar" build_path = /obj/item/crowbar/abductor build_type = PROTOLATHE - materials = list(MAT_METAL = 5000, MAT_SILVER = 2500, MAT_PLASMA = 1000, MAT_TITANIUM = 2000, MAT_DIAMOND = 2000) + materials = list(/datum/material/iron = 5000, /datum/material/silver = 2500, /datum/material/plasma = 1000, /datum/material/titanium = 2000, /datum/material/diamond = 2000) category = list("Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -93,7 +93,7 @@ id = "alien_welder" build_path = /obj/item/weldingtool/abductor build_type = PROTOLATHE - materials = list(MAT_METAL = 5000, MAT_SILVER = 2500, MAT_PLASMA = 5000, MAT_TITANIUM = 2000, MAT_DIAMOND = 2000) + materials = list(/datum/material/iron = 5000, /datum/material/silver = 2500, /datum/material/plasma = 5000, /datum/material/titanium = 2000, /datum/material/diamond = 2000) category = list("Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -103,7 +103,7 @@ id = "alien_multitool" build_path = /obj/item/multitool/abductor build_type = PROTOLATHE - materials = list(MAT_METAL = 5000, MAT_SILVER = 2500, MAT_PLASMA = 5000, MAT_TITANIUM = 2000, MAT_DIAMOND = 2000) + materials = list(/datum/material/iron = 5000, /datum/material/silver = 2500, /datum/material/plasma = 5000, /datum/material/titanium = 2000, /datum/material/diamond = 2000) category = list("Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_ENGINEERING @@ -117,7 +117,7 @@ id = "alien_scalpel" build_path = /obj/item/scalpel/alien build_type = PROTOLATHE - materials = list(MAT_METAL = 2000, MAT_SILVER = 1500, MAT_PLASMA = 500, MAT_TITANIUM = 1500) + materials = list(/datum/material/iron = 2000, /datum/material/silver = 1500, /datum/material/plasma = 500, /datum/material/titanium = 1500) category = list("Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -127,7 +127,7 @@ id = "alien_hemostat" build_path = /obj/item/hemostat/alien build_type = PROTOLATHE - materials = list(MAT_METAL = 2000, MAT_SILVER = 1500, MAT_PLASMA = 500, MAT_TITANIUM = 1500) + materials = list(/datum/material/iron = 2000, /datum/material/silver = 1500, /datum/material/plasma = 500, /datum/material/titanium = 1500) category = list("Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -137,7 +137,7 @@ id = "alien_retractor" build_path = /obj/item/retractor/alien build_type = PROTOLATHE - materials = list(MAT_METAL = 2000, MAT_SILVER = 1500, MAT_PLASMA = 500, MAT_TITANIUM = 1500) + materials = list(/datum/material/iron = 2000, /datum/material/silver = 1500, /datum/material/plasma = 500, /datum/material/titanium = 1500) category = list("Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -147,7 +147,7 @@ id = "alien_saw" build_path = /obj/item/circular_saw/alien build_type = PROTOLATHE - materials = list(MAT_METAL = 10000, MAT_SILVER = 2500, MAT_PLASMA = 1000, MAT_TITANIUM = 1500) + materials = list(/datum/material/iron = 10000, /datum/material/silver = 2500, /datum/material/plasma = 1000, /datum/material/titanium = 1500) category = list("Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -157,7 +157,7 @@ id = "alien_drill" build_path = /obj/item/surgicaldrill/alien build_type = PROTOLATHE - materials = list(MAT_METAL = 10000, MAT_SILVER = 2500, MAT_PLASMA = 1000, MAT_TITANIUM = 1500) + materials = list(/datum/material/iron = 10000, /datum/material/silver = 2500, /datum/material/plasma = 1000, /datum/material/titanium = 1500) category = list("Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL @@ -167,6 +167,6 @@ id = "alien_cautery" build_path = /obj/item/cautery/alien build_type = PROTOLATHE - materials = list(MAT_METAL = 2000, MAT_SILVER = 1500, MAT_PLASMA = 500, MAT_TITANIUM = 1500) + materials = list(/datum/material/iron = 2000, /datum/material/silver = 1500, /datum/material/plasma = 500, /datum/material/titanium = 1500) category = list("Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL diff --git a/code/modules/research/designs/weapon_designs.dm b/code/modules/research/designs/weapon_designs.dm index a41dd1529fb4..50ae6bf045a9 100644 --- a/code/modules/research/designs/weapon_designs.dm +++ b/code/modules/research/designs/weapon_designs.dm @@ -13,7 +13,7 @@ desc = "Designed to quickly reload revolvers. TRAC bullets embed a tracking implant within the target's body." id = "c38_trac" build_type = PROTOLATHE - materials = list(MAT_METAL = 20000, MAT_SILVER = 5000, MAT_GOLD = 1000) + materials = list(/datum/material/iron = 20000, /datum/material/silver = 5000, /datum/material/gold = 1000) build_path = /obj/item/ammo_box/c38/trac category = list("Ammo") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -23,7 +23,7 @@ desc = "Designed to quickly reload revolvers. Hot Shot bullets contain an incendiary payload." id = "c38_hotshot" build_type = PROTOLATHE - materials = list(MAT_METAL = 20000, MAT_PLASMA = 5000) + materials = list(/datum/material/iron = 20000, /datum/material/plasma = 5000) build_path = /obj/item/ammo_box/c38/hotshot category = list("Ammo") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -33,7 +33,7 @@ desc = "Designed to quickly reload revolvers. Iceblox bullets contain a cryogenic payload." id = "c38_iceblox" build_type = PROTOLATHE - materials = list(MAT_METAL = 20000, MAT_PLASMA = 5000) + materials = list(/datum/material/iron = 20000, /datum/material/plasma = 5000) build_path = /obj/item/ammo_box/c38/iceblox category = list("Ammo") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -79,7 +79,7 @@ desc = "A 12 gauge anti-material slug. Great for breaching airlocks and windows with minimal shots." id = "sec_Brslug" build_type = PROTOLATHE - materials = list(MAT_METAL = 4000) + materials = list(/datum/material/iron = 4000) build_path = /obj/item/ammo_casing/shotgun/breacher category = list("Ammo") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -89,7 +89,7 @@ desc = "This safety firing pin allows firearms to be operated within proximity to a firing range." id = "pin_testing" build_type = PROTOLATHE - materials = list(MAT_METAL = 500, MAT_GLASS = 300) + materials = list(/datum/material/iron = 500, /datum/material/glass = 300) build_path = /obj/item/firing_pin/test_range category = list("Firing Pins") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -99,7 +99,7 @@ desc = "This is a security firing pin which only authorizes users who are mindshield-implanted." id = "pin_loyalty" build_type = PROTOLATHE - materials = list(MAT_SILVER = 600, MAT_DIAMOND = 600, MAT_URANIUM = 200) + materials = list(/datum/material/silver = 600, /datum/material/diamond = 600, /datum/material/uranium = 200) build_path = /obj/item/firing_pin/implant/mindshield category = list("Firing Pins") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -109,7 +109,7 @@ desc = "A basic non-lethal stunning mine. Stuns anyone who walks over it." id = "stunmine" build_type = PROTOLATHE - materials = list(MAT_METAL = 4000, MAT_GLASS = 1000) + materials = list(/datum/material/iron = 4000, /datum/material/glass = 1000) build_path = /obj/item/deployablemine/stun category = list("Ammo") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -119,7 +119,7 @@ desc = "An advanced non-lethal stunning mine. Uses advanced detection software to only trigger when activated by someone without a mindshield implant." id = "stunmine_adv" build_type = PROTOLATHE - materials = list(MAT_METAL = 8000, MAT_GLASS = 3000, MAT_SILVER = 200) + materials = list(/datum/material/iron = 8000, /datum/material/glass = 3000, /datum/material/silver = 200) build_path = /obj/item/deployablemine/smartstun category = list("Ammo") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -129,7 +129,7 @@ desc = "An advanced non-lethal stunning mine. Uses advanced detection software to only trigger when activated by someone without a mindshield implant. Can be rapidly placed and disarmed." id = "stunmine_rapid" build_type = PROTOLATHE - materials = list(MAT_METAL = 10000, MAT_GLASS = 4000, MAT_SILVER = 500, MAT_URANIUM = 200) + materials = list(/datum/material/iron = 10000, /datum/material/glass = 4000, /datum/material/silver = 500, /datum/material/uranium = 200) build_path = /obj/item/deployablemine/rapid category = list("Ammo") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -139,7 +139,7 @@ desc = "An advanced non-lethal stunning mine. Uses advanced detection software to only trigger when activated by someone without a mindshield implant. Very powerful and hard to disarm." id = "stunmine_heavy" build_type = PROTOLATHE - materials = list(MAT_METAL = 10000, MAT_GLASS = 4000, MAT_SILVER = 500, MAT_URANIUM = 200) + materials = list(/datum/material/iron = 10000, /datum/material/glass = 4000, /datum/material/silver = 500, /datum/material/uranium = 200) build_path = /obj/item/deployablemine/heavy category = list("Ammo") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -149,7 +149,7 @@ desc = "An advanced pressure activated pranking mine, honk!" id = "clown_mine" build_type = PROTOLATHE - materials = list(MAT_METAL = 4000, MAT_GLASS = 1000, MAT_BANANIUM = 500) + materials = list(/datum/material/iron = 4000, /datum/material/glass = 1000, /datum/material/bananium = 500) build_path = /obj/item/deployablemine/honk category = list("Ammo") departmental_flags = DEPARTMENTAL_FLAG_SERVICE @@ -159,7 +159,7 @@ desc = "A high-tech revolver that fires internal, reusable shock cartridges in a revolving cylinder. The cartridges can be recharged using conventional rechargers." id = "stunrevolver" build_type = PROTOLATHE - materials = list(MAT_METAL = 10000, MAT_GLASS = 10000, MAT_SILVER = 10000) + materials = list(/datum/material/iron = 10000, /datum/material/glass = 10000, /datum/material/silver = 10000) build_path = /obj/item/gun/energy/tesla_revolver category = list("Weapons") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -169,7 +169,7 @@ desc = "An energy gun with an experimental miniaturized reactor." id = "nuclear_gun" build_type = PROTOLATHE - materials = list(MAT_METAL = 10000, MAT_GLASS = 2000, MAT_URANIUM = 3000, MAT_TITANIUM = 1000) + materials = list(/datum/material/iron = 10000, /datum/material/glass = 2000, /datum/material/uranium = 3000, /datum/material/titanium = 1000) build_path = /obj/item/gun/energy/e_gun/nuclear category = list("Weapons") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -179,7 +179,7 @@ desc = "An advanced riot shield made of lightweight materials that collapses for easy storage." id = "tele_shield" build_type = PROTOLATHE - materials = list(MAT_METAL = 4000, MAT_GLASS = 4000, MAT_SILVER = 300, MAT_TITANIUM = 200) + materials = list(/datum/material/iron = 4000, /datum/material/glass = 4000, /datum/material/silver = 300, /datum/material/titanium = 200) build_path = /obj/item/shield/riot/tele category = list("Weapons") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -189,7 +189,7 @@ desc = "A powerful long ranged anti-material rifle that fires charged particle beams to obliterate targets." id = "beamrifle" build_type = PROTOLATHE - materials = list(MAT_METAL = 10000, MAT_GLASS = 5000, MAT_DIAMOND = 5000, MAT_URANIUM = 8000, MAT_SILVER = 4500, MAT_GOLD = 5000) + materials = list(/datum/material/iron = 10000, /datum/material/glass = 5000, /datum/material/diamond = 5000, /datum/material/uranium = 8000, /datum/material/silver = 4500, /datum/material/gold = 5000) build_path = /obj/item/gun/energy/beam_rifle category = list("Weapons") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -199,7 +199,7 @@ desc = "Your opponent will bubble into a messy pile of goop." id = "decloner" build_type = PROTOLATHE - materials = list(MAT_GOLD = 5000,MAT_URANIUM = 10000) + materials = list(/datum/material/gold = 5000,/datum/material/uranium = 10000) reagents_list = list(/datum/reagent/toxin/mutagen = 40) build_path = /obj/item/gun/energy/decloner category = list("Weapons") @@ -210,7 +210,7 @@ desc = "A gun that fires many syringes." id = "rapidsyringe" build_type = PROTOLATHE - materials = list(MAT_METAL = 5000, MAT_GLASS = 1000) + materials = list(/datum/material/iron = 5000, /datum/material/glass = 1000) build_path = /obj/item/gun/syringe/rapidsyringe category = list("Weapons") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL //uwu @@ -220,7 +220,7 @@ desc = "A gun that shoots temperature energy beams to change temperature." id = "temp_gun" build_type = PROTOLATHE - materials = list(MAT_METAL = 5000, MAT_GLASS = 500, MAT_SILVER = 3000) + materials = list(/datum/material/iron = 5000, /datum/material/glass = 500, /datum/material/silver = 3000) build_path = /obj/item/gun/energy/temperature category = list("Weapons") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -230,7 +230,7 @@ desc = "A tool that discharges controlled radiation which induces mutation in plant cells. Harmless to other organic life." id = "flora_gun" build_type = PROTOLATHE - materials = list(MAT_METAL = 2000, MAT_GLASS = 500) + materials = list(/datum/material/iron = 2000, /datum/material/glass = 500) reagents_list = list(/datum/reagent/uranium/radium = 20) build_path = /obj/item/gun/energy/floragun category = list("Weapons") @@ -241,7 +241,7 @@ desc = "A grenade that affects a larger area and uses larger containers." id = "large_Grenade" build_type = PROTOLATHE - materials = list(MAT_METAL = 3000) + materials = list(/datum/material/iron = 3000) build_path = /obj/item/grenade/chem_grenade/large category = list("Weapons") departmental_flags = DEPARTMENTAL_FLAG_SECURITY | DEPARTMENTAL_FLAG_MEDICAL @@ -251,7 +251,7 @@ desc = "An advanced grenade that is able to self ignite its mixture." id = "pyro_Grenade" build_type = PROTOLATHE - materials = list(MAT_METAL = 2000, MAT_PLASMA = 500) + materials = list(/datum/material/iron = 2000, /datum/material/plasma = 500) build_path = /obj/item/grenade/chem_grenade/pyro category = list("Weapons") departmental_flags = DEPARTMENTAL_FLAG_SECURITY | DEPARTMENTAL_FLAG_MEDICAL @@ -261,7 +261,7 @@ desc = "An advanced grenade that rapidly cools its contents upon detonation." id = "cryo_Grenade" build_type = PROTOLATHE - materials = list(MAT_METAL = 2000, MAT_SILVER = 500) + materials = list(/datum/material/iron = 2000, /datum/material/silver = 500) build_path = /obj/item/grenade/chem_grenade/cryo category = list("Weapons") departmental_flags = DEPARTMENTAL_FLAG_SECURITY | DEPARTMENTAL_FLAG_MEDICAL @@ -271,7 +271,7 @@ desc = "An advanced grenade that can be detonated several times, best used with a repeating igniter." id = "adv_Grenade" build_type = PROTOLATHE - materials = list(MAT_METAL = 3000, MAT_GLASS = 500) + materials = list(/datum/material/iron = 3000, /datum/material/glass = 500) build_path = /obj/item/grenade/chem_grenade/adv_release category = list("Weapons") departmental_flags = DEPARTMENTAL_FLAG_SECURITY | DEPARTMENTAL_FLAG_MEDICAL @@ -281,7 +281,7 @@ desc = "Not quite as menacing as it sounds." id = "xray_laser" build_type = PROTOLATHE - materials = list(MAT_GOLD = 5000, MAT_URANIUM = 4000, MAT_METAL = 5000, MAT_TITANIUM = 2000, MAT_BLUESPACE = 2000) + materials = list(/datum/material/gold = 5000, /datum/material/uranium = 4000, /datum/material/iron = 5000, /datum/material/titanium = 2000, /datum/material/bluespace = 2000) build_path = /obj/item/gun/energy/xray category = list("Weapons") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -291,7 +291,7 @@ desc = "How to dismantle a cyborg: The gun." id = "ioncarbine" build_type = PROTOLATHE - materials = list(MAT_SILVER = 6000, MAT_METAL = 8000, MAT_URANIUM = 2000) + materials = list(/datum/material/silver = 6000, /datum/material/iron = 8000, /datum/material/uranium = 2000) build_path = /obj/item/gun/energy/ionrifle/carbine category = list("Weapons") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -301,7 +301,7 @@ desc = "A projector that emits high density quantum-coupled bluespace beams." id = "wormholeprojector" build_type = PROTOLATHE - materials = list(MAT_SILVER = 2000, MAT_METAL = 5000, MAT_DIAMOND = 2000, MAT_BLUESPACE = 3000) + materials = list(/datum/material/silver = 2000, /datum/material/iron = 5000, /datum/material/diamond = 2000, /datum/material/bluespace = 3000) build_path = /obj/item/gun/energy/wormhole_projector category = list("Weapons") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -313,7 +313,7 @@ desc = "A 20 round magazine for the out of date security WT-550 Auto Rifle." id = "mag_oldsmg" build_type = PROTOLATHE - materials = list(MAT_METAL = 4000) + materials = list(/datum/material/iron = 4000) build_path = /obj/item/ammo_box/magazine/wt550m9 category = list("Ammo") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -322,7 +322,7 @@ name = "WT-550 Auto Gun Armour Piercing Magazine (4.6x30mm AP)" desc = "A 20 round armour piercing magazine for the out of date security WT-550 Auto Rifle." id = "mag_oldsmg_ap" - materials = list(MAT_METAL = 6000, MAT_SILVER = 600) + materials = list(/datum/material/iron = 6000, /datum/material/silver = 600) build_path = /obj/item/ammo_box/magazine/wt550m9/wtap departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -330,7 +330,7 @@ name = "WT-550 Auto Gun Incendiary Magazine (4.6x30mm IC)" desc = "A 20 round armour piercing magazine for the out of date security WT-550 Auto Rifle." id = "mag_oldsmg_ic" - materials = list(MAT_METAL = 6000, MAT_SILVER = 600, MAT_GLASS = 1000) + materials = list(/datum/material/iron = 6000, /datum/material/silver = 600, /datum/material/glass = 1000) build_path = /obj/item/ammo_box/magazine/wt550m9/wtic departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -338,7 +338,7 @@ name = "WT-550 Auto Gun Rubber Bullet Magazine (4.6x30mm Rubber)" desc = "A 20 round rubber bullet magazine for the out of date security WT-550 Auto Rifle." id = "mag_oldsmg_rubber" - materials = list(MAT_METAL = 4000) + materials = list(/datum/material/iron = 4000) build_path = /obj/item/ammo_box/magazine/wt550m9/wtr departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -347,7 +347,7 @@ desc = "A stunning shell for a shotgun." id = "stunshell" build_type = PROTOLATHE - materials = list(MAT_METAL = 200) + materials = list(/datum/material/iron = 200) build_path = /obj/item/ammo_casing/shotgun/stunslug category = list("Ammo") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -357,7 +357,7 @@ desc = "A high-tech shotgun shell which can be loaded with materials to produce unique effects." id = "techshotshell" build_type = PROTOLATHE - materials = list(MAT_METAL = 1000, MAT_GLASS = 200) + materials = list(/datum/material/iron = 1000, /datum/material/glass = 200) build_path = /obj/item/ammo_casing/shotgun/techshell category = list("Ammo") departmental_flags = DEPARTMENTAL_FLAG_SECURITY | DEPARTMENTAL_FLAG_SCIENCE @@ -367,7 +367,7 @@ desc = "A reverse-engineered suppressor that fits on most small arms with threaded barrels." id = "suppressor" build_type = PROTOLATHE - materials = list(MAT_METAL = 2000, MAT_SILVER = 500) + materials = list(/datum/material/iron = 2000, /datum/material/silver = 500) build_path = /obj/item/suppressor category = list("Weapons") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -377,7 +377,7 @@ desc = "A multi-mode device that blasts one-point bluespace-gravitational bolts that locally distort gravity." id = "gravitygun" build_type = PROTOLATHE - materials = list(MAT_SILVER = 8000, MAT_URANIUM = 8000, MAT_GLASS = 12000, MAT_METAL = 12000, MAT_DIAMOND = 3000, MAT_BLUESPACE = 3000) + materials = list(/datum/material/silver = 8000, /datum/material/uranium = 8000, /datum/material/glass = 12000, /datum/material/iron = 12000, /datum/material/diamond = 3000, /datum/material/bluespace = 3000) build_path = /obj/item/gun/energy/gravity_gun category = list("Weapons") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE @@ -387,7 +387,7 @@ desc = "A reverse-engineered energy crossbow favored by syndicate infiltration teams and carp hunters." id = "largecrossbow" build_type = PROTOLATHE - materials = list(MAT_METAL = 5000, MAT_GLASS = 1500, MAT_URANIUM = 1500, MAT_SILVER = 1500) + materials = list(/datum/material/iron = 5000, /datum/material/glass = 1500, /datum/material/uranium = 1500, /datum/material/silver = 1500) build_path = /obj/item/gun/energy/kinetic_accelerator/crossbow/large category = list("Weapons") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -397,7 +397,7 @@ desc = "A shotgun dart designed with similar internals to that of a cryostatis beaker, allowing reagents to not react when inside." id = "shotgundartcryostatis" build_type = PROTOLATHE - materials = list(MAT_METAL = 3500) + materials = list(/datum/material/iron = 3500) build_path = /obj/item/ammo_casing/shotgun/dart/noreact category = list("Ammo") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL diff --git a/code/modules/research/destructive_analyzer.dm b/code/modules/research/destructive_analyzer.dm index 7dd7b76007b8..71ba12637083 100644 --- a/code/modules/research/destructive_analyzer.dm +++ b/code/modules/research/destructive_analyzer.dm @@ -63,7 +63,7 @@ Note: Must be placed within 3 tiles of the R&D Console if(storage) //Also sends salvaged materials to a linked protolathe, if any. for(var/material in thing.materials) var/can_insert = min((storage.max_amount - storage.total_amount), (max(thing.materials[material]*(decon_mod/10), thing.materials[material]))) - storage.insert_amount(can_insert, material) + storage.insert_amount_mat(can_insert, material) . += can_insert if (.) linked_console.linked_lathe.materials.silo_log(src, "reclaimed", 1, "[thing.name]", thing.materials) diff --git a/code/modules/research/experimentor.dm b/code/modules/research/experimentor.dm index a4b0b3ce9c76..97195dd55da2 100644 --- a/code/modules/research/experimentor.dm +++ b/code/modules/research/experimentor.dm @@ -483,7 +483,7 @@ if(linked_console.linked_lathe) var/datum/component/material_container/linked_materials = linked_console.linked_lathe.GetComponent(/datum/component/material_container) for(var/material in exp_on.materials) - linked_materials.insert_amount( min((linked_materials.max_amount - linked_materials.total_amount), (exp_on.materials[material])), material) + linked_materials.insert_amount_mat( min((linked_materials.max_amount - linked_materials.total_amount), (exp_on.materials[material])), material) if(prob(EFFECT_PROB_LOW) && criticalReaction) visible_message("[src]'s crushing mechanism slowly and smoothly descends, flattening the [exp_on]!") new /obj/item/stack/sheet/plasteel(get_turf(pick(oview(1,src)))) diff --git a/code/modules/research/machinery/_production.dm b/code/modules/research/machinery/_production.dm index 42409e6de891..60a580701fa2 100644 --- a/code/modules/research/machinery/_production.dm +++ b/code/modules/research/machinery/_production.dm @@ -91,19 +91,19 @@ I.materials = matlist.Copy() SSblackbox.record_feedback("nested tally", "item_printed", amount, list("[type]", "[path]")) -/obj/machinery/rnd/production/proc/check_mat(datum/design/being_built, M) // now returns how many times the item can be built with the material +/obj/machinery/rnd/production/proc/check_mat(datum/design/being_built, var/mat) // now returns how many times the item can be built with the material if (!materials.mat_container) // no connected silo return 0 var/list/all_materials = being_built.reagents_list + being_built.materials - var/A = materials.mat_container.amount(M) + var/A = materials.mat_container.get_material_amount(mat) if(!A) - A = reagents.get_reagent_amount(M) + A = reagents.get_reagent_amount(mat) // these types don't have their .materials set in do_print, so don't allow // them to be constructed efficiently var/ef = efficient_with(being_built.build_path) ? efficiency_coeff : 1 - return round(A / max(1, all_materials[M] / ef)) + return round(A / max(1, all_materials[mat] / ef)) /obj/machinery/rnd/production/proc/efficient_with(path) return !ispath(path, /obj/item/stack/sheet) && !ispath(path, /obj/item/stack/ore/bluespace_crystal) @@ -147,7 +147,7 @@ if(!reagents.has_reagent(R, D.reagents_list[R]*amount/coeff)) say("Not enough reagents to complete prototype[amount > 1? "s" : ""].") return FALSE - materials.mat_container.use_amount(efficient_mats, amount) + materials.mat_container.use_materials(efficient_mats, amount) materials.silo_log(src, "built", -amount, "[D.name]", efficient_mats) for(var/R in D.reagents_list) reagents.remove_reagent(R, D.reagents_list[R]*amount/coeff) @@ -208,11 +208,13 @@ var/list/l = list() l += "

Material Storage:

" for(var/mat_id in materials.mat_container.materials) - var/datum/material/M = materials.mat_container.materials[mat_id] - l += "* [num2text(M.amount, 8)] of [M.name]: " // yogs - num2text - if(M.amount >= MINERAL_MATERIAL_AMOUNT) l += "Eject [RDSCREEN_NOBREAK]" - if(M.amount >= MINERAL_MATERIAL_AMOUNT*5) l += "5x [RDSCREEN_NOBREAK]" - if(M.amount >= MINERAL_MATERIAL_AMOUNT) l += "All[RDSCREEN_NOBREAK]" + var/datum/material/M = mat_id + var/amount = materials.mat_container.materials[mat_id] + var/ref = REF(M) + l += "* [amount] of [M.name]: " + if(amount >= MINERAL_MATERIAL_AMOUNT) l += "Eject [RDSCREEN_NOBREAK]" + if(amount >= MINERAL_MATERIAL_AMOUNT*5) l += "5x [RDSCREEN_NOBREAK]" + if(amount >= MINERAL_MATERIAL_AMOUNT) l += "All[RDSCREEN_NOBREAK]" l += "" l += "
[RDSCREEN_NOBREAK]" return l @@ -300,7 +302,8 @@ if(ls["disposeall"]) //Causes the protolathe to dispose of all it's reagents. reagents.clear_reagents() if(ls["ejectsheet"]) //Causes the protolathe to eject a sheet of material - eject_sheets(ls["ejectsheet"], ls["eject_amt"]) + var/datum/material/M = locate(ls["ejectsheet"]) + eject_sheets(M, ls["eject_amt"]) updateUsrDialog() /obj/machinery/rnd/production/proc/eject_sheets(eject_sheet, eject_amt) diff --git a/code/modules/research/rdconsole.dm b/code/modules/research/rdconsole.dm index db75ad674e35..c1df27cc95c6 100644 --- a/code/modules/research/rdconsole.dm +++ b/code/modules/research/rdconsole.dm @@ -51,15 +51,15 @@ Nothing else in the console has ID requirements. // In addition it displays the coordinates of the node in the tooltip. // Use this when making new techweb nodes to determine a good position for it. // It will also prevent clicking on nodes. - var/do_node_drag = FALSE + var/do_node_drag = FALSE /obj/machinery/computer/rdconsole/production circuit = /obj/item/circuitboard/computer/rdconsole/production research_control = FALSE /proc/CallMaterialName(ID) - if (copytext(ID, 1, 2) == "$" && GLOB.materials_list[ID]) - var/datum/material/material = GLOB.materials_list[ID] + if (istype(ID, /datum/material)) + var/datum/material/material = ID return material.name else if(GLOB.chemical_reagents_list[ID]) @@ -389,11 +389,12 @@ Nothing else in the console has ID requirements. l += ui_protolathe_header() l += "

Material Storage:

" for(var/mat_id in mat_container.materials) - var/datum/material/M = mat_container.materials[mat_id] - l += "* [num2text(M.amount, 8)] of [M.name]: " // yogs - num2text - if(M.amount >= MINERAL_MATERIAL_AMOUNT) l += "Eject [RDSCREEN_NOBREAK]" - if(M.amount >= MINERAL_MATERIAL_AMOUNT*5) l += "5x [RDSCREEN_NOBREAK]" - if(M.amount >= MINERAL_MATERIAL_AMOUNT) l += "All[RDSCREEN_NOBREAK]" + var/datum/material/M = mat_id + var/amount = mat_container.materials[mat_id] + l += "* [amount] of [M.name]: " + if(amount >= MINERAL_MATERIAL_AMOUNT) l += "Eject [RDSCREEN_NOBREAK]" + if(amount >= MINERAL_MATERIAL_AMOUNT*5) l += "5x [RDSCREEN_NOBREAK]" + if(amount >= MINERAL_MATERIAL_AMOUNT) l += "All[RDSCREEN_NOBREAK]" l += "" l += "
[RDSCREEN_NOBREAK]" return l @@ -522,11 +523,12 @@ Nothing else in the console has ID requirements. l += ui_circuit_header() l += "

Material Storage:

" for(var/mat_id in mat_container.materials) - var/datum/material/M = mat_container.materials[mat_id] - l += "* [M.amount] of [M.name]: " - if(M.amount >= MINERAL_MATERIAL_AMOUNT) l += "Eject [RDSCREEN_NOBREAK]" - if(M.amount >= MINERAL_MATERIAL_AMOUNT*5) l += "5x [RDSCREEN_NOBREAK]" - if(M.amount >= MINERAL_MATERIAL_AMOUNT) l += "All[RDSCREEN_NOBREAK]
" + var/datum/material/M = mat_id + var/amount = mat_container.materials[mat_id] + l += "* [amount] of [M.name]: " + if(amount >= MINERAL_MATERIAL_AMOUNT) l += "Eject [RDSCREEN_NOBREAK]" + if(amount >= MINERAL_MATERIAL_AMOUNT*5) l += "5x [RDSCREEN_NOBREAK]" + if(amount >= MINERAL_MATERIAL_AMOUNT) l += "All[RDSCREEN_NOBREAK]" return l /obj/machinery/computer/rdconsole/proc/ui_techdisk() //Legacy code @@ -1026,7 +1028,7 @@ Nothing else in the console has ID requirements. D.category -= "Imported" else for(var/x in D.materials) - if( !(x in list(MAT_METAL, MAT_GLASS))) + if( !(x in list(/datum/material/iron, /datum/material/glass))) autolathe_friendly = FALSE D.category -= "Imported" diff --git a/code/modules/research/research_disk.dm b/code/modules/research/research_disk.dm index dd9d124a2e1a..83d8fd81d0a2 100644 --- a/code/modules/research/research_disk.dm +++ b/code/modules/research/research_disk.dm @@ -3,7 +3,7 @@ name = "technology disk" desc = "A disk for storing technology data for further research." icon_state = "datadisk0" - materials = list(MAT_METAL=300, MAT_GLASS=100) + materials = list(/datum/material/iron=300, /datum/material/glass=100) var/datum/techweb/stored_research /obj/item/disk/tech_disk/Initialize() diff --git a/code/modules/research/stock_parts.dm b/code/modules/research/stock_parts.dm index 0c72e68b5cc2..8cf1fb8f6bef 100644 --- a/code/modules/research/stock_parts.dm +++ b/code/modules/research/stock_parts.dm @@ -132,31 +132,31 @@ If you create T5+ please take a pass at gene_modder.dm [L40]. Max_values MUST fi name = "capacitor" desc = "A basic capacitor used in the construction of a variety of devices." icon_state = "capacitor" - materials = list(MAT_METAL=50, MAT_GLASS=50) + materials = list(/datum/material/iron=50, /datum/material/glass=50) /obj/item/stock_parts/scanning_module name = "scanning module" desc = "A compact, high resolution scanning module used in the construction of certain devices." icon_state = "scan_module" - materials = list(MAT_METAL=50, MAT_GLASS=20) + materials = list(/datum/material/iron=50, /datum/material/glass=20) /obj/item/stock_parts/manipulator name = "micro-manipulator" desc = "A tiny little manipulator used in the construction of certain devices." icon_state = "micro_mani" - materials = list(MAT_METAL=30) + materials = list(/datum/material/iron=30) /obj/item/stock_parts/micro_laser name = "micro-laser" desc = "A tiny laser used in certain devices." icon_state = "micro_laser" - materials = list(MAT_METAL=10, MAT_GLASS=20) + materials = list(/datum/material/iron=10, /datum/material/glass=20) /obj/item/stock_parts/matter_bin name = "matter bin" desc = "A container designed to hold compressed matter awaiting reconstruction." icon_state = "matter_bin" - materials = list(MAT_METAL=80) + materials = list(/datum/material/iron=80) //Rating 2 @@ -165,35 +165,35 @@ If you create T5+ please take a pass at gene_modder.dm [L40]. Max_values MUST fi desc = "An advanced capacitor used in the construction of a variety of devices." icon_state = "adv_capacitor" rating = 2 - materials = list(MAT_METAL=50, MAT_GLASS=50) + materials = list(/datum/material/iron=50, /datum/material/glass=50) /obj/item/stock_parts/scanning_module/adv name = "advanced scanning module" desc = "A compact, high resolution scanning module used in the construction of certain devices." icon_state = "adv_scan_module" rating = 2 - materials = list(MAT_METAL=50, MAT_GLASS=20) + materials = list(/datum/material/iron=50, /datum/material/glass=20) /obj/item/stock_parts/manipulator/nano name = "nano-manipulator" desc = "A tiny little manipulator used in the construction of certain devices." icon_state = "nano_mani" rating = 2 - materials = list(MAT_METAL=30) + materials = list(/datum/material/iron=30) /obj/item/stock_parts/micro_laser/high name = "high-power micro-laser" desc = "A tiny laser used in certain devices." icon_state = "high_micro_laser" rating = 2 - materials = list(MAT_METAL=10, MAT_GLASS=20) + materials = list(/datum/material/iron=10, /datum/material/glass=20) /obj/item/stock_parts/matter_bin/adv name = "advanced matter bin" desc = "A container designed to hold compressed matter awaiting reconstruction." icon_state = "advanced_matter_bin" rating = 2 - materials = list(MAT_METAL=80) + materials = list(/datum/material/iron=80) //Rating 3 @@ -202,35 +202,35 @@ If you create T5+ please take a pass at gene_modder.dm [L40]. Max_values MUST fi desc = "A super-high capacity capacitor used in the construction of a variety of devices." icon_state = "super_capacitor" rating = 3 - materials = list(MAT_METAL=50, MAT_GLASS=50) + materials = list(/datum/material/iron=50, /datum/material/glass=50) /obj/item/stock_parts/scanning_module/phasic name = "phasic scanning module" desc = "A compact, high resolution phasic scanning module used in the construction of certain devices." icon_state = "super_scan_module" rating = 3 - materials = list(MAT_METAL=50, MAT_GLASS=20) + materials = list(/datum/material/iron=50, /datum/material/glass=20) /obj/item/stock_parts/manipulator/pico name = "pico-manipulator" desc = "A tiny little manipulator used in the construction of certain devices." icon_state = "pico_mani" rating = 3 - materials = list(MAT_METAL=30) + materials = list(/datum/material/iron=30) /obj/item/stock_parts/micro_laser/ultra name = "ultra-high-power micro-laser" icon_state = "ultra_high_micro_laser" desc = "A tiny laser used in certain devices." rating = 3 - materials = list(MAT_METAL=10, MAT_GLASS=20) + materials = list(/datum/material/iron=10, /datum/material/glass=20) /obj/item/stock_parts/matter_bin/super name = "super matter bin" desc = "A container designed to hold compressed matter awaiting reconstruction." icon_state = "super_matter_bin" rating = 3 - materials = list(MAT_METAL=80) + materials = list(/datum/material/iron=80) //Rating 4 @@ -239,35 +239,35 @@ If you create T5+ please take a pass at gene_modder.dm [L40]. Max_values MUST fi desc = "A quadratic capacitor used in the construction of a variety of devices." icon_state = "quadratic_capacitor" rating = 4 - materials = list(MAT_METAL=50, MAT_GLASS=50) + materials = list(/datum/material/iron=50, /datum/material/glass=50) /obj/item/stock_parts/scanning_module/triphasic name = "triphasic scanning module" desc = "A compact, ultra resolution triphasic scanning module used in the construction of certain devices." icon_state = "triphasic_scan_module" rating = 4 - materials = list(MAT_METAL=50, MAT_GLASS=20) + materials = list(/datum/material/iron=50, /datum/material/glass=20) /obj/item/stock_parts/manipulator/femto name = "femto-manipulator" desc = "A tiny manipulator used in the construction of certain devices." icon_state = "femto_mani" rating = 4 - materials = list(MAT_METAL=30) + materials = list(/datum/material/iron=30) /obj/item/stock_parts/micro_laser/quadultra name = "quad-ultra micro-laser" icon_state = "quadultra_micro_laser" desc = "A tiny laser used in certain devices." rating = 4 - materials = list(MAT_METAL=10, MAT_GLASS=20) + materials = list(/datum/material/iron=10, /datum/material/glass=20) /obj/item/stock_parts/matter_bin/bluespace name = "bluespace matter bin" desc = "A container designed to hold compressed matter awaiting reconstruction." icon_state = "bluespace_matter_bin" rating = 4 - materials = list(MAT_METAL=80) + materials = list(/datum/material/iron=80) // Subspace stock parts @@ -275,43 +275,43 @@ If you create T5+ please take a pass at gene_modder.dm [L40]. Max_values MUST fi name = "subspace ansible" icon_state = "subspace_ansible" desc = "A compact module capable of sensing extradimensional activity." - materials = list(MAT_METAL=30, MAT_GLASS=10) + materials = list(/datum/material/iron=30, /datum/material/glass=10) /obj/item/stock_parts/subspace/filter name = "hyperwave filter" icon_state = "hyperwave_filter" desc = "A tiny device capable of filtering and converting super-intense radiowaves." - materials = list(MAT_METAL=30, MAT_GLASS=10) + materials = list(/datum/material/iron=30, /datum/material/glass=10) /obj/item/stock_parts/subspace/amplifier name = "subspace amplifier" icon_state = "subspace_amplifier" desc = "A compact micro-machine capable of amplifying weak subspace transmissions." - materials = list(MAT_METAL=30, MAT_GLASS=10) + materials = list(/datum/material/iron=30, /datum/material/glass=10) /obj/item/stock_parts/subspace/treatment name = "subspace treatment disk" icon_state = "treatment_disk" desc = "A compact micro-machine capable of stretching out hyper-compressed radio waves." - materials = list(MAT_METAL=30, MAT_GLASS=10) + materials = list(/datum/material/iron=30, /datum/material/glass=10) /obj/item/stock_parts/subspace/analyzer name = "subspace wavelength analyzer" icon_state = "wavelength_analyzer" desc = "A sophisticated analyzer capable of analyzing cryptic subspace wavelengths." - materials = list(MAT_METAL=30, MAT_GLASS=10) + materials = list(/datum/material/iron=30, /datum/material/glass=10) /obj/item/stock_parts/subspace/crystal name = "ansible crystal" icon_state = "ansible_crystal" desc = "A crystal made from pure glass used to transmit laser databursts to subspace." - materials = list(MAT_GLASS=50) + materials = list(/datum/material/glass=50) /obj/item/stock_parts/subspace/transmitter name = "subspace transmitter" icon_state = "subspace_transmitter" desc = "A large piece of equipment used to open a window into the subspace dimension." - materials = list(MAT_METAL=50) + materials = list(/datum/material/iron=50) /obj/item/research//Makes testing much less of a pain -Sieve name = "research" diff --git a/code/modules/research/xenobiology/xenobiology.dm b/code/modules/research/xenobiology/xenobiology.dm index 6ffe9a10b963..dd5581e3617a 100644 --- a/code/modules/research/xenobiology/xenobiology.dm +++ b/code/modules/research/xenobiology/xenobiology.dm @@ -1027,7 +1027,7 @@ item_state = "tile-bluespace" w_class = WEIGHT_CLASS_NORMAL force = 6 - materials = list(MAT_METAL=500) + materials = list(/datum/material/iron=500) throwforce = 10 throw_speed = 3 throw_range = 7 @@ -1044,7 +1044,7 @@ item_state = "tile-sepia" w_class = WEIGHT_CLASS_NORMAL force = 6 - materials = list(MAT_METAL=500) + materials = list(/datum/material/iron=500) throwforce = 10 throw_speed = 0.1 throw_range = 28 diff --git a/code/modules/ruins/lavaland_ruin_code.dm b/code/modules/ruins/lavaland_ruin_code.dm index 02da49c6b9c3..0f8d91af4dea 100644 --- a/code/modules/ruins/lavaland_ruin_code.dm +++ b/code/modules/ruins/lavaland_ruin_code.dm @@ -34,7 +34,7 @@ desc = "Allows for the construction of a Golem Shell." id = "golem" build_type = AUTOLATHE - materials = list(MAT_METAL = 40000) + materials = list(/datum/material/iron = 40000) build_path = /obj/item/golem_shell category = list("Imported") diff --git a/code/modules/surgery/surgery.dm b/code/modules/surgery/surgery.dm index 1de98e587934..81705bb7ec9f 100644 --- a/code/modules/surgery/surgery.dm +++ b/code/modules/surgery/surgery.dm @@ -141,14 +141,14 @@ name = "Surgery Procedure Disk" desc = "A disk that contains advanced surgery procedures, must be loaded into an Operating Console." icon_state = "datadisk1" - materials = list(MAT_METAL=300, MAT_GLASS=100) + materials = list(/datum/material/iron=300, /datum/material/glass=100) var/list/surgeries /obj/item/disk/surgery/debug name = "Debug Surgery Disk" desc = "A disk that contains all existing surgery procedures." icon_state = "datadisk1" - materials = list(MAT_METAL=300, MAT_GLASS=100) + materials = list(/datum/material/iron=300, /datum/material/glass=100) /obj/item/disk/surgery/debug/Initialize() . = ..() diff --git a/code/modules/surgery/tools.dm b/code/modules/surgery/tools.dm index 72e2eb4680e4..ee57f3bf3676 100644 --- a/code/modules/surgery/tools.dm +++ b/code/modules/surgery/tools.dm @@ -6,7 +6,7 @@ lefthand_file = 'icons/mob/inhands/equipment/medical_lefthand.dmi' righthand_file = 'icons/mob/inhands/equipment/medical_righthand.dmi' item_state = "clamps" - materials = list(MAT_METAL=6000, MAT_GLASS=3000) + materials = list(/datum/material/iron=6000, /datum/material/glass=3000) flags_1 = CONDUCT_1 item_flags = SURGICAL_TOOL w_class = WEIGHT_CLASS_TINY @@ -17,7 +17,7 @@ desc = "Micro-mechanical manipulator for retracting stuff." icon = 'icons/obj/surgery.dmi' icon_state = "retractor" - materials = list(MAT_METAL=6000, MAT_GLASS=3000) + materials = list(/datum/material/iron=6000, /datum/material/glass=3000) w_class = WEIGHT_CLASS_TINY toolspeed = 0.5 @@ -30,7 +30,7 @@ lefthand_file = 'icons/mob/inhands/equipment/medical_lefthand.dmi' righthand_file = 'icons/mob/inhands/equipment/medical_righthand.dmi' item_state = "clamps" - materials = list(MAT_METAL=5000, MAT_GLASS=2500) + materials = list(/datum/material/iron=5000, /datum/material/glass=2500) flags_1 = CONDUCT_1 item_flags = SURGICAL_TOOL w_class = WEIGHT_CLASS_TINY @@ -42,7 +42,7 @@ desc = "Tiny servos power a pair of pincers to stop bleeding." icon = 'icons/obj/surgery.dmi' icon_state = "hemostat" - materials = list(MAT_METAL=5000, MAT_GLASS=2500) + materials = list(/datum/material/iron=5000, /datum/material/glass=2500) w_class = WEIGHT_CLASS_TINY toolspeed = 0.5 attack_verb = list("attacked", "pinched") @@ -56,7 +56,7 @@ lefthand_file = 'icons/mob/inhands/equipment/medical_lefthand.dmi' righthand_file = 'icons/mob/inhands/equipment/medical_righthand.dmi' item_state = "cautery" - materials = list(MAT_METAL=2500, MAT_GLASS=750) + materials = list(/datum/material/iron=2500, /datum/material/glass=750) flags_1 = CONDUCT_1 item_flags = SURGICAL_TOOL w_class = WEIGHT_CLASS_TINY @@ -68,7 +68,7 @@ desc = "A heated element that cauterizes wounds." icon = 'icons/obj/surgery.dmi' icon_state = "cautery" - materials = list(MAT_METAL=2500, MAT_GLASS=750) + materials = list(/datum/material/iron=2500, /datum/material/glass=750) w_class = WEIGHT_CLASS_TINY toolspeed = 0.5 attack_verb = list("burnt") @@ -82,7 +82,7 @@ lefthand_file = 'icons/mob/inhands/equipment/tools_lefthand.dmi' righthand_file = 'icons/mob/inhands/equipment/tools_righthand.dmi' hitsound = 'sound/weapons/circsawhit.ogg' - materials = list(MAT_METAL=10000, MAT_GLASS=6000) + materials = list(/datum/material/iron=10000, /datum/material/glass=6000) flags_1 = CONDUCT_1 item_flags = SURGICAL_TOOL force = 15 @@ -104,7 +104,7 @@ icon = 'icons/obj/surgery.dmi' icon_state = "drill" hitsound = 'sound/weapons/circsawhit.ogg' - materials = list(MAT_METAL=10000, MAT_GLASS=6000) + materials = list(/datum/material/iron=10000, /datum/material/glass=6000) force = 10 w_class = WEIGHT_CLASS_SMALL toolspeed = 0.5 @@ -127,7 +127,7 @@ throwforce = 5 throw_speed = 3 throw_range = 5 - materials = list(MAT_METAL=4000, MAT_GLASS=1000) + materials = list(/datum/material/iron=4000, /datum/material/glass=1000) attack_verb = list("attacked", "slashed", "stabbed", "sliced", "torn", "ripped", "diced", "cut") hitsound = 'sound/weapons/bladeslice.ogg' sharpness = IS_SHARP_ACCURATE @@ -146,7 +146,7 @@ throwforce = 5 throw_speed = 3 throw_range = 5 - materials = list(MAT_METAL=4000, MAT_GLASS=1000) + materials = list(/datum/material/iron=4000, /datum/material/glass=1000) attack_verb = list("attacked", "slashed", "stabbed", "sliced", "torn", "ripped", "diced", "cut") toolspeed = 0.5 hitsound = 'sound/weapons/bladeslice.ogg' @@ -173,7 +173,7 @@ throwforce = 9 throw_speed = 2 throw_range = 5 - materials = list(MAT_METAL=10000, MAT_GLASS=6000) + materials = list(/datum/material/iron=10000, /datum/material/glass=6000) attack_verb = list("attacked", "slashed", "sawed", "cut") sharpness = IS_SHARP @@ -193,7 +193,7 @@ throwforce = 9 throw_speed = 2 throw_range = 5 - materials = list(MAT_METAL=10000, MAT_GLASS=6000) + materials = list(/datum/material/iron=10000, /datum/material/glass=6000) toolspeed = 0.5 attack_verb = list("attacked", "slashed", "sawed", "cut") sharpness = IS_SHARP diff --git a/code/modules/swarmers/swarmer_act.dm b/code/modules/swarmers/swarmer_act.dm index 97ab761061f7..3631ef84a062 100644 --- a/code/modules/swarmers/swarmer_act.dm +++ b/code/modules/swarmers/swarmer_act.dm @@ -28,7 +28,7 @@ return 0 /obj/item/integrate_amount() //returns the amount of resources gained when eating this item - if(materials[MAT_METAL] || materials[MAT_GLASS]) + if(materials[/datum/material/iron] || materials[/datum/material/glass]) return 1 return ..() @@ -57,7 +57,7 @@ /obj/structure/swarmer_beacon/swarmer_act(mob/living/simple_animal/hostile/swarmer/actor) to_chat(actor, "This machine is required for further reproduction of swarmers. Aborting.") return FALSE - + /obj/structure/flora/swarmer_act() return FALSE diff --git a/icons/mob/inhands/equipment/toolbox_lefthand.dmi b/icons/mob/inhands/equipment/toolbox_lefthand.dmi index 390942637562..4cee2d7d43a0 100644 Binary files a/icons/mob/inhands/equipment/toolbox_lefthand.dmi and b/icons/mob/inhands/equipment/toolbox_lefthand.dmi differ diff --git a/icons/mob/inhands/equipment/toolbox_righthand.dmi b/icons/mob/inhands/equipment/toolbox_righthand.dmi index 533f0a591ccd..8f1755669fc5 100644 Binary files a/icons/mob/inhands/equipment/toolbox_righthand.dmi and b/icons/mob/inhands/equipment/toolbox_righthand.dmi differ diff --git a/icons/obj/storage.dmi b/icons/obj/storage.dmi index 7ef0155a832e..48cde8096b98 100644 Binary files a/icons/obj/storage.dmi and b/icons/obj/storage.dmi differ diff --git a/tgui/packages/tgui/interfaces/ExosuitFabricator.js b/tgui/packages/tgui/interfaces/ExosuitFabricator.js index a9c42d91a811..3500ddae92ea 100644 --- a/tgui/packages/tgui/interfaces/ExosuitFabricator.js +++ b/tgui/packages/tgui/interfaces/ExosuitFabricator.js @@ -793,4 +793,4 @@ const BeingBuilt = (props, context) => { ); } -}; +}; \ No newline at end of file diff --git a/yogstation.dme b/yogstation.dme index de955b7436da..7ab195c6a188 100644 --- a/yogstation.dme +++ b/yogstation.dme @@ -41,6 +41,7 @@ #include "code\__DEFINES\DNA.dm" #include "code\__DEFINES\economy.dm" #include "code\__DEFINES\events.dm" +#include "code\__DEFINES\exosuit_fab.dm" #include "code\__DEFINES\exports.dm" #include "code\__DEFINES\extools.dm" #include "code\__DEFINES\fantasy_affixes.dm" @@ -61,6 +62,7 @@ #include "code\__DEFINES\logging.dm" #include "code\__DEFINES\machines.dm" #include "code\__DEFINES\maps.dm" +#include "code\__DEFINES\materials.dm" #include "code\__DEFINES\maths.dm" #include "code\__DEFINES\MC.dm" #include "code\__DEFINES\melee.dm" @@ -274,6 +276,7 @@ #include "code\controllers\subsystem\lighting.dm" #include "code\controllers\subsystem\machines.dm" #include "code\controllers\subsystem\mapping.dm" +#include "code\controllers\subsystem\materials.dm" #include "code\controllers\subsystem\minor_mapping.dm" #include "code\controllers\subsystem\mobs.dm" #include "code\controllers\subsystem\moods.dm" @@ -391,6 +394,7 @@ #include "code\datums\components\earprotection.dm" #include "code\datums\components\edit_complainer.dm" #include "code\datums\components\empprotection.dm" +#include "code\datums\components\explodable.dm" #include "code\datums\components\footstep.dm" #include "code\datums\components\forced_gravity.dm" #include "code\datums\components\forensics.dm" @@ -531,6 +535,8 @@ #include "code\datums\martial\psychotic_brawl.dm" #include "code\datums\martial\sleeping_carp.dm" #include "code\datums\martial\wrestling.dm" +#include "code\datums\materials\_material.dm" +#include "code\datums\materials\basemats.dm" #include "code\datums\mood_events\drink_events.dm" #include "code\datums\mood_events\drug_events.dm" #include "code\datums\mood_events\generic_negative_events.dm" @@ -1627,7 +1633,6 @@ #include "code\modules\client\preferences_savefile.dm" #include "code\modules\client\preferences_toggles.dm" #include "code\modules\client\verbs\etips.dm" -#include "code\modules\client\verbs\linkforum.dm" #include "code\modules\client\verbs\ooc.dm" #include "code\modules\client\verbs\ping.dm" #include "code\modules\client\verbs\suicide.dm" diff --git a/yogstation/code/game/objects/items/airlock_scanner.dm b/yogstation/code/game/objects/items/airlock_scanner.dm index bdcb96d2d25c..b275bab9f1e8 100644 --- a/yogstation/code/game/objects/items/airlock_scanner.dm +++ b/yogstation/code/game/objects/items/airlock_scanner.dm @@ -6,7 +6,7 @@ w_class = WEIGHT_CLASS_SMALL - materials = list(MAT_METAL=50, MAT_GLASS=50) + materials = list(/datum/material/iron=50, /datum/material/glass=50) flags_1 = CONDUCT_1 item_flags = NOBLUDGEON diff --git a/yogstation/code/game/objects/items/devices/scanners.dm b/yogstation/code/game/objects/items/devices/scanners.dm index 69155e9fb53e..2bc7922fec27 100644 --- a/yogstation/code/game/objects/items/devices/scanners.dm +++ b/yogstation/code/game/objects/items/devices/scanners.dm @@ -28,7 +28,7 @@ TRICORDER w_class = WEIGHT_CLASS_TINY throw_speed = 3 throw_range = 7 - materials = list(MAT_METAL=500,MAT_SILVER=300,MAT_GOLD=300) + materials = list(/datum/material/iron=500,/datum/material/silver=300,/datum/material/gold=300) var/medicalTricorder = FALSE //Set to TRUE for normal medical scanner, set to FALSE for a gutted version diff --git a/yogstation/code/game/objects/items/fryingpan.dm b/yogstation/code/game/objects/items/fryingpan.dm index a857453efcf5..1e5efc096a5a 100644 --- a/yogstation/code/game/objects/items/fryingpan.dm +++ b/yogstation/code/game/objects/items/fryingpan.dm @@ -12,7 +12,7 @@ var/bonkpower = 15 var/pantrify = FALSE block_chance = 10 - materials = list(MAT_METAL=75) + materials = list(/datum/material/iron=75) attack_verb = list("BONKED", "panned") hitsound = 'yogstation/sound/weapons/pan.ogg' @@ -32,7 +32,7 @@ bonkpower = 50 pantrify = TRUE block_chance = 25 - materials = list(MAT_BANANIUM=75) + materials = list(/datum/material/bananium=75) attack_verb = list("BONKED", "panned", "flexes on") armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 100, "bio" = 0, "rad" = 0, "fire" = 100, "acid" = 100) //honkzo bananium frying pan folded over 1000 times, your mime explosives are no match. diff --git a/yogstation/code/game/objects/items/tools.dm b/yogstation/code/game/objects/items/tools.dm index fbd20061cdce..940bcd5fa542 100644 --- a/yogstation/code/game/objects/items/tools.dm +++ b/yogstation/code/game/objects/items/tools.dm @@ -3,7 +3,7 @@ /obj/item/jawsoflife name = "jaws of life" desc = "A set of jaws of life, compressed through the magic of science. It's fitted with a prying head." - materials = list(MAT_METAL=150,MAT_SILVER=50,MAT_TITANIUM=25) + materials = list(/datum/material/iron=150,/datum/material/silver=50,/datum/material/titanium=25) icon = 'icons/obj/tools.dmi' icon_state = "jaws_pry" item_state = "jawsoflife" @@ -49,7 +49,7 @@ ..() else ..() - + /obj/item/jawsoflife/proc/transform_crowbar(mob/user) desc = "A set of jaws of life, compressed through the magic of science. It's fitted with a prying head." attack_verb = list("attacked", "bashed", "battered", "bludgeoned", "whacked") @@ -87,7 +87,7 @@ item_state = "drill" lefthand_file = 'icons/mob/inhands/equipment/tools_lefthand.dmi' righthand_file = 'icons/mob/inhands/equipment/tools_righthand.dmi' - materials = list(MAT_METAL=150,MAT_SILVER=50,MAT_TITANIUM=25) //done for balance reasons, making them high value for research, but harder to get + materials = list(/datum/material/iron=150,/datum/material/silver=50,/datum/material/titanium=25) //done for balance reasons, making them high value for research, but harder to get force = 8 //might or might not be too high, subject to change w_class = WEIGHT_CLASS_SMALL throwforce = 8 diff --git a/yogstation/code/game/objects/items/toys.dm b/yogstation/code/game/objects/items/toys.dm index acf2451e6529..cb9823b6fd8f 100644 --- a/yogstation/code/game/objects/items/toys.dm +++ b/yogstation/code/game/objects/items/toys.dm @@ -91,7 +91,7 @@ icon_state = "toyglock" item_state = "toyglock" slot_flags = ITEM_SLOT_BELT - materials = list(MAT_METAL=10, MAT_GLASS=10) + materials = list(/datum/material/iron=10, /datum/material/glass=10) attack_verb = list("struck", "pistol whipped", "hit", "bashed") /obj/item/toy/gun/toyflaregun @@ -101,5 +101,5 @@ icon_state = "toyflaregun" item_state = "toyflaregun" slot_flags = ITEM_SLOT_BELT - materials = list(MAT_METAL=10, MAT_GLASS=10) + materials = list(/datum/material/iron=10, /datum/material/glass=10) attack_verb = list("struck", "pistol whipped", "hit", "bashed") diff --git a/yogstation/code/modules/guardian/guardianbuilder.dm b/yogstation/code/modules/guardian/guardianbuilder.dm index 09d462ca96c3..4f8dc654cb14 100644 --- a/yogstation/code/modules/guardian/guardianbuilder.dm +++ b/yogstation/code/modules/guardian/guardianbuilder.dm @@ -24,6 +24,9 @@ src.allow_special = allow_special src.debug_mode = debug_mode +/datum/guardianbuilder/ui_state(mob/user) + return GLOB.always_state + /datum/guardianbuilder/ui_interact(mob/user, datum/tgui/ui) ui = SStgui.try_update_ui(user, src, ui) if(!ui) diff --git a/yogstation/code/modules/power/antimatter/shielding.dm b/yogstation/code/modules/power/antimatter/shielding.dm index 0bdf822d494c..1bcfb273b84a 100644 --- a/yogstation/code/modules/power/antimatter/shielding.dm +++ b/yogstation/code/modules/power/antimatter/shielding.dm @@ -238,7 +238,7 @@ throwforce = 5 throw_speed = 1 throw_range = 2 - materials = list(MAT_METAL=100) + materials = list(/datum/material/iron=100) /obj/item/am_shielding_container/multitool_act(mob/living/user, obj/item/I) if(isturf(loc)) diff --git a/yogstation/code/modules/research/designs/biogenerator_designs.dm b/yogstation/code/modules/research/designs/biogenerator_designs.dm index 8b32a8d9cdf1..28d2eb5282ee 100644 --- a/yogstation/code/modules/research/designs/biogenerator_designs.dm +++ b/yogstation/code/modules/research/designs/biogenerator_designs.dm @@ -2,7 +2,7 @@ name = "Unstable Mutagen" id = "unstable_mutagen" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 600) + materials = list(/datum/material/biomass = 600) build_path = /obj/item/reagent_containers/glass/bottle/mutagen category = list("initial","Botany Chemicals") @@ -10,6 +10,6 @@ name = "Goat Cube" id = "gcube" build_type = BIOGENERATOR - materials = list(MAT_BIOMASS = 350) + materials = list(/datum/material/biomass = 350) build_path = /obj/item/reagent_containers/food/snacks/monkeycube/goat category = list("initial", "Food") \ No newline at end of file diff --git a/yogstation/code/modules/research/designs/bluespace_designs.dm b/yogstation/code/modules/research/designs/bluespace_designs.dm index 4cad3c7dc60c..2a9ca9c478e8 100644 --- a/yogstation/code/modules/research/designs/bluespace_designs.dm +++ b/yogstation/code/modules/research/designs/bluespace_designs.dm @@ -3,7 +3,7 @@ desc = "A pipe that teleports gases." id = "bluespace_pipe" build_type = PROTOLATHE - materials = list(MAT_GOLD = 1000, MAT_DIAMOND = 750, MAT_URANIUM = 250, MAT_BLUESPACE = 2000) + materials = list(/datum/material/gold = 1000, /datum/material/diamond = 750, /datum/material/uranium = 250, /datum/material/bluespace = 2000) build_path = /obj/item/pipe/bluespace category = list("Bluespace Designs") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING diff --git a/yogstation/code/modules/research/designs/medical_designs.dm b/yogstation/code/modules/research/designs/medical_designs.dm index 76afd02420ff..5cd948549a19 100644 --- a/yogstation/code/modules/research/designs/medical_designs.dm +++ b/yogstation/code/modules/research/designs/medical_designs.dm @@ -4,7 +4,7 @@ id = "nanite_heart" build_type = PROTOLATHE | MECHFAB construction_time = 80 - materials = list(MAT_METAL = 200, MAT_GLASS = 500, MAT_SILVER=300, MAT_GOLD=300) + materials = list(/datum/material/iron = 200, /datum/material/glass = 500, /datum/material/silver=300, /datum/material/gold=300) build_path = /obj/item/organ/heart/nanite category = list("Misc", "Medical Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL | DEPARTMENTAL_FLAG_SCIENCE \ No newline at end of file diff --git a/yogstation/code/modules/research/designs/spacepod_designs.dm b/yogstation/code/modules/research/designs/spacepod_designs.dm index a0a3423d21fd..974893dbd380 100644 --- a/yogstation/code/modules/research/designs/spacepod_designs.dm +++ b/yogstation/code/modules/research/designs/spacepod_designs.dm @@ -11,7 +11,7 @@ desc = "Allows for the construction of a spacepod core system, made up of the engine and life support systems." id = "podcore" build_type = PROTOLATHE - materials = list(MAT_METAL=5000, MAT_URANIUM=1000, MAT_PLASMA=5000) + materials = list(/datum/material/iron=5000, /datum/material/uranium=1000, /datum/material/plasma=5000) build_path = /obj/item/pod_parts/core category = list("Spacepod Designs") departmental_flags = DEPARTMENTAL_FLAG_ALL @@ -21,7 +21,7 @@ desc = "Allows for the construction of spacepod armor. This is the civilian version." id = "podarmor_civ" build_type = PROTOLATHE - materials = list(MAT_METAL=15000,MAT_GLASS=5000,MAT_PLASMA=10000) + materials = list(/datum/material/iron=15000,/datum/material/glass=5000,/datum/material/plasma=10000) build_path = /obj/item/pod_parts/armor category = list("Spacepod Designs") departmental_flags = DEPARTMENTAL_FLAG_ALL @@ -33,7 +33,7 @@ build_type = PROTOLATHE build_path = /obj/item/pod_parts/armor/black category = list("Spacepod Designs") - materials = list(MAT_METAL=15000,MAT_GLASS=5000,MAT_PLASMA=10000) + materials = list(/datum/material/iron=15000,/datum/material/glass=5000,/datum/material/plasma=10000) departmental_flags = DEPARTMENTAL_FLAG_SCIENCE /datum/design/pod_armor_industrial @@ -43,7 +43,7 @@ build_type = PROTOLATHE build_path = /obj/item/pod_parts/armor/industrial category = list("Spacepod Designs") - materials = list(MAT_METAL=15000,MAT_GLASS=5000,MAT_PLASMA=10000,MAT_DIAMOND=5000,MAT_SILVER=7500) + materials = list(/datum/material/iron=15000,/datum/material/glass=5000,/datum/material/plasma=10000,/datum/material/diamond=5000,/datum/material/silver=7500) departmental_flags = DEPARTMENTAL_FLAG_CARGO | DEPARTMENTAL_FLAG_ENGINEERING /datum/design/pod_armor_sec @@ -53,7 +53,7 @@ build_type = PROTOLATHE build_path = /obj/item/pod_parts/armor/security category = list("Spacepod Designs") - materials = list(MAT_METAL=15000,MAT_GLASS=5000,MAT_PLASMA=10000,MAT_DIAMOND=5000,MAT_SILVER=7500) + materials = list(/datum/material/iron=15000,/datum/material/glass=5000,/datum/material/plasma=10000,/datum/material/diamond=5000,/datum/material/silver=7500) departmental_flags = DEPARTMENTAL_FLAG_SECURITY /datum/design/pod_armor_gold @@ -63,7 +63,7 @@ build_type = PROTOLATHE build_path = /obj/item/pod_parts/armor/gold category = list("Spacepod Designs") - materials = list(MAT_METAL=5000,MAT_GLASS=2500,MAT_PLASMA=7500,MAT_GOLD=10000) + materials = list(/datum/material/iron=5000,/datum/material/glass=2500,/datum/material/plasma=7500,/datum/material/gold=10000) departmental_flags = DEPARTMENTAL_FLAG_ALL ////////////////////////////////////////// @@ -77,7 +77,7 @@ build_type = PROTOLATHE build_path = /obj/item/spacepod_equipment/weaponry/disabler category = list("Spacepod Designs") - materials = list(MAT_METAL = 15000) + materials = list(/datum/material/iron = 15000) departmental_flags = DEPARTMENTAL_FLAG_SECURITY /datum/design/pod_gun_bdisabler @@ -87,7 +87,7 @@ build_type = PROTOLATHE build_path = /obj/item/spacepod_equipment/weaponry/burst_disabler category = list("Spacepod Designs") - materials = list(MAT_METAL = 15000,MAT_PLASMA=2000) + materials = list(/datum/material/iron = 15000,/datum/material/plasma=2000) departmental_flags = DEPARTMENTAL_FLAG_SECURITY /datum/design/pod_gun_laser @@ -97,7 +97,7 @@ build_type = PROTOLATHE build_path = /obj/item/spacepod_equipment/weaponry/laser category = list("Spacepod Designs") - materials = list(MAT_METAL=10000,MAT_GLASS=5000,MAT_GOLD=1000,MAT_SILVER=2000) + materials = list(/datum/material/iron=10000,/datum/material/glass=5000,/datum/material/gold=1000,/datum/material/silver=2000) departmental_flags = DEPARTMENTAL_FLAG_SECURITY /datum/design/pod_ka_basic @@ -105,7 +105,7 @@ desc = "Allows for the construction of a weak spacepod Kinetic Accelerator" id = "pod_ka_basic" build_type = PROTOLATHE - materials = list(MAT_METAL = 10000, MAT_GLASS = 5000, MAT_SILVER = 2000, MAT_URANIUM = 2000) + materials = list(/datum/material/iron = 10000, /datum/material/glass = 5000, /datum/material/silver = 2000, /datum/material/uranium = 2000) build_path = /obj/item/spacepod_equipment/weaponry/basic_pod_ka category = list("Spacepod Designs") departmental_flags = DEPARTMENTAL_FLAG_CARGO @@ -115,7 +115,7 @@ desc = "Allows for the construction of a spacepod Kinetic Accelerator." id = "pod_ka" build_type = PROTOLATHE - materials = list(MAT_METAL = 10000, MAT_GLASS = 5000, MAT_SILVER = 2000, MAT_GOLD = 2000, MAT_DIAMOND = 2000) + materials = list(/datum/material/iron = 10000, /datum/material/glass = 5000, /datum/material/silver = 2000, /datum/material/gold = 2000, /datum/material/diamond = 2000) build_path = /obj/item/spacepod_equipment/weaponry/pod_ka category = list("Spacepod Designs") departmental_flags = DEPARTMENTAL_FLAG_CARGO @@ -126,7 +126,7 @@ desc = "Allows for the construction of a plasma cutter." id = "pod_plasma_cutter" build_type = PROTOLATHE - materials = list(MAT_METAL = 10000, MAT_GLASS = 5000, MAT_SILVER = 2000, MAT_GOLD = 2000, MAT_DIAMOND = 2000) + materials = list(/datum/material/iron = 10000, /datum/material/glass = 5000, /datum/material/silver = 2000, /datum/material/gold = 2000, /datum/material/diamond = 2000) build_path = /obj/item/spacepod_equipment/weaponry/plasma_cutter category = list("Spacepod Designs") departmental_flags = DEPARTMENTAL_FLAG_CARGO @@ -136,7 +136,7 @@ desc = "Allows for the construction of an advanced plasma cutter." id = "pod_adv_plasma_cutter" build_type = PROTOLATHE - materials = list(MAT_METAL = 10000, MAT_GLASS = 5000, MAT_SILVER = 4000, MAT_GOLD = 4000, MAT_DIAMOND = 4000) + materials = list(/datum/material/iron = 10000, /datum/material/glass = 5000, /datum/material/silver = 4000, /datum/material/gold = 4000, /datum/material/diamond = 4000) build_path = /obj/item/spacepod_equipment/weaponry/plasma_cutter/adv category = list("Spacepod Designs") departmental_flags = DEPARTMENTAL_FLAG_CARGO @@ -150,7 +150,7 @@ desc = "Allows for the construction of a spacepod tracking module." id = "podmisc_tracker" build_type = PROTOLATHE - materials = list(MAT_METAL=5000) + materials = list(/datum/material/iron=5000) build_path = /obj/item/spacepod_equipment/tracker category = list("Spacepod Designs") departmental_flags = DEPARTMENTAL_FLAG_ALL @@ -164,7 +164,7 @@ desc = "Allows for the construction of a spacepod ore storage module." id = "podcargo_ore" build_type = PROTOLATHE - materials = list(MAT_METAL=20000, MAT_GLASS=2000) + materials = list(/datum/material/iron=20000, /datum/material/glass=2000) build_path = /obj/item/spacepod_equipment/cargo/large/ore category = list("Spacepod Designs") departmental_flags = DEPARTMENTAL_FLAG_CARGO @@ -174,7 +174,7 @@ desc = "Allows the construction of a spacepod crate storage module." id = "podcargo_crate" build_type = PROTOLATHE - materials = list(MAT_METAL=25000) + materials = list(/datum/material/iron=25000) build_path = /obj/item/spacepod_equipment/cargo/large category = list("Spacepod Designs") departmental_flags = DEPARTMENTAL_FLAG_ALL @@ -188,7 +188,7 @@ desc = "Allows the construction of a spacepod passenger seat module." id = "podcargo_seat" build_type = PROTOLATHE - materials = list(MAT_METAL=7500, MAT_GLASS=2500) + materials = list(/datum/material/iron=7500, /datum/material/glass=2500) build_path = /obj/item/spacepod_equipment/cargo/chair category = list("Spacepod Designs") departmental_flags = DEPARTMENTAL_FLAG_ALL @@ -198,7 +198,7 @@ desc = "Allows the construction of a spacepod auxillary cargo module." id = "podcargo_lootbox" build_type = PROTOLATHE - materials = list(MAT_METAL=7500, MAT_GLASS=2500) + materials = list(/datum/material/iron=7500, /datum/material/glass=2500) build_path = /obj/item/spacepod_equipment/cargo/loot_box category = list("Spacepod Designs") departmental_flags = DEPARTMENTAL_FLAG_ALL*/ @@ -211,7 +211,7 @@ desc = "Allows for the construction of a tumbler style podlock." id = "podlock_keyed" build_type = PROTOLATHE - materials = list(MAT_METAL=4500) + materials = list(/datum/material/iron=4500) build_path = /obj/item/spacepod_equipment/lock/keyed category = list("Spacepod Designs") departmental_flags = DEPARTMENTAL_FLAG_ALL @@ -221,7 +221,7 @@ desc = "Allows for the construction of a blank key for a podlock." id = "podkey" build_type = PROTOLATHE - materials = list(MAT_METAL=500) + materials = list(/datum/material/iron=500) build_path = /obj/item/spacepod_key category = list("Spacepod Designs") departmental_flags = DEPARTMENTAL_FLAG_ALL @@ -233,5 +233,5 @@ build_type = PROTOLATHE build_path = /obj/item/device/lock_buster category = list("Spacepod Designs") - materials = list(MAT_METAL = 15000, MAT_DIAMOND=2500) //it IS a drill! + materials = list(/datum/material/iron = 15000, /datum/material/diamond=2500) //it IS a drill! departmental_flags = DEPARTMENTAL_FLAG_SECURITY diff --git a/yogstation/code/modules/research/designs/tool_designs.dm b/yogstation/code/modules/research/designs/tool_designs.dm index 89cc7ff6159f..103d007e5644 100644 --- a/yogstation/code/modules/research/designs/tool_designs.dm +++ b/yogstation/code/modules/research/designs/tool_designs.dm @@ -2,7 +2,7 @@ name = "Surgical Drapes" id = "surgical_drapes" build_type = PROTOLATHE - materials = list(MAT_PLASTIC = 2500) + materials = list(/datum/material/plastic = 2500) build_path = /obj/item/surgical_drapes category = list("Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_MEDICAL | DEPARTMENTAL_FLAG_SCIENCE @@ -12,7 +12,7 @@ desc = "An advanced programmable device capable of quickly swapping to the correct tool for performing repetitive tasks quickly." id = "tool_switcher" build_type = PROTOLATHE - materials = list(MAT_METAL = 1000, MAT_GLASS = 500, MAT_DIAMOND = 1500, MAT_URANIUM = 200) + materials = list(/datum/material/iron = 1000, /datum/material/glass = 500, /datum/material/diamond = 1500, /datum/material/uranium = 200) build_path = /obj/item/storage/belt/tool_switcher category = list("Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING | DEPARTMENTAL_FLAG_MEDICAL @@ -22,7 +22,7 @@ desc = "A multifunction handheld device useful for data sensing, analysis, and recording." id = "tricorder" build_type = PROTOLATHE - materials = list(MAT_METAL=500,MAT_SILVER=300,MAT_GOLD=300) + materials = list(/datum/material/iron=500,/datum/material/silver=300,/datum/material/gold=300) build_path = /obj/item/multitool/tricorder category = list("Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_SCIENCE | DEPARTMENTAL_FLAG_ENGINEERING \ No newline at end of file diff --git a/yogstation/code/modules/surgery/tools.dm b/yogstation/code/modules/surgery/tools.dm index 791765fd21b0..0dfc1eea2580 100644 --- a/yogstation/code/modules/surgery/tools.dm +++ b/yogstation/code/modules/surgery/tools.dm @@ -1,3 +1,3 @@ // Surgical Drapes are obviously made from some type of sterile plastic, I doubt NT would ever shell-out for anything more advanced /obj/item/surgical_drapes - materials = list(MAT_PLASTIC = 2500) \ No newline at end of file + materials = list(/datum/material/plastic = 2500) \ No newline at end of file