diff --git a/baystation12.dme b/baystation12.dme index 32628ed0ae..d7a1750493 100644 --- a/baystation12.dme +++ b/baystation12.dme @@ -1615,6 +1615,7 @@ #include "code\modules\research\circuitprinter.dm" #include "code\modules\research\designs.dm" #include "code\modules\research\destructive_analyzer.dm" +#include "code\modules\research\mechfab_designs.dm" #include "code\modules\research\message_server.dm" #include "code\modules\research\protolathe.dm" #include "code\modules\research\rd-readme.dm" diff --git a/code/__defines/research.dm b/code/__defines/research.dm index 0cfc2aded6..d40722d0cf 100644 --- a/code/__defines/research.dm +++ b/code/__defines/research.dm @@ -14,5 +14,5 @@ #define IMPRINTER 0x1 //For circuits. Uses glass/chemicals. #define PROTOLATHE 0x2 //New stuff. Uses glass/metal/chemicals -#define MECHFAB 0x4 //Remember, objects utilising this flag should have construction_time and construction_cost vars. +#define MECHFAB 0x4 //Mechfab #define CHASSIS 0x8 //For protolathe, but differently diff --git a/code/game/mecha/equipment/mecha_equipment.dm b/code/game/mecha/equipment/mecha_equipment.dm index 607e8f445c..db1cb3d004 100644 --- a/code/game/mecha/equipment/mecha_equipment.dm +++ b/code/game/mecha/equipment/mecha_equipment.dm @@ -7,8 +7,6 @@ icon_state = "mecha_equip" force = 5 origin_tech = list(TECH_MATERIAL = 2) - construction_time = 100 - construction_cost = list(DEFAULT_WALL_MATERIAL=10000) var/equip_cooldown = 0 var/equip_ready = 1 var/energy_drain = 0 diff --git a/code/game/mecha/equipment/tools/medical_tools.dm b/code/game/mecha/equipment/tools/medical_tools.dm index 498a9dfff6..98a49af28a 100644 --- a/code/game/mecha/equipment/tools/medical_tools.dm +++ b/code/game/mecha/equipment/tools/medical_tools.dm @@ -6,7 +6,6 @@ origin_tech = list(TECH_DATA = 2, TECH_BIO = 3) energy_drain = 20 range = MELEE - construction_cost = list(DEFAULT_WALL_MATERIAL=5000,"glass"=10000) equip_cooldown = 20 var/mob/living/carbon/occupant = null var/datum/global_iterator/pr_mech_sleeper @@ -384,8 +383,6 @@ range = MELEE|RANGED equip_cooldown = 10 origin_tech = list(TECH_MATERIAL = 3, TECH_BIO = 4, TECH_MAGNET = 4, TECH_DATA = 3) - construction_time = 200 - construction_cost = list(DEFAULT_WALL_MATERIAL=3000,"glass"=2000) required_type = /obj/mecha/medical New() diff --git a/code/game/mecha/equipment/tools/tools.dm b/code/game/mecha/equipment/tools/tools.dm index 4b9a17483f..ca51d1e1b3 100644 --- a/code/game/mecha/equipment/tools/tools.dm +++ b/code/game/mecha/equipment/tools/tools.dm @@ -126,9 +126,8 @@ /obj/item/mecha_parts/mecha_equipment/tool/drill/diamonddrill name = "diamond drill" desc = "This is an upgraded version of the drill that'll pierce the heavens! (Can be attached to: Combat and Engineering Exosuits)" - icon_state = "mecha_diamond_drill" - origin_tech = list(TECH_MATERIAL = 4, TECH_ENGINEERING = 3) - construction_cost = list(DEFAULT_WALL_MATERIAL=10000,"diamond"=6500) + icon_state = "mecha_diamond_drill" + origin_tech = list(TECH_MATERIAL = 4, TECH_ENGINEERING = 3) equip_cooldown = 20 force = 15 @@ -255,8 +254,6 @@ equip_cooldown = 10 energy_drain = 250 range = MELEE|RANGED - construction_time = 1200 - construction_cost = list(DEFAULT_WALL_MATERIAL=30000,"phoron"=25000,"silver"=20000,"gold"=20000) var/mode = 0 //0 - deconstruct, 1 - wall or floor, 2 - airlock. var/disabled = 0 //malf @@ -506,7 +503,6 @@ equip_cooldown = 10 energy_drain = 50 range = 0 - construction_cost = list(DEFAULT_WALL_MATERIAL=20000,"silver"=5000) var/deflect_coeff = 1.15 var/damage_coeff = 0.8 @@ -556,7 +552,6 @@ equip_cooldown = 10 energy_drain = 50 range = 0 - construction_cost = list(DEFAULT_WALL_MATERIAL=20000,"gold"=5000) var/deflect_coeff = 1.15 var/damage_coeff = 0.8 @@ -627,7 +622,6 @@ equip_cooldown = 20 energy_drain = 100 range = 0 - construction_cost = list(DEFAULT_WALL_MATERIAL=10000,"gold"=1000,"silver"=2000,"glass"=5000) var/health_boost = 2 var/datum/global_iterator/pr_repair_droid var/icon/droid_overlay @@ -722,7 +716,6 @@ equip_cooldown = 10 energy_drain = 0 range = 0 - construction_cost = list(DEFAULT_WALL_MATERIAL=10000,"gold"=2000,"silver"=3000,"glass"=2000) var/datum/global_iterator/pr_energy_relay var/coeff = 100 var/list/use_channels = list(EQUIP,ENVIRON,LIGHT) @@ -839,7 +832,6 @@ equip_cooldown = 10 energy_drain = 0 range = MELEE - construction_cost = list(DEFAULT_WALL_MATERIAL=10000,"silver"=500,"glass"=1000) var/datum/global_iterator/pr_mech_generator var/coeff = 100 var/obj/item/stack/material/fuel @@ -972,9 +964,8 @@ /obj/item/mecha_parts/mecha_equipment/generator/nuclear name = "\improper ExoNuclear reactor" desc = "Generates power using uranium. Pollutes the environment." - icon_state = "tesla" - origin_tech = list(TECH_POWER = 3, TECH_ENGINEERING = 3) - construction_cost = list(DEFAULT_WALL_MATERIAL=10000,"silver"=500,"glass"=1000) + icon_state = "tesla" + origin_tech = list(TECH_POWER = 3, TECH_ENGINEERING = 3) max_fuel = 50000 fuel_per_cycle_idle = 10 fuel_per_cycle_active = 30 @@ -1072,7 +1063,6 @@ origin_tech = list(TECH_ENGINEERING = 1, TECH_BIO = 1) energy_drain = 10 range = MELEE - construction_cost = list(DEFAULT_WALL_MATERIAL=5000,"glass"=5000) equip_cooldown = 20 var/mob/living/carbon/occupant = null var/door_locked = 1 diff --git a/code/game/mecha/equipment/weapons/weapons.dm b/code/game/mecha/equipment/weapons/weapons.dm index f034f27550..913f9acb72 100644 --- a/code/game/mecha/equipment/weapons/weapons.dm +++ b/code/game/mecha/equipment/weapons/weapons.dm @@ -274,7 +274,6 @@ /obj/item/mecha_parts/mecha_equipment/weapon/ballistic/missile_rack/flashbang/clusterbang//Because I am a heartless bastard -Sieve name = "\improper SOP-6 grenade launcher" projectile = /obj/item/weapon/grenade/flashbang/clusterbang - construction_cost = list(DEFAULT_WALL_MATERIAL=20000,"gold"=6000,"uranium"=6000) /obj/item/mecha_parts/mecha_equipment/weapon/ballistic/missile_rack/flashbang/clusterbang/limited/get_equip_info()//Limited version of the clusterbang launcher that can't reload return "* [chassis.selected==src?"":""][src.name][chassis.selected==src?"":""]\[[src.projectiles]\]" diff --git a/code/game/mecha/mech_fabricator.dm b/code/game/mecha/mech_fabricator.dm index 3fb9ed8bf4..7fc5f17e86 100644 --- a/code/game/mecha/mech_fabricator.dm +++ b/code/game/mecha/mech_fabricator.dm @@ -1,126 +1,29 @@ -///////////////////////////// -///// Part Fabricator /////// -///////////////////////////// - /obj/machinery/mecha_part_fabricator icon = 'icons/obj/robotics.dmi' icon_state = "fab-idle" name = "Exosuit Fabricator" - desc = "Nothing is being built." + desc = "A machine used for construction of robotcs and mechas." density = 1 anchored = 1 use_power = 1 idle_power_usage = 20 active_power_usage = 5000 req_access = list(access_robotics) - var/current_manufacturer - var/time_coeff = 1.5 //can be upgraded with research - var/resource_coeff = 1.5 //can be upgraded with research - var/list/resources = list( - DEFAULT_WALL_MATERIAL=0, - "glass"=0, - "gold"=0, - "silver"=0, - "diamond"=0, - "phoron"=0, - "uranium"=0, - ) + + var/speed = 1 + var/mat_efficiency = 1 + var/list/materials = list(DEFAULT_WALL_MATERIAL = 0, "glass" = 0, "gold" = 0, "silver" = 0, "diamond" = 0, "phoron" = 0, "uranium" = 0) var/res_max_amount = 200000 + var/datum/research/files - var/id - var/sync = 0 - var/part_set - var/obj/being_built - var/list/queue = list() - var/processing_queue = 0 - var/screen = "main" - var/opened = 0 - var/temp - var/output_dir = SOUTH //the direction relative to the fabber at which completed parts appear. - var/list/part_sets = list( //set names must be unique - "Robot"=list( - /obj/item/robot_parts/robot_suit, - /obj/item/robot_parts/chest, - /obj/item/robot_parts/head, - /obj/item/robot_parts/l_arm, - /obj/item/robot_parts/r_arm, - /obj/item/robot_parts/l_leg, - /obj/item/robot_parts/r_leg, - /obj/item/robot_parts/robot_component/binary_communication_device, - /obj/item/robot_parts/robot_component/radio, - /obj/item/robot_parts/robot_component/actuator, - /obj/item/robot_parts/robot_component/diagnosis_unit, - /obj/item/robot_parts/robot_component/camera, - /obj/item/robot_parts/robot_component/armour - ), - "Ripley"=list( - /obj/item/mecha_parts/chassis/ripley, - /obj/item/mecha_parts/part/ripley_torso, - /obj/item/mecha_parts/part/ripley_left_arm, - /obj/item/mecha_parts/part/ripley_right_arm, - /obj/item/mecha_parts/part/ripley_left_leg, - /obj/item/mecha_parts/part/ripley_right_leg - ), -// "Hoverpod"=list( -// /obj/structure/largecrate/hoverpod // Doesn't work, even with required vars. Why? - Gamerofthegame -// ), - "Odysseus"=list( - /obj/item/mecha_parts/chassis/odysseus, - /obj/item/mecha_parts/part/odysseus_torso, - /obj/item/mecha_parts/part/odysseus_head, - /obj/item/mecha_parts/part/odysseus_left_arm, - /obj/item/mecha_parts/part/odysseus_right_arm, - /obj/item/mecha_parts/part/odysseus_left_leg, - /obj/item/mecha_parts/part/odysseus_right_leg - ), + var/list/datum/design/queue = list() + var/progress = 0 + var/busy = 0 - "Gygax"=list( - /obj/item/mecha_parts/chassis/gygax, - /obj/item/mecha_parts/part/gygax_torso, - /obj/item/mecha_parts/part/gygax_head, - /obj/item/mecha_parts/part/gygax_left_arm, - /obj/item/mecha_parts/part/gygax_right_arm, - /obj/item/mecha_parts/part/gygax_left_leg, - /obj/item/mecha_parts/part/gygax_right_leg, - /obj/item/mecha_parts/part/gygax_armour - ), - "Durand"=list( - /obj/item/mecha_parts/chassis/durand, - /obj/item/mecha_parts/part/durand_torso, - /obj/item/mecha_parts/part/durand_head, - /obj/item/mecha_parts/part/durand_left_arm, - /obj/item/mecha_parts/part/durand_right_arm, - /obj/item/mecha_parts/part/durand_left_leg, - /obj/item/mecha_parts/part/durand_right_leg, - /obj/item/mecha_parts/part/durand_armour - ), - "Exosuit Equipment"=list( - /obj/item/mecha_parts/mecha_equipment/tool/hydraulic_clamp, - /obj/item/mecha_parts/mecha_equipment/tool/drill, - /obj/item/mecha_parts/mecha_equipment/tool/extinguisher, - /obj/item/mecha_parts/mecha_equipment/tool/cable_layer, - /obj/item/mecha_parts/mecha_equipment/tool/sleeper, - /obj/item/mecha_parts/mecha_equipment/tool/syringe_gun, - /obj/item/mecha_parts/mecha_equipment/tool/passenger, - /obj/item/mecha_parts/chassis/firefighter, - ///obj/item/mecha_parts/mecha_equipment/repair_droid, - /obj/item/mecha_parts/mecha_equipment/generator, - ///obj/item/mecha_parts/mecha_equipment/jetpack, //TODO MECHA JETPACK SPRITE MISSING - /obj/item/mecha_parts/mecha_equipment/weapon/energy/taser, - /obj/item/mecha_parts/mecha_equipment/weapon/ballistic/lmg - ), - - "Robotic Upgrade Modules" = list( - /obj/item/borg/upgrade/reset, - /obj/item/borg/upgrade/rename, - /obj/item/borg/upgrade/restart, - /obj/item/borg/upgrade/vtec, - /obj/item/borg/upgrade/tasercooler, - /obj/item/borg/upgrade/jetpack - ), - - "Misc"=list(/obj/item/mecha_parts/mecha_tracking) - ) + var/list/categories = list() + var/category = null + var/manufacturer = null + var/sync_message = "" /obj/machinery/mecha_part_fabricator/New() ..() @@ -134,643 +37,129 @@ component_parts += new /obj/item/weapon/stock_parts/console_screen(src) RefreshParts() - // part_sets["Cyborg Upgrade Modules"] = typesof(/obj/item/borg/upgrade/) - /obj/item/borg/upgrade/ // Eh. This does it dymaically, but to support having the items referenced otherwhere in the code but not being constructable, going to do it manaully. - - for(var/part_set in part_sets) - convert_part_set(part_set) files = new /datum/research(src) //Setup the research data holder. - /* - if(!id) - for(var/obj/machinery/r_n_d/server/centcom/S in world) - S.initialize() - break - */ return /obj/machinery/mecha_part_fabricator/initialize() - current_manufacturer = basic_robolimb.company + manufacturer = basic_robolimb.company + update_categories() + +/obj/machinery/mecha_part_fabricator/process() + ..() + if(stat) + return + if(busy) + use_power = 2 + progress += speed + check_build() + else + use_power = 1 + update_icon() + +/obj/machinery/mecha_part_fabricator/update_icon() + overlays.Cut() + if(panel_open) + icon_state = "fab-o" + else + icon_state = "fab-idle" + if(busy) + overlays += "fab-active" + +/obj/machinery/mecha_part_fabricator/dismantle() + for(var/f in materials) + eject_materials(f, -1) + ..() /obj/machinery/mecha_part_fabricator/RefreshParts() - var/T = 0 + res_max_amount = 0 for(var/obj/item/weapon/stock_parts/matter_bin/M in component_parts) + res_max_amount += M.rating * 100000 // 200k -> 600k + var/T = 0 + for(var/obj/item/weapon/stock_parts/manipulator/M in component_parts) T += M.rating - res_max_amount = (187500+(T * 37500)) - T = 0 - for(var/obj/item/weapon/stock_parts/micro_laser/Ma in component_parts) - T += Ma.rating - if(T >= 1) - T -= 1 - var/diff - diff = round(initial(resource_coeff) - (initial(resource_coeff)*(T))/25,0.01) - if(resource_coeff!=diff) - resource_coeff = diff - T = 0 - for(var/obj/item/weapon/stock_parts/manipulator/Ml in component_parts) - T += Ml.rating - if(T>= 1) - T -= 1 - diff = round(initial(time_coeff) - (initial(time_coeff)*(T))/25,0.01) - if(time_coeff!=diff) - time_coeff = diff + mat_efficiency = 1 - (T - 1) / 4 // 1 -> 0.5 + for(var/obj/item/weapon/stock_parts/micro_laser/M in component_parts) // Not resetting T is intended; speed is affected by both + T += M.rating + speed = T / 2 // 1 -> 3 -/obj/machinery/mecha_part_fabricator/Destroy() - for(var/atom/A in src) - qdel(A) - ..() - return - -/obj/machinery/mecha_part_fabricator/proc/operation_allowed(mob/M) - if(isrobot(M) || isAI(M)) - return 1 - if(!istype(req_access) || !req_access.len) - return 1 - else if(istype(M, /mob/living/carbon/human)) - var/mob/living/carbon/human/H = M - for(var/ID in list(H.get_active_hand(), H.wear_id, H.belt)) - if(src.check_access(ID)) - return 1 - M << "You don't have required permissions to use [src]" - return 0 - -/obj/machinery/mecha_part_fabricator/proc/convert_part_set(set_name as text) - var/list/parts = part_sets[set_name] - if(istype(parts, /list)) - for(var/i=1;i<=parts.len;i++) - var/path = parts[i] - var/part = new path(src) - if(part) - parts[i] = part - //debug below - if(!istype(parts[i],/obj/item)) return 0 - return - - -/obj/machinery/mecha_part_fabricator/proc/add_part_set(set_name as text,parts=null) - if(set_name in part_sets)//attempt to create duplicate set - return 0 - if(isnull(parts)) - part_sets[set_name] = list() - else - part_sets[set_name] = parts - convert_part_set(set_name) - return 1 - -/obj/machinery/mecha_part_fabricator/proc/add_part_to_set(set_name as text,part) - if(!part) return 0 - src.add_part_set(set_name)//if no "set_name" set exists, create - var/list/part_set = part_sets[set_name] - var/atom/apart - if(ispath(part)) - apart = new part(src) - else - apart = part - if(!istype(apart)) return 0 - for(var/obj/O in part_set) - if(O.type == apart.type) - qdel(apart) - return 0 - part_set[++part_set.len] = apart - return 1 - -/obj/machinery/mecha_part_fabricator/proc/remove_part_set(set_name as text) - for(var/i=1,i<=part_sets.len,i++) - if(part_sets[i]==set_name) - part_sets.Cut(i,++i) - return -/* - proc/sanity_check() - for(var/p in resources) - var/index = resources.Find(p) - index = resources.Find(p, ++index) - if(index) //duplicate resource - world << "Duplicate resource definition for [src](\ref[src])" - return 0 - for(var/set_name in part_sets) - var/index = part_sets.Find(set_name) - index = part_sets.Find(set_name, ++index) - if(index) //duplicate part set - world << "Duplicate part set definition for [src](\ref[src])" - return 0 - return 1 -*/ - -/obj/machinery/mecha_part_fabricator/proc/output_parts_list(set_name) - var/output = "" - var/list/part_set = listgetindex(part_sets, set_name) - if(istype(part_set)) - for(var/obj/item/part in part_set) - var/resources_available = check_resources(part) - output += "
[output_part_info(part)]
\[[resources_available?"Build | ":null]Add to queue\]\[?\]
" - return output - -/obj/machinery/mecha_part_fabricator/proc/output_part_info(var/obj/item/part) - var/output = "[part.name] (Cost: [output_part_cost(part)]) [get_construction_time_w_coeff(part)/10]sec" - return output - -/obj/machinery/mecha_part_fabricator/proc/output_part_cost(var/obj/item/part) - var/i = 0 - var/output - if(part.vars.Find("construction_time") && part.vars.Find("construction_cost"))//The most efficient way to go about this. Not all objects have these vars, but if they don't then they CANNOT be made by the mech fab. Doing it this way reduces a major amount of typecasting and switches, while cutting down maintenece for them as well -Sieve - for(var/c in part:construction_cost)//The check should ensure that anything without the var doesn't make it to this point - if(c in resources) - output += "[i?" | ":null][get_resource_cost_w_coeff(part,c)] [c]" - i++ - return output - else - return 0 - -/obj/machinery/mecha_part_fabricator/proc/output_available_resources() - var/output - for(var/resource in resources) - var/amount = min(res_max_amount, resources[resource]) - output += "[resource]: [amount] cm³" - if(amount>0) - output += " - Remove \[1\] | \[10\] | \[All\]" - output += "
" - return output - -/obj/machinery/mecha_part_fabricator/proc/remove_resources(var/obj/item/part) -//Be SURE to add any new equipment to this switch, but don't be suprised if it spits out children objects - if(part.vars.Find("construction_time") && part.vars.Find("construction_cost")) - for(var/resource in part:construction_cost) - if(resource in src.resources) - src.resources[resource] -= get_resource_cost_w_coeff(part,resource) - else +/obj/machinery/mecha_part_fabricator/attack_hand(var/mob/user) + if(..()) return - -/obj/machinery/mecha_part_fabricator/proc/check_resources(var/obj/item/part) -// if(istype(part, /obj/item/robot_parts) || istype(part, /obj/item/mecha_parts) || istype(part,/obj/item/borg/upgrade)) -//Be SURE to add any new equipment to this switch, but don't be suprised if it spits out children objects - if(part.vars.Find("construction_time") && part.vars.Find("construction_cost")) - for(var/resource in part:construction_cost) - if(resource in src.resources) - if(src.resources[resource] < get_resource_cost_w_coeff(part,resource)) - return 0 - return 1 - else - return 0 - -/obj/machinery/mecha_part_fabricator/proc/build_part(var/obj/item/part) - if(!part) return - - // critical exploit prevention, do not remove unless you replace it -walter0o - if( !(locate(part, src.contents)) || !(part.vars.Find("construction_time")) || !(part.vars.Find("construction_cost")) ) // these 3 are the current requirements for an object being buildable by the mech_fabricator + if(!allowed(user)) return + ui_interact(user) - if(current_manufacturer) - src.being_built = new part.type(src, current_manufacturer) - else - src.being_built = new part.type(src, basic_robolimb.company) +/obj/machinery/mecha_part_fabricator/ui_interact(var/mob/user, var/ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1) + var/data[0] - src.desc = "It's building [src.being_built]." - src.remove_resources(part) - src.overlays += "fab-active" - src.use_power = 2 - src.updateUsrDialog() - sleep(get_construction_time_w_coeff(part)) - src.use_power = 1 - src.overlays -= "fab-active" - src.desc = initial(src.desc) - if(being_built) - src.being_built.Move(get_step(src,output_dir)) - src.visible_message("\icon[src] [src] beeps, \"The following has been completed: [src.being_built] is built\".") - src.being_built = null - src.updateUsrDialog() - return 1 + var/datum/design/current = queue.len ? queue[1] : null + if(current) + data["current"] = current.name + data["queue"] = get_queue_names() + data["buildable"] = get_build_options() + data["category"] = category + data["categories"] = categories + if(all_robolimbs) + var/list/T = list() + for(var/A in all_robolimbs) + var/datum/robolimb/R = all_robolimbs[A] + T += list(list("id" = A, "company" = R.company)) + data["manufacturers"] = T + data["manufacturer"] = manufacturer + data["materials"] = get_materials() + data["maxres"] = res_max_amount + data["sync"] = sync_message + if(current) + data["builtperc"] = round((progress / current.time) * 100) -/obj/machinery/mecha_part_fabricator/proc/update_queue_on_page() - send_byjax(usr,"mecha_fabricator.browser","queue",src.list_queue()) - return - -/obj/machinery/mecha_part_fabricator/proc/add_part_set_to_queue(set_name) - if(set_name in part_sets) - var/list/part_set = part_sets[set_name] - if(islist(part_set)) - for(var/obj/item/part in part_set) - add_to_queue(part) - return - -/obj/machinery/mecha_part_fabricator/proc/add_to_queue(part) - if(!istype(queue)) - queue = list() - if(part) - queue[++queue.len] = part - return queue.len - -/obj/machinery/mecha_part_fabricator/proc/remove_from_queue(index) - if(!isnum(index) || !istype(queue) || (index<1 || index>queue.len)) - return 0 - queue.Cut(index,++index) - return 1 - -/obj/machinery/mecha_part_fabricator/proc/process_queue() - var/obj/item/part = listgetindex(src.queue, 1) - if(!part) - remove_from_queue(1) - if(src.queue.len) - return process_queue() - else - return - if(!(part.vars.Find("construction_time")) || !(part.vars.Find("construction_cost")))//If it shouldn't be printed - remove_from_queue(1)//Take it out of the quene - return process_queue()//Then reprocess it - temp = null - while(part) - if(stat&(NOPOWER|BROKEN)) - return 0 - if(!check_resources(part)) - src.visible_message("\icon[src] [src] beeps, \"Not enough resources. Queue processing stopped\".") - temp = {"Not enough resources to build next part.
- Try again | Return"} - return 0 - remove_from_queue(1) - build_part(part) - part = listgetindex(src.queue, 1) - src.visible_message("\icon[src] [src] beeps, \"Queue processing finished successfully\".") - return 1 - -/obj/machinery/mecha_part_fabricator/proc/list_queue() - var/output = "Queue contains:" - if(!istype(queue) || !queue.len) - output += "
Nothing" - else - output += "
    " - for(var/i=1;i<=queue.len;i++) - var/obj/item/part = listgetindex(src.queue, i) - if(istype(part)) - if(part.vars.Find("construction_time") && part.vars.Find("construction_cost")) - output += "[part.name] - [i>1?"":null] [i↓":null] Remove" - else//Prevents junk items from even appearing in the list, and they will be silently removed when the fab processes - remove_from_queue(i)//Trash it - return list_queue()//Rebuild it - output += "
" - output += "\[Process queue | Clear queue\]" - return output - -/obj/machinery/mecha_part_fabricator/proc/convert_designs() - if(!files) return - var/i = 0 - for(var/datum/design/D in files.known_designs) - if(D.build_type&16) - if(D.category in part_sets)//Checks if it's a valid category - if(add_part_to_set(D.category, D.build_path))//Adds it to said category - i++ - else - if(add_part_to_set("Misc", D.build_path))//If in doubt, chunk it into the Misc - i++ - return i - -/obj/machinery/mecha_part_fabricator/proc/update_tech() - if(!files) return - var/output - for(var/datum/tech/T in files.known_tech) - if(T && T.level > 1) - var/diff - switch(T.id) //bad, bad formulas - if("materials") - var/pmat = 0//Calculations to make up for the fact that these parts and tech modify the same thing - for(var/obj/item/weapon/stock_parts/micro_laser/Ml in component_parts) - pmat += Ml.rating - if(pmat >= 1) - pmat -= 1//So the equations don't have to be reworked, upgrading a single part from T1 to T2 is == to 1 tech level - diff = round(initial(resource_coeff) - (initial(resource_coeff)*(T.level+pmat))/25,0.01) - if(resource_coeff!=diff) - resource_coeff = diff - output+="Production efficiency increased.
" - if("programming") - var/ptime = 0 - for(var/obj/item/weapon/stock_parts/manipulator/Ma in component_parts) - ptime += Ma.rating - if(ptime >= 2) - ptime -= 2 - diff = round(initial(time_coeff) - (initial(time_coeff)*(T.level+ptime))/25,0.1) - if(time_coeff!=diff) - time_coeff = diff - output+="Production routines updated.
" - return output - - -/obj/machinery/mecha_part_fabricator/proc/sync(silent=null) -/* if(queue.len) - if(!silent) - temp = "Error. Please clear processing queue before updating!" - src.updateUsrDialog() - return -*/ - if(!silent) - temp = "Updating local R&D database..." - src.updateUsrDialog() - sleep(30) //only sleep if called by user - var/found = 0 - for(var/obj/machinery/computer/rdconsole/RDC in get_area_all_atoms(get_area(src))) - if(!RDC.sync) - continue - found++ - for(var/datum/tech/T in RDC.files.known_tech) - files.AddTech2Known(T) - for(var/datum/design/D in RDC.files.known_designs) - files.AddDesign2Known(D) - files.RefreshResearch() - var/i = src.convert_designs() - var/tech_output = update_tech() - if(!silent) - temp = "Processed [i] equipment designs.
" - temp += tech_output - temp += "Return" - src.updateUsrDialog() - if(i || tech_output) - src.visible_message("\icon[src] [src] beeps, \"Successfully synchronized with R&D server. New data processed.\"") - if(found == 0) - temp = "Couldn't contact R&D server.
" - temp += "Return" - src.updateUsrDialog() - src.visible_message("\icon[src] [src] beeps, \"Error! Couldn't connect to R&D server.\"") - return - -/obj/machinery/mecha_part_fabricator/proc/get_resource_cost_w_coeff(var/obj/item/part as obj,var/resource as text, var/roundto=1) -//Be SURE to add any new equipment to this switch, but don't be suprised if it spits out children objects - if(part.vars.Find("construction_time") && part.vars.Find("construction_cost")) - return round(part:construction_cost[resource]*resource_coeff, roundto) - else - return 0 - -/obj/machinery/mecha_part_fabricator/proc/get_construction_time_w_coeff(var/obj/item/part as obj, var/roundto=1) -//Be SURE to add any new equipment to this switch, but don't be suprised if it spits out children objects - if(part.vars.Find("construction_time") && part.vars.Find("construction_cost")) - return round(part:construction_time*time_coeff, roundto) - else - return 0 - - -/obj/machinery/mecha_part_fabricator/attack_hand(mob/user as mob) - var/dat, left_part - if (..()) - return - if(!operation_allowed(user)) - return - user.set_machine(src) - var/turf/exit = get_step(src,SOUTH) - if(exit.density) - src.visible_message("\icon[src] [src] beeps, \"Error! Part outlet is obstructed\".") - return - if(temp) - left_part = temp - else if(src.being_built) - left_part = {"Building [src.being_built.name].
- Please wait until completion...
"} - else - switch(screen) - if("main") - left_part = output_available_resources()+"
" - left_part += "Sync with R&D servers | Set manufacturer ([current_manufacturer])
" - 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 = {" - - [src.name] - - - - - - - - - -
- [left_part] - - [list_queue()] -
- - "} - user << browse(dat, "window=mecha_fabricator;size=1000x400") - onclose(user, "mecha_fabricator") - return - -/obj/machinery/mecha_part_fabricator/proc/exploit_prevention(var/obj/Part, mob/user as mob, var/desc_exploit) -// critical exploit prevention, feel free to improve or replace this, but do not remove it -walter0o - - if(!Part || !user || !istype(Part) || !istype(user)) // sanity - return 1 - - if( !(locate(Part, src.contents)) || !(Part.vars.Find("construction_time")) || !(Part.vars.Find("construction_cost")) ) // these 3 are the current requirements for an object being buildable by the mech_fabricator - - var/turf/LOC = get_turf(user) - message_admins("[key_name_admin(user)] tried to exploit an Exosuit Fabricator to [desc_exploit ? "get the desc of" : "duplicate"] [Part] ! ([LOC ? "JMP" : "null"])", 0) - log_admin("EXPLOIT : [key_name(user)] tried to exploit an Exosuit Fabricator to [desc_exploit ? "get the desc of" : "duplicate"] [Part] !") - return 1 - - return null + ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open) + if(!ui) + ui = new(user, src, ui_key, "mechfab.tmpl", "Exosuit Fabricator UI", 800, 600) + ui.set_initial_data(data) + ui.open() + ui.set_auto_update(1) /obj/machinery/mecha_part_fabricator/Topic(href, href_list) - - if(..()) // critical exploit prevention, do not remove unless you replace it -walter0o + if(..()) return - var/datum/topic_input/filter = new /datum/topic_input(href,href_list) - if(href_list["set_manufacturer"]) - var/choice = input(usr, "Which manufacturer do you wish to use for this fabricator?") as null|anything in all_robolimbs - if(choice) current_manufacturer = choice - if(href_list["part_set"]) - var/tpart_set = filter.getStr("part_set") - if(tpart_set) - if(tpart_set=="clear") - src.part_set = null - else - src.part_set = tpart_set - screen = "parts" - if(href_list["part"]) - var/obj/part = filter.getObj("part") + if(href_list["build"]) + add_to_queue(text2num(href_list["build"])) - // critical exploit prevention, do not remove unless you replace it -walter0o - if(src.exploit_prevention(part, usr)) - return + if(href_list["remove"]) + remove_from_queue(text2num(href_list["remove"])) - if(!processing_queue) - build_part(part) - else - add_to_queue(part) - if(href_list["add_to_queue"]) - var/obj/part = filter.getObj("add_to_queue") + if(href_list["category"]) + if(href_list["category"] in categories) + category = href_list["category"] - // critical exploit prevention, do not remove unless you replace it -walter0o - if(src.exploit_prevention(part, usr)) - return + if(href_list["manufacturer"]) + if(href_list["manufacturer"] in all_robolimbs) + manufacturer = href_list["manufacturer"] - add_to_queue(part) + if(href_list["eject"]) + eject_materials(href_list["eject"], text2num(href_list["amount"])) - return update_queue_on_page() - if(href_list["remove_from_queue"]) - remove_from_queue(filter.getNum("remove_from_queue")) - return update_queue_on_page() - if(href_list["partset_to_queue"]) - add_part_set_to_queue(filter.get("partset_to_queue")) - return update_queue_on_page() - if(href_list["process_queue"]) - spawn(-1) - if(processing_queue || being_built) - return 0 - processing_queue = 1 - process_queue() - processing_queue = 0 -/* - if(href_list["list_queue"]) - list_queue() -*/ - if(href_list["clear_temp"]) - temp = null - if(href_list["screen"]) - src.screen = href_list["screen"] - if(href_list["queue_move"] && href_list["index"]) - var/index = filter.getNum("index") - var/new_index = index + filter.getNum("queue_move") - if(isnum(index) && isnum(new_index)) - if(InRange(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"]) - queue = list() - src.sync() - return update_queue_on_page() - if(href_list["part_desc"]) - var/obj/part = filter.getObj("part_desc") - - // critical exploit prevention, do not remove unless you replace it -walter0o - if(src.exploit_prevention(part, usr, 1)) - return - - if(part) - temp = {"

[part] description:

- [part.desc]
- Return - "} - if(href_list["remove_mat"] && href_list["material"]) - temp = "Ejected [remove_material(href_list["material"],text2num(href_list["remove_mat"]))] of [href_list["material"]]
Return" - src.updateUsrDialog() - return - -/obj/machinery/mecha_part_fabricator/proc/remove_material(var/mat_string, var/amount) - var/type - switch(mat_string) - if(DEFAULT_WALL_MATERIAL) - type = /obj/item/stack/material/steel - if("glass") - type = /obj/item/stack/material/glass - if("gold") - type = /obj/item/stack/material/gold - if("silver") - type = /obj/item/stack/material/silver - if("diamond") - type = /obj/item/stack/material/diamond - if("phoron") - type = /obj/item/stack/material/phoron - if("uranium") - type = /obj/item/stack/material/uranium - else - return 0 - var/result = 0 - var/obj/item/stack/material/res = new type(src) - - // amount available to take out - var/total_amount = round(resources[mat_string]/res.perunit) - - // number of stacks we're going to take out - res.amount = round(min(total_amount,amount)) - - if(res.amount>0) - resources[mat_string] -= res.amount*res.perunit - res.Move(src.loc) - result = res.amount + sync() else - qdel(res) - return result + sync_message = "" + + return 1 -/obj/machinery/mecha_part_fabricator/emag_act(var/remaining_charges, var/mob/user) - sleep() - switch(emagged) - if(0) - emagged = 0.5 - src.visible_message("\icon[src] [src] beeps: \"DB error \[Code 0x00F1\]\"") - sleep(10) - src.visible_message("\icon[src] [src] beeps: \"Attempting auto-repair\"") - sleep(15) - src.visible_message("\icon[src] [src] beeps: \"User DB corrupted \[Code 0x00FA\]. Truncating data structure...\"") - sleep(30) - src.visible_message("\icon[src] [src] beeps: \"User DB truncated. Please contact your [company_name] system operator for future assistance.\"") - req_access = null - emagged = 1 - return 1 - if(0.5) - src.visible_message("\icon[src] [src] beeps: \"DB not responding \[Code 0x0003\]...\"") - if(1) - src.visible_message("\icon[src] [src] beeps: \"No records in User DB\"") - -/obj/machinery/mecha_part_fabricator/attackby(obj/W as obj, mob/user as mob) - if(istype(W,/obj/item/weapon/screwdriver)) - if (!opened) - opened = 1 - icon_state = "fab-o" - user << "You open the maintenance hatch of [src]." - else - opened = 0 - icon_state = "fab-idle" - user << "You close the maintenance hatch of [src]." +/obj/machinery/mecha_part_fabricator/attackby(var/obj/item/I, var/mob/user) + if(busy) + user << "\The [src] is busy. Please wait for completion of previous operation." + return 1 + if(default_deconstruction_screwdriver(user, I)) + return + if(default_deconstruction_crowbar(user, I)) + return + if(default_part_replacement(user, I)) return - if (opened) - if(istype(W, /obj/item/weapon/crowbar)) - playsound(src.loc, 'sound/items/Crowbar.ogg', 50, 1) - var/obj/machinery/constructable_frame/machine_frame/M = new /obj/machinery/constructable_frame/machine_frame(src.loc) - M.state = 2 - M.icon_state = "box_1" - for(var/obj/I in component_parts) - I.loc = src.loc - if(src.resources[DEFAULT_WALL_MATERIAL] >= 3750) - var/obj/item/stack/material/steel/G = new /obj/item/stack/material/steel(src.loc) - G.amount = round(src.resources[DEFAULT_WALL_MATERIAL] / G.perunit) - if(src.resources["glass"] >= 3750) - var/obj/item/stack/material/glass/G = new /obj/item/stack/material/glass(src.loc) - G.amount = round(src.resources["glass"] / G.perunit) - if(src.resources["phoron"] >= 2000) - var/obj/item/stack/material/phoron/G = new /obj/item/stack/material/phoron(src.loc) - G.amount = round(src.resources["phoron"] / G.perunit) - if(src.resources["silver"] >= 2000) - var/obj/item/stack/material/silver/G = new /obj/item/stack/material/silver(src.loc) - G.amount = round(src.resources["silver"] / G.perunit) - if(src.resources["gold"] >= 2000) - var/obj/item/stack/material/gold/G = new /obj/item/stack/material/gold(src.loc) - G.amount = round(src.resources["gold"] / G.perunit) - if(src.resources["uranium"] >= 2000) - var/obj/item/stack/material/uranium/G = new /obj/item/stack/material/uranium(src.loc) - G.amount = round(src.resources["uranium"] / G.perunit) - if(src.resources["diamond"] >= 2000) - var/obj/item/stack/material/diamond/G = new /obj/item/stack/material/diamond(src.loc) - G.amount = round(src.resources["diamond"] / G.perunit) - qdel(src) - return 1 - else - user << "You can't load the [src.name] while it's opened." - return 1 var/material - switch(W.type) + switch(I.type) if(/obj/item/stack/material/gold) material = "gold" if(/obj/item/stack/material/silver) @@ -788,30 +177,171 @@ else return ..() - if(src.being_built) - user << "The fabricator is currently processing. Please wait until completion." - return - - var/obj/item/stack/material/stack = W - + var/obj/item/stack/material/stack = I var/sname = "[stack.name]" var/amnt = stack.perunit - if(src.resources[material] < res_max_amount) + + if(materials[material] + amnt <= res_max_amount) if(stack && stack.amount >= 1) var/count = 0 - src.overlays += "fab-load-[material]"//loading animation is now an overlay based on material type. No more spontaneous conversion of all ores to metal. -vey - sleep(10) - - while(src.resources[material] < res_max_amount && stack.amount >= 1) - src.resources[material] += amnt + overlays += "fab-load-metal" + spawn(10) + overlays -= "fab-load-metal" + while(materials[material] + amnt <= res_max_amount && stack.amount >= 1) + materials[material] += amnt stack.use(1) count++ - src.overlays -= "fab-load-[material]" user << "You insert [count] [sname] into the fabricator." - src.updateUsrDialog() - else - user << "The fabricator can only accept full sheets of [sname]." - return + update_busy() else user << "The fabricator cannot hold more [sname]." - return + +/obj/machinery/mecha_part_fabricator/emag_act(var/remaining_charges, var/mob/user) + switch(emagged) + if(0) + emagged = 0.5 + visible_message("\icon[src] [src] beeps: \"DB error \[Code 0x00F1\]\"") + sleep(10) + visible_message("\icon[src] [src] beeps: \"Attempting auto-repair\"") + sleep(15) + visible_message("\icon[src] [src] beeps: \"User DB corrupted \[Code 0x00FA\]. Truncating data structure...\"") + sleep(30) + visible_message("\icon[src] [src] beeps: \"User DB truncated. Please contact your [company_name] system operator for future assistance.\"") + req_access = null + emagged = 1 + return 1 + if(0.5) + visible_message("\icon[src] [src] beeps: \"DB not responding \[Code 0x0003\]...\"") + if(1) + visible_message("\icon[src] [src] beeps: \"No records in User DB\"") + +/obj/machinery/mecha_part_fabricator/proc/update_busy() + if(queue.len) + if(can_build(queue[1])) + busy = 1 + else + busy = 0 + else + busy = 0 + +/obj/machinery/mecha_part_fabricator/proc/add_to_queue(var/index) + var/datum/design/D = files.known_designs[index] + queue += D + update_busy() + +/obj/machinery/mecha_part_fabricator/proc/remove_from_queue(var/index) + if(index == 1) + progress = 0 + queue.Cut(index, index + 1) + update_busy() + +/obj/machinery/mecha_part_fabricator/proc/can_build(var/datum/design/D) + for(var/M in D.materials) + if(materials[M] < D.materials[M]) + return 0 + return 1 + +/obj/machinery/mecha_part_fabricator/proc/check_build() + if(!queue.len) + progress = 0 + return + var/datum/design/D = queue[1] + if(!can_build(D)) + progress = 0 + return + if(D.time > progress) + return + for(var/M in D.materials) + materials[M] = max(0, materials[M] - D.materials[M] * mat_efficiency) + if(D.build_path) + var/obj/new_item = new D.build_path(loc, manufacturer) + visible_message("\The [src] pings, indicating that \the [D] is complete.", "You hear a ping.") + if(mat_efficiency != 1) + if(new_item.matter && new_item.matter.len > 0) + for(var/i in new_item.matter) + new_item.matter[i] = new_item.matter[i] * mat_efficiency + remove_from_queue(1) + +/obj/machinery/mecha_part_fabricator/proc/get_queue_names() + . = list() + for(var/i = 2 to queue.len) + var/datum/design/D = queue[i] + . += D.name + +/obj/machinery/mecha_part_fabricator/proc/get_build_options() + . = list() + for(var/i = 1 to files.known_designs.len) + var/datum/design/D = files.known_designs[i] + if(!D.build_path || !(D.build_type & MECHFAB)) + continue + . += list(list("name" = D.name, "id" = i, "category" = D.category, "resourses" = get_design_resourses(D), "time" = get_design_time(D))) + +/obj/machinery/mecha_part_fabricator/proc/get_design_resourses(var/datum/design/D) + var/list/F = list() + for(var/T in D.materials) + F += "[capitalize(T)]: [D.materials[T] * mat_efficiency]" + return english_list(F, and_text = ", ") + +/obj/machinery/mecha_part_fabricator/proc/get_design_time(var/datum/design/D) + return time2text(round(10 * D.time / speed), "mm:ss") + +/obj/machinery/mecha_part_fabricator/proc/update_categories() + categories = list() + for(var/datum/design/D in files.known_designs) + if(!D.build_path || !(D.build_type & MECHFAB)) + continue + categories |= D.category + if(!category || !(category in categories)) + category = categories[1] + +/obj/machinery/mecha_part_fabricator/proc/get_materials() + . = list() + for(var/T in materials) + . += list(list("mat" = capitalize(T), "amt" = materials[T])) + +/obj/machinery/mecha_part_fabricator/proc/eject_materials(var/material, var/amount) // 0 amount = 0 means ejecting a full stack; -1 means eject everything + var/recursive = amount == -1 ? 1 : 0 + material = lowertext(material) + var/mattype + switch(material) + if(DEFAULT_WALL_MATERIAL) + mattype = /obj/item/stack/material/steel + if("glass") + mattype = /obj/item/stack/material/glass + if("gold") + mattype = /obj/item/stack/material/gold + if("silver") + mattype = /obj/item/stack/material/silver + if("diamond") + mattype = /obj/item/stack/material/diamond + if("phoron") + mattype = /obj/item/stack/material/phoron + if("uranium") + mattype = /obj/item/stack/material/uranium + else + return + var/obj/item/stack/material/S = new mattype(loc) + if(amount <= 0) + amount = S.max_amount + var/ejected = min(round(materials[material] / S.perunit), amount) + S.amount = min(ejected, amount) + if(S.amount <= 0) + qdel(S) + return + materials[material] -= ejected * S.perunit + if(recursive && materials[material] >= S.perunit) + eject_materials(material, -1) + update_busy() + +/obj/machinery/mecha_part_fabricator/proc/sync() + sync_message = "Error: no console found." + for(var/obj/machinery/computer/rdconsole/RDC in get_area_all_atoms(get_area(src))) + if(!RDC.sync) + continue + for(var/datum/tech/T in RDC.files.known_tech) + files.AddTech2Known(T) + for(var/datum/design/D in RDC.files.known_designs) + files.AddDesign2Known(D) + files.RefreshResearch() + sync_message = "Sync complete." + update_categories() diff --git a/code/game/mecha/mecha_control_console.dm b/code/game/mecha/mecha_control_console.dm index e3bee7a816..e9dbd93edf 100644 --- a/code/game/mecha/mecha_control_console.dm +++ b/code/game/mecha/mecha_control_console.dm @@ -70,8 +70,6 @@ icon = 'icons/obj/device.dmi' icon_state = "motion2" origin_tech = list(TECH_DATA = 2, TECH_MAGNET = 2) - construction_time = 50 - construction_cost = list(DEFAULT_WALL_MATERIAL=500) proc/get_mecha_info() if(!in_mecha()) diff --git a/code/game/mecha/mecha_parts.dm b/code/game/mecha/mecha_parts.dm index fbc6a1d7aa..876e6c3f6b 100644 --- a/code/game/mecha/mecha_parts.dm +++ b/code/game/mecha/mecha_parts.dm @@ -11,15 +11,12 @@ w_class = 5 flags = CONDUCT origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2) - var/construction_time = 100 - var/list/construction_cost = list(DEFAULT_WALL_MATERIAL=20000,"glass"=5000) /obj/item/mecha_parts/chassis name="Mecha Chassis" icon_state = "backbone" var/datum/construction/construct - construction_cost = list(DEFAULT_WALL_MATERIAL=20000) flags = CONDUCT attackby(obj/item/W as obj, mob/user as mob) @@ -42,48 +39,37 @@ /obj/item/mecha_parts/part/ripley_torso name="Ripley Torso" desc="A torso part of Ripley APLU. Contains power unit, processing core and life support systems." - icon_state = "ripley_harness" - origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_BIO = 2, TECH_ENGINEERING = 2) - construction_time = 200 - construction_cost = list(DEFAULT_WALL_MATERIAL=40000,"glass"=15000) + icon_state = "ripley_harness" + origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_BIO = 2, TECH_ENGINEERING = 2) /obj/item/mecha_parts/part/ripley_left_arm name="Ripley Left Arm" desc="A Ripley APLU left arm. Data and power sockets are compatible with most exosuit tools." - icon_state = "ripley_l_arm" - origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_ENGINEERING = 2) - construction_time = 150 - construction_cost = list(DEFAULT_WALL_MATERIAL=25000) + icon_state = "ripley_l_arm" + origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_ENGINEERING = 2) /obj/item/mecha_parts/part/ripley_right_arm name="Ripley Right Arm" desc="A Ripley APLU right arm. Data and power sockets are compatible with most exosuit tools." - icon_state = "ripley_r_arm" - origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_ENGINEERING = 2) - construction_time = 150 - construction_cost = list(DEFAULT_WALL_MATERIAL=25000) + icon_state = "ripley_r_arm" + origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_ENGINEERING = 2) /obj/item/mecha_parts/part/ripley_left_leg name="Ripley Left Leg" desc="A Ripley APLU left leg. Contains somewhat complex servodrives and balance maintaining systems." - icon_state = "ripley_l_leg" - origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_ENGINEERING = 2) - construction_time = 150 - construction_cost = list(DEFAULT_WALL_MATERIAL=30000) + icon_state = "ripley_l_leg" + origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_ENGINEERING = 2) /obj/item/mecha_parts/part/ripley_right_leg name="Ripley Right Leg" desc="A Ripley APLU right leg. Contains somewhat complex servodrives and balance maintaining systems." - icon_state = "ripley_r_leg" - origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_ENGINEERING = 2) - construction_time = 150 - construction_cost = list(DEFAULT_WALL_MATERIAL=30000) + icon_state = "ripley_r_leg" + origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_ENGINEERING = 2) ///////// Gygax /obj/item/mecha_parts/chassis/gygax name = "Gygax Chassis" - construction_cost = list(DEFAULT_WALL_MATERIAL=25000) New() ..() @@ -92,62 +78,47 @@ /obj/item/mecha_parts/part/gygax_torso name="Gygax Torso" desc="A torso part of Gygax. Contains power unit, processing core and life support systems. Has an additional equipment slot." - icon_state = "gygax_harness" - origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_BIO = 3, TECH_ENGINEERING = 3) - construction_time = 300 - construction_cost = list(DEFAULT_WALL_MATERIAL=50000,"glass"=20000) + icon_state = "gygax_harness" + origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_BIO = 3, TECH_ENGINEERING = 3) /obj/item/mecha_parts/part/gygax_head name="Gygax Head" desc="A Gygax head. Houses advanced surveilance and targeting sensors." - icon_state = "gygax_head" - origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_MAGNET = 3, TECH_ENGINEERING = 3) - construction_time = 200 - construction_cost = list(DEFAULT_WALL_MATERIAL=20000,"glass"=10000) + icon_state = "gygax_head" + origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_MAGNET = 3, TECH_ENGINEERING = 3) /obj/item/mecha_parts/part/gygax_left_arm name="Gygax Left Arm" desc="A Gygax left arm. Data and power sockets are compatible with most exosuit tools and weapons." - icon_state = "gygax_l_arm" - origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_ENGINEERING = 3) - construction_time = 200 - construction_cost = list(DEFAULT_WALL_MATERIAL=30000) + icon_state = "gygax_l_arm" + origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_ENGINEERING = 3) /obj/item/mecha_parts/part/gygax_right_arm name="Gygax Right Arm" desc="A Gygax right arm. Data and power sockets are compatible with most exosuit tools and weapons." - icon_state = "gygax_r_arm" - origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_ENGINEERING = 3) - construction_time = 200 - construction_cost = list(DEFAULT_WALL_MATERIAL=30000) + icon_state = "gygax_r_arm" + origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_ENGINEERING = 3) /obj/item/mecha_parts/part/gygax_left_leg name="Gygax Left Leg" - icon_state = "gygax_l_leg" - origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_ENGINEERING = 3) - construction_time = 200 - construction_cost = list(DEFAULT_WALL_MATERIAL=35000) + icon_state = "gygax_l_leg" + origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_ENGINEERING = 3) /obj/item/mecha_parts/part/gygax_right_leg name="Gygax Right Leg" - icon_state = "gygax_r_leg" - origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_ENGINEERING = 3) - construction_time = 200 - construction_cost = list(DEFAULT_WALL_MATERIAL=35000) + icon_state = "gygax_r_leg" + origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_ENGINEERING = 3) /obj/item/mecha_parts/part/gygax_armour name="Gygax Armour Plates" - icon_state = "gygax_armour" - origin_tech = list(TECH_MATERIAL = 6, TECH_COMBAT = 4, TECH_ENGINEERING = 5) - construction_time = 600 - construction_cost = list(DEFAULT_WALL_MATERIAL=50000,"diamond"=10000) + icon_state = "gygax_armour" + origin_tech = list(TECH_MATERIAL = 6, TECH_COMBAT = 4, TECH_ENGINEERING = 5) //////////// Durand /obj/item/mecha_parts/chassis/durand name = "Durand Chassis" - construction_cost = list(DEFAULT_WALL_MATERIAL=25000) New() ..() @@ -155,52 +126,38 @@ /obj/item/mecha_parts/part/durand_torso name="Durand Torso" - icon_state = "durand_harness" - origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 3, TECH_BIO = 3, TECH_ENGINEERING = 3) - construction_time = 300 - construction_cost = list(DEFAULT_WALL_MATERIAL=55000,"glass"=20000,"silver"=10000) + icon_state = "durand_harness" + origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 3, TECH_BIO = 3, TECH_ENGINEERING = 3) /obj/item/mecha_parts/part/durand_head name="Durand Head" - icon_state = "durand_head" - origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 3, TECH_MAGNET = 3, TECH_ENGINEERING = 3) - construction_time = 200 - construction_cost = list(DEFAULT_WALL_MATERIAL=25000,"glass"=10000,"silver"=3000) + icon_state = "durand_head" + origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 3, TECH_MAGNET = 3, TECH_ENGINEERING = 3) /obj/item/mecha_parts/part/durand_left_arm name="Durand Left Arm" - icon_state = "durand_l_arm" - origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 3, TECH_ENGINEERING = 3) - construction_time = 200 - construction_cost = list(DEFAULT_WALL_MATERIAL=35000,"silver"=3000) + icon_state = "durand_l_arm" + origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 3, TECH_ENGINEERING = 3) /obj/item/mecha_parts/part/durand_right_arm name="Durand Right Arm" - icon_state = "durand_r_arm" - origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 3, TECH_ENGINEERING = 3) - construction_time = 200 - construction_cost = list(DEFAULT_WALL_MATERIAL=35000,"silver"=3000) + icon_state = "durand_r_arm" + origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 3, TECH_ENGINEERING = 3) /obj/item/mecha_parts/part/durand_left_leg name="Durand Left Leg" - icon_state = "durand_l_leg" - origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 3, TECH_ENGINEERING = 3) - construction_time = 200 - construction_cost = list(DEFAULT_WALL_MATERIAL=40000,"silver"=3000) + icon_state = "durand_l_leg" + origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 3, TECH_ENGINEERING = 3) /obj/item/mecha_parts/part/durand_right_leg name="Durand Right Leg" - icon_state = "durand_r_leg" - origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 3, TECH_ENGINEERING = 3) - construction_time = 200 - construction_cost = list(DEFAULT_WALL_MATERIAL=40000,"silver"=3000) + icon_state = "durand_r_leg" + origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 3, TECH_ENGINEERING = 3) /obj/item/mecha_parts/part/durand_armour name="Durand Armour Plates" - icon_state = "durand_armour" - origin_tech = list(TECH_MATERIAL = 5, TECH_COMBAT = 4, TECH_ENGINEERING = 5) - construction_time = 600 - construction_cost = list(DEFAULT_WALL_MATERIAL=50000,"uranium"=10000) + icon_state = "durand_armour" + origin_tech = list(TECH_MATERIAL = 5, TECH_COMBAT = 4, TECH_ENGINEERING = 5) @@ -247,43 +204,43 @@ /obj/item/mecha_parts/part/phazon_torso name="Phazon Torso" icon_state = "phazon_harness" - construction_time = 300 - construction_cost = list(DEFAULT_WALL_MATERIAL=35000,"glass"=10000,"phoron"=20000) + //construction_time = 300 + //construction_cost = list(DEFAULT_WALL_MATERIAL=35000,"glass"=10000,"phoron"=20000) origin_tech = list(TECH_DATA = 5, TECH_MATERIAL = 7, TECH_BLUESPACE = 6, TECH_POWER = 6) /obj/item/mecha_parts/part/phazon_head name="Phazon Head" icon_state = "phazon_head" - construction_time = 200 - construction_cost = list(DEFAULT_WALL_MATERIAL=15000,"glass"=5000,"phoron"=10000) + //construction_time = 200 + //construction_cost = list(DEFAULT_WALL_MATERIAL=15000,"glass"=5000,"phoron"=10000) origin_tech = list(TECH_DATA = 4, TECH_MATERIAL = 5, TECH_MAGNET = 6) /obj/item/mecha_parts/part/phazon_left_arm name="Phazon Left Arm" icon_state = "phazon_l_arm" - construction_time = 200 - construction_cost = list(DEFAULT_WALL_MATERIAL=20000,"phoron"=10000) + //construction_time = 200 + //construction_cost = list(DEFAULT_WALL_MATERIAL=20000,"phoron"=10000) origin_tech = list(TECH_MATERIAL = 5, TECH_BLUESPACE = 2, TECH_MAGNET = 2) /obj/item/mecha_parts/part/phazon_right_arm name="Phazon Right Arm" icon_state = "phazon_r_arm" - construction_time = 200 - construction_cost = list(DEFAULT_WALL_MATERIAL=20000,"phoron"=10000) + //construction_time = 200 + //construction_cost = list(DEFAULT_WALL_MATERIAL=20000,"phoron"=10000) origin_tech = list(TECH_MATERIAL = 5, TECH_BLUESPACE = 2, TECH_MAGNET = 2) /obj/item/mecha_parts/part/phazon_left_leg name="Phazon Left Leg" icon_state = "phazon_l_leg" - construction_time = 200 - construction_cost = list(DEFAULT_WALL_MATERIAL=20000,"phoron"=10000) + //construction_time = 200 + //construction_cost = list(DEFAULT_WALL_MATERIAL=20000,"phoron"=10000) origin_tech = list(TECH_MATERIAL = 5, TECH_BLUESPACE = 3, TECH_MAGNET = 3) /obj/item/mecha_parts/part/phazon_right_leg name="Phazon Right Leg" icon_state = "phazon_r_leg" - construction_time = 200 - construction_cost = list(DEFAULT_WALL_MATERIAL=20000,"phoron"=10000) + //construction_time = 200 + //construction_cost = list(DEFAULT_WALL_MATERIAL=20000,"phoron"=10000) origin_tech = list(TECH_MATERIAL = 5, TECH_BLUESPACE = 3, TECH_MAGNET = 3) ///////// Odysseus @@ -299,49 +256,37 @@ /obj/item/mecha_parts/part/odysseus_head name="Odysseus Head" icon_state = "odysseus_head" - construction_time = 100 - construction_cost = list(DEFAULT_WALL_MATERIAL=2000,"glass"=10000) origin_tech = list(TECH_DATA = 3, TECH_MATERIAL = 2) /obj/item/mecha_parts/part/odysseus_torso name="Odysseus Torso" desc="A torso part of Odysseus. Contains power unit, processing core and life support systems." - icon_state = "odysseus_torso" - origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_BIO = 2, TECH_ENGINEERING = 2) - construction_time = 180 - construction_cost = list(DEFAULT_WALL_MATERIAL=25000) + icon_state = "odysseus_torso" + origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_BIO = 2, TECH_ENGINEERING = 2) /obj/item/mecha_parts/part/odysseus_left_arm name="Odysseus Left Arm" desc="An Odysseus left arm. Data and power sockets are compatible with most exosuit tools." - icon_state = "odysseus_l_arm" - origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_ENGINEERING = 2) - construction_time = 120 - construction_cost = list(DEFAULT_WALL_MATERIAL=10000) + icon_state = "odysseus_l_arm" + origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_ENGINEERING = 2) /obj/item/mecha_parts/part/odysseus_right_arm name="Odysseus Right Arm" desc="An Odysseus right arm. Data and power sockets are compatible with most exosuit tools." - icon_state = "odysseus_r_arm" - origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_ENGINEERING = 2) - construction_time = 120 - construction_cost = list(DEFAULT_WALL_MATERIAL=10000) + icon_state = "odysseus_r_arm" + origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_ENGINEERING = 2) /obj/item/mecha_parts/part/odysseus_left_leg name="Odysseus Left Leg" desc="An Odysseus left leg. Contains somewhat complex servodrives and balance maintaining systems." - icon_state = "odysseus_l_leg" - origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_ENGINEERING = 2) - construction_time = 130 - construction_cost = list(DEFAULT_WALL_MATERIAL=15000) + icon_state = "odysseus_l_leg" + origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_ENGINEERING = 2) /obj/item/mecha_parts/part/odysseus_right_leg name="Odysseus Right Leg" desc="A Odysseus right leg. Contains somewhat complex servodrives and balance maintaining systems." - icon_state = "odysseus_r_leg" - origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_ENGINEERING = 2) - construction_time = 130 - construction_cost = list(DEFAULT_WALL_MATERIAL=15000) + icon_state = "odysseus_r_leg" + origin_tech = list(TECH_DATA = 2, TECH_MATERIAL = 2, TECH_ENGINEERING = 2) /*/obj/item/mecha_parts/part/odysseus_armour name="Odysseus Carapace" diff --git a/code/game/objects/items/devices/flash.dm b/code/game/objects/items/devices/flash.dm index 8f9fa27093..c253976b76 100644 --- a/code/game/objects/items/devices/flash.dm +++ b/code/game/objects/items/devices/flash.dm @@ -194,8 +194,6 @@ desc = "When a problem arises, SCIENCE is the solution." icon_state = "sflash" origin_tech = list(TECH_MAGNET = 2, TECH_COMBAT = 1) - var/construction_cost = list(DEFAULT_WALL_MATERIAL=750,"glass"=750) - var/construction_time=100 /obj/item/device/flash/synthetic/attack(mob/living/M as mob, mob/user as mob) ..() diff --git a/code/game/objects/items/devices/t_scanner.dm b/code/game/objects/items/devices/t_scanner.dm index 3bd706f11e..7dc13cb9e8 100644 --- a/code/game/objects/items/devices/t_scanner.dm +++ b/code/game/objects/items/devices/t_scanner.dm @@ -8,7 +8,7 @@ w_class = 2 item_state = "electronic" matter = list(DEFAULT_WALL_MATERIAL = 150) - origin_tech = list(TECH_MAGNET = 1, TECH_ENGINERING = 1) + origin_tech = list(TECH_MAGNET = 1, TECH_ENGINEERING = 1) var/scan_range = 1 diff --git a/code/game/objects/items/robot/robot_parts.dm b/code/game/objects/items/robot/robot_parts.dm index 83c5ea2098..78a4e41f28 100644 --- a/code/game/objects/items/robot/robot_parts.dm +++ b/code/game/objects/items/robot/robot_parts.dm @@ -5,8 +5,6 @@ icon_state = "blank" flags = CONDUCT slot_flags = SLOT_BELT - var/construction_time = 100 - var/list/construction_cost = list(DEFAULT_WALL_MATERIAL=20000,"glass"=5000) var/list/part = null // Order of args is important for installing robolimbs. var/sabotaged = 0 //Emagging limbs can have repercussions when installed as prosthetics. var/model_info @@ -32,8 +30,6 @@ name = "left arm" desc = "A skeletal limb wrapped in pseudomuscles, with a low-conductivity case." icon_state = "l_arm" - construction_time = 200 - construction_cost = list(DEFAULT_WALL_MATERIAL=18000) part = list("l_arm","l_hand") model_info = 1 @@ -41,8 +37,6 @@ name = "right arm" desc = "A skeletal limb wrapped in pseudomuscles, with a low-conductivity case." icon_state = "r_arm" - construction_time = 200 - construction_cost = list(DEFAULT_WALL_MATERIAL=18000) part = list("r_arm","r_hand") model_info = 1 @@ -50,8 +44,6 @@ name = "left leg" desc = "A skeletal limb wrapped in pseudomuscles, with a low-conductivity case." icon_state = "l_leg" - construction_time = 200 - construction_cost = list(DEFAULT_WALL_MATERIAL=15000) part = list("l_leg","l_foot") model_info = 1 @@ -59,8 +51,6 @@ name = "right leg" desc = "A skeletal limb wrapped in pseudomuscles, with a low-conductivity case." icon_state = "r_leg" - construction_time = 200 - construction_cost = list(DEFAULT_WALL_MATERIAL=15000) part = list("r_leg","r_foot") model_info = 1 @@ -69,8 +59,6 @@ desc = "A heavily reinforced case containing cyborg logic boards, with space for a standard power cell." icon_state = "chest" part = list("groin","chest") - construction_time = 350 - construction_cost = list(DEFAULT_WALL_MATERIAL=40000) var/wires = 0.0 var/obj/item/weapon/cell/cell = null @@ -79,8 +67,6 @@ desc = "A standard reinforced braincase, with spine-plugged neural socket and sensor gimbals." icon_state = "head" part = list("head") - construction_time = 350 - construction_cost = list(DEFAULT_WALL_MATERIAL=25000) var/obj/item/device/flash/flash1 = null var/obj/item/device/flash/flash2 = null @@ -88,8 +74,6 @@ name = "endoskeleton" desc = "A complex metal backbone with standard limb sockets and pseudomuscle anchors." icon_state = "robo_suit" - construction_time = 500 - construction_cost = list(DEFAULT_WALL_MATERIAL=50000) var/obj/item/robot_parts/l_arm/l_arm = null var/obj/item/robot_parts/r_arm/r_arm = null var/obj/item/robot_parts/l_leg/l_leg = null diff --git a/code/game/objects/items/robot/robot_upgrades.dm b/code/game/objects/items/robot/robot_upgrades.dm index 1dc489d75e..ccd6ab0adb 100644 --- a/code/game/objects/items/robot/robot_upgrades.dm +++ b/code/game/objects/items/robot/robot_upgrades.dm @@ -6,8 +6,6 @@ desc = "Protected by FRM." icon = 'icons/obj/module.dmi' icon_state = "cyborg_upgrade" - var/construction_time = 120 - var/construction_cost = list(DEFAULT_WALL_MATERIAL=10000) var/locked = 0 var/require_module = 0 var/installed = 0 @@ -43,7 +41,6 @@ name = "robot reclassification board" desc = "Used to rename a cyborg." icon_state = "cyborg_upgrade1" - construction_cost = list(DEFAULT_WALL_MATERIAL=35000) var/heldname = "default name" /obj/item/borg/upgrade/rename/attack_self(mob/user as mob) @@ -61,7 +58,6 @@ /obj/item/borg/upgrade/restart name = "robot emergency restart module" desc = "Used to force a restart of a disabled-but-repaired robot, bringing it back online." - construction_cost = list(DEFAULT_WALL_MATERIAL=60000 , "glass"=5000) icon_state = "cyborg_upgrade1" @@ -85,7 +81,6 @@ /obj/item/borg/upgrade/vtec name = "robotic VTEC Module" desc = "Used to kick in a robot's VTEC systems, increasing their speed." - construction_cost = list(DEFAULT_WALL_MATERIAL=80000 , "glass"=6000 , "gold"= 5000) icon_state = "cyborg_upgrade2" require_module = 1 @@ -102,7 +97,6 @@ /obj/item/borg/upgrade/tasercooler name = "robotic Rapid Taser Cooling Module" desc = "Used to cool a mounted taser, increasing the potential current in it and thus its recharge rate." - construction_cost = list(DEFAULT_WALL_MATERIAL=80000 , "glass"=6000 , "gold"= 2000, "diamond" = 500) icon_state = "cyborg_upgrade3" require_module = 1 @@ -137,7 +131,6 @@ /obj/item/borg/upgrade/jetpack name = "mining robot jetpack" desc = "A carbon dioxide jetpack suitable for low-gravity mining operations." - construction_cost = list(DEFAULT_WALL_MATERIAL=10000,"phoron"=15000,"uranium" = 20000) icon_state = "cyborg_upgrade3" require_module = 1 @@ -159,7 +152,6 @@ /obj/item/borg/upgrade/syndicate/ name = "illegal equipment module" desc = "Unlocks the hidden, deadlier functions of a robot" - construction_cost = list(DEFAULT_WALL_MATERIAL=10000,"glass"=15000,"diamond" = 10000) icon_state = "cyborg_upgrade3" require_module = 1 diff --git a/code/game/objects/items/weapons/power_cells.dm b/code/game/objects/items/weapons/power_cells.dm index a471595886..e61875f5ec 100644 --- a/code/game/objects/items/weapons/power_cells.dm +++ b/code/game/objects/items/weapons/power_cells.dm @@ -14,8 +14,6 @@ var/maxcharge = 1000 var/rigged = 0 // true if rigged to explode var/minor_fault = 0 //If not 100% reliable, it will build up faults. - var/construction_cost = list(DEFAULT_WALL_MATERIAL=750,"glass"=75) - var/construction_time=100 matter = list(DEFAULT_WALL_MATERIAL = 700, "glass" = 50) suicide_act(mob/user) @@ -83,7 +81,6 @@ icon_state = "scell" maxcharge = 20000 matter = list(DEFAULT_WALL_MATERIAL = 700, "glass" = 70) - construction_cost = list(DEFAULT_WALL_MATERIAL=750,"glass"=100) /obj/item/weapon/cell/super/empty/New() ..() @@ -95,7 +92,6 @@ icon_state = "hpcell" maxcharge = 30000 matter = list(DEFAULT_WALL_MATERIAL = 700, "glass" = 80) - construction_cost = list(DEFAULT_WALL_MATERIAL=500,"glass"=150,"gold"=200,"silver"=200) /obj/item/weapon/cell/hyper/empty/New() ..() diff --git a/code/modules/mob/holder.dm b/code/modules/mob/holder.dm index 862602bd5c..8b44fb8627 100644 --- a/code/modules/mob/holder.dm +++ b/code/modules/mob/holder.dm @@ -57,7 +57,7 @@ slot_flags = SLOT_HEAD | SLOT_OCLOTHING /obj/item/weapon/holder/drone - origin_tech = list(TECH_MAGNET = 3, TECH_ENGINERING = 5) + origin_tech = list(TECH_MAGNET = 3, TECH_ENGINEERING = 5) /obj/item/weapon/holder/mouse w_class = 1 diff --git a/code/modules/mob/living/carbon/brain/MMI.dm b/code/modules/mob/living/carbon/brain/MMI.dm index d9b84ea3b0..07004f9754 100644 --- a/code/modules/mob/living/carbon/brain/MMI.dm +++ b/code/modules/mob/living/carbon/brain/MMI.dm @@ -25,10 +25,6 @@ w_class = 3 origin_tech = list(TECH_BIO = 3) - var/list/construction_cost = list(DEFAULT_WALL_MATERIAL=1000,"glass"=500) - var/construction_time = 75 - //these vars are so the mecha fabricator doesn't shit itself anymore. --NEO - req_access = list(access_robotics) //Revised. Brainmob is now contained directly within object of transfer. MMI in this case. diff --git a/code/modules/mob/living/carbon/brain/posibrain.dm b/code/modules/mob/living/carbon/brain/posibrain.dm index 4af00df604..05198f38bf 100644 --- a/code/modules/mob/living/carbon/brain/posibrain.dm +++ b/code/modules/mob/living/carbon/brain/posibrain.dm @@ -6,8 +6,6 @@ w_class = 3 origin_tech = list(TECH_ENGINEERING = 4, TECH_MATERIAL = 4, TECH_BLUESPACE = 2, TECH_DATA = 4) - construction_cost = list(DEFAULT_WALL_MATERIAL=500,"glass"=500,"silver"=200,"gold"=200,"phoron"=100,"diamond"=10) - construction_time = 75 var/searching = 0 var/askDelay = 10 * 60 * 1 req_access = list(access_robotics) diff --git a/code/modules/mob/living/silicon/robot/component.dm b/code/modules/mob/living/silicon/robot/component.dm index 1894d62942..6f0b3d81bd 100644 --- a/code/modules/mob/living/silicon/robot/component.dm +++ b/code/modules/mob/living/silicon/robot/component.dm @@ -217,8 +217,6 @@ /obj/item/robot_parts/robot_component icon = 'icons/obj/robot_component.dmi' icon_state = "working" - construction_time = 200 - construction_cost = list(DEFAULT_WALL_MATERIAL=5000) var/brute = 0 var/burn = 0 var/icon_state_broken = "broken" diff --git a/code/modules/research/designs.dm b/code/modules/research/designs.dm index 9d5bfd40da..ce5fb4670b 100644 --- a/code/modules/research/designs.dm +++ b/code/modules/research/designs.dm @@ -63,7 +63,7 @@ other types of metals and chemistry for reagents). desc = "Produce additional disks for storing device designs." id = "design_disk" req_tech = list(TECH_DATA = 1) - materials = list("metal" = 30, "glass" = 10) + materials = list(DEFAULT_WALL_MATERIAL = 30, "glass" = 10) build_path = /obj/item/weapon/disk/design_disk sort_string = "GAAAA" @@ -72,7 +72,7 @@ other types of metals and chemistry for reagents). desc = "Produce additional disks for storing technology data." id = "tech_disk" req_tech = list(TECH_DATA = 1) - materials = list("metal" = 30, "glass" = 10) + materials = list(DEFAULT_WALL_MATERIAL = 30, "glass" = 10) build_path = /obj/item/weapon/disk/tech_disk sort_string = "GAAAB" @@ -90,114 +90,114 @@ other types of metals and chemistry for reagents). /datum/design/item/stock_part/basic_capacitor id = "basic_capacitor" req_tech = list(TECH_POWER = 1) - materials = list("metal" = 50, "glass" = 50) + materials = list(DEFAULT_WALL_MATERIAL = 50, "glass" = 50) build_path = /obj/item/weapon/stock_parts/capacitor sort_string = "CAAAA" /datum/design/item/stock_part/adv_capacitor id = "adv_capacitor" req_tech = list(TECH_POWER = 3) - materials = list("metal" = 50, "glass" = 50) + materials = list(DEFAULT_WALL_MATERIAL = 50, "glass" = 50) build_path = /obj/item/weapon/stock_parts/capacitor/adv sort_string = "CAAAB" /datum/design/item/stock_part/super_capacitor id = "super_capacitor" req_tech = list(TECH_POWER = 5, TECH_MATERIAL = 4) - materials = list("metal" = 50, "glass" = 50, "gold" = 20) + materials = list(DEFAULT_WALL_MATERIAL = 50, "glass" = 50, "gold" = 20) build_path = /obj/item/weapon/stock_parts/capacitor/super sort_string = "CAAAC" /datum/design/item/stock_part/micro_mani id = "micro_mani" req_tech = list(TECH_MATERIAL = 1, TECH_DATA = 1) - materials = list("metal" = 30) + materials = list(DEFAULT_WALL_MATERIAL = 30) build_path = /obj/item/weapon/stock_parts/manipulator sort_string = "CAABA" /datum/design/item/stock_part/nano_mani id = "nano_mani" req_tech = list(TECH_MATERIAL = 3, TECH_DATA = 2) - materials = list("metal" = 30) + materials = list(DEFAULT_WALL_MATERIAL = 30) build_path = /obj/item/weapon/stock_parts/manipulator/nano sort_string = "CAABB" /datum/design/item/stock_part/pico_mani id = "pico_mani" req_tech = list(TECH_MATERIAL = 5, TECH_DATA = 2) - materials = list("metal" = 30) + materials = list(DEFAULT_WALL_MATERIAL = 30) build_path = /obj/item/weapon/stock_parts/manipulator/pico sort_string = "CAABC" /datum/design/item/stock_part/basic_matter_bin id = "basic_matter_bin" req_tech = list(TECH_MATERIAL = 1) - materials = list("metal" = 80) + materials = list(DEFAULT_WALL_MATERIAL = 80) build_path = /obj/item/weapon/stock_parts/matter_bin sort_string = "CAACA" /datum/design/item/stock_part/adv_matter_bin id = "adv_matter_bin" req_tech = list(TECH_MATERIAL = 3) - materials = list("metal" = 80) + materials = list(DEFAULT_WALL_MATERIAL = 80) build_path = /obj/item/weapon/stock_parts/matter_bin/adv sort_string = "CAACB" /datum/design/item/stock_part/super_matter_bin id = "super_matter_bin" req_tech = list(TECH_MATERIAL = 5) - materials = list("metal" = 80) + materials = list(DEFAULT_WALL_MATERIAL = 80) build_path = /obj/item/weapon/stock_parts/matter_bin/super sort_string = "CAACC" /datum/design/item/stock_part/basic_micro_laser id = "basic_micro_laser" req_tech = list(TECH_MAGNET = 1) - materials = list("metal" = 10, "glass" = 20) + materials = list(DEFAULT_WALL_MATERIAL = 10, "glass" = 20) build_path = /obj/item/weapon/stock_parts/micro_laser sort_string = "CAADA" /datum/design/item/stock_part/high_micro_laser id = "high_micro_laser" req_tech = list(TECH_MAGNET = 3) - materials = list("metal" = 10, "glass" = 20) + materials = list(DEFAULT_WALL_MATERIAL = 10, "glass" = 20) build_path = /obj/item/weapon/stock_parts/micro_laser/high sort_string = "CAADB" /datum/design/item/stock_part/ultra_micro_laser id = "ultra_micro_laser" req_tech = list(TECH_MAGNET = 5, TECH_MATERIAL = 5) - materials = list("metal" = 10, "glass" = 20, "uranium" = 10) + materials = list(DEFAULT_WALL_MATERIAL = 10, "glass" = 20, "uranium" = 10) build_path = /obj/item/weapon/stock_parts/micro_laser/ultra sort_string = "CAADC" /datum/design/item/stock_part/basic_sensor id = "basic_sensor" req_tech = list(TECH_MAGNET = 1) - materials = list("metal" = 50, "glass" = 20) + materials = list(DEFAULT_WALL_MATERIAL = 50, "glass" = 20) build_path = /obj/item/weapon/stock_parts/scanning_module sort_string = "CAAEA" /datum/design/item/stock_part/adv_sensor id = "adv_sensor" req_tech = list(TECH_MAGNET = 3) - materials = list("metal" = 50, "glass" = 20) + materials = list(DEFAULT_WALL_MATERIAL = 50, "glass" = 20) build_path = /obj/item/weapon/stock_parts/scanning_module/adv sort_string = "CAAEB" /datum/design/item/stock_part/phasic_sensor id = "phasic_sensor" req_tech = list(TECH_MAGNET = 5, TECH_MATERIAL = 3) - materials = list("metal" = 50, "glass" = 20, "silver" = 10) + materials = list(DEFAULT_WALL_MATERIAL = 50, "glass" = 20, "silver" = 10) build_path = /obj/item/weapon/stock_parts/scanning_module/phasic sort_string = "CAAEC" /datum/design/item/stock_part/RPED name = "Rapid Part Exchange Device" desc = "Special mechanical module made to store, sort, and apply standard machine parts." - id = "rped" + id = "rped" req_tech = list(TECH_ENGINEERING = 3, TECH_MATERIAL = 3) - materials = list("metal" = 15000, "glass" = 5000) + materials = list(DEFAULT_WALL_MATERIAL = 15000, "glass" = 5000) build_path = /obj/item/weapon/storage/part_replacer sort_string = "CBAAA" @@ -217,7 +217,7 @@ other types of metals and chemistry for reagents). build_type = PROTOLATHE | MECHFAB id = "basic_cell" req_tech = list(TECH_POWER = 1) - materials = list("metal" = 700, "glass" = 50) + materials = list(DEFAULT_WALL_MATERIAL = 700, "glass" = 50) build_path = /obj/item/weapon/cell category = "Misc" sort_string = "DAAAA" @@ -227,7 +227,7 @@ other types of metals and chemistry for reagents). build_type = PROTOLATHE | MECHFAB id = "high_cell" req_tech = list(TECH_POWER = 2) - materials = list("metal" = 700, "glass" = 60) + materials = list(DEFAULT_WALL_MATERIAL = 700, "glass" = 60) build_path = /obj/item/weapon/cell/high category = "Misc" sort_string = "DAAAB" @@ -236,7 +236,7 @@ other types of metals and chemistry for reagents). name = "super-capacity" id = "super_cell" req_tech = list(TECH_POWER = 3, TECH_MATERIAL = 2) - materials = list("metal" = 700, "glass" = 70) + materials = list(DEFAULT_WALL_MATERIAL = 700, "glass" = 70) build_path = /obj/item/weapon/cell/super category = "Misc" sort_string = "DAAAC" @@ -245,13 +245,13 @@ other types of metals and chemistry for reagents). name = "hyper-capacity" id = "hyper_cell" req_tech = list(TECH_POWER = 5, TECH_MATERIAL = 4) - materials = list("metal" = 400, "gold" = 150, "silver" = 150, "glass" = 70) + materials = list(DEFAULT_WALL_MATERIAL = 400, "gold" = 150, "silver" = 150, "glass" = 70) build_path = /obj/item/weapon/cell/hyper category = "Misc" sort_string = "DAAAD" /datum/design/item/hud - materials = list("metal" = 50, "glass" = 50) + materials = list(DEFAULT_WALL_MATERIAL = 50, "glass" = 50) /datum/design/item/hud/AssembleDesignName() ..() @@ -277,9 +277,9 @@ other types of metals and chemistry for reagents). /datum/design/item/mesons name = "Optical meson scanners design" desc = "Using the meson-scanning technology those glasses allow you to see through walls, floor or anything else." - id = "mesons" + id = "mesons" req_tech = list(TECH_MAGNET = 2, TECH_ENGINEERING = 2) - materials = list("metal" = 50, "glass" = 50) + materials = list(DEFAULT_WALL_MATERIAL = 50, "glass" = 50) build_path = /obj/item/clothing/glasses/meson sort_string = "GAAAC" @@ -288,23 +288,23 @@ other types of metals and chemistry for reagents). name = "Mining equipment design ([item_name])" /datum/design/item/weapon/mining/jackhammer - id = "jackhammer" + id = "jackhammer" req_tech = list(TECH_MATERIAL = 3, TECH_POWER = 2, TECH_ENGINEERING = 2) - materials = list("metal" = 2000, "glass" = 500, "silver" = 500) + materials = list(DEFAULT_WALL_MATERIAL = 2000, "glass" = 500, "silver" = 500) build_path = /obj/item/weapon/pickaxe/jackhammer sort_string = "KAAAA" /datum/design/item/weapon/mining/drill - id = "drill" + id = "drill" req_tech = list(TECH_MATERIAL = 2, TECH_POWER = 3, TECH_ENGINEERING = 2) - materials = list("metal" = 6000, "glass" = 1000) //expensive, but no need for miners. + materials = list(DEFAULT_WALL_MATERIAL = 6000, "glass" = 1000) //expensive, but no need for miners. build_path = /obj/item/weapon/pickaxe/drill sort_string = "KAAAB" /datum/design/item/weapon/mining/plasmacutter - id = "plasmacutter" + id = "plasmacutter" req_tech = list(TECH_MATERIAL = 4, TECH_PHORON = 3, TECH_ENGINEERING = 3) - materials = list("metal" = 1500, "glass" = 500, "gold" = 500, "phoron" = 500) + materials = list(DEFAULT_WALL_MATERIAL = 1500, "glass" = 500, "gold" = 500, "phoron" = 500) build_path = /obj/item/weapon/pickaxe/plasmacutter sort_string = "KAAAC" @@ -316,9 +316,9 @@ other types of metals and chemistry for reagents). sort_string = "KAAAD" /datum/design/item/weapon/mining/drill_diamond - id = "drill_diamond" + id = "drill_diamond" req_tech = list(TECH_MATERIAL = 6, TECH_POWER = 4, TECH_ENGINEERING = 4) - materials = list("metal" = 3000, "glass" = 1000, "diamond" = 2000) + materials = list(DEFAULT_WALL_MATERIAL = 3000, "glass" = 1000, "diamond" = 2000) build_path = /obj/item/weapon/pickaxe/diamonddrill sort_string = "KAAAE" /////////////////////////////////// @@ -329,7 +329,7 @@ other types of metals and chemistry for reagents). materials = list("$glass" = 2000, "sacid" = 20, "$phoron" = 10000, "$diamond" = 5000, "$gold" = 10000) /datum/design/item/medical - materials = list("metal" = 30, "glass" = 20) + materials = list(DEFAULT_WALL_MATERIAL = 30, "glass" = 20) /datum/design/item/medical/AssembleDesignName() ..() @@ -337,9 +337,9 @@ other types of metals and chemistry for reagents). /datum/design/item/medical/robot_scanner desc = "A hand-held scanner able to diagnose robotic injuries." - id = "robot_scanner" + id = "robot_scanner" req_tech = list(TECH_MAGNET = 3, TECH_BIO = 2, TECH_ENGINEERING = 3) - materials = list("metal" = 500, "glass" = 200) + materials = list(DEFAULT_WALL_MATERIAL = 500, "glass" = 200) build_path = /obj/item/device/robotanalyzer sort_string = "MACFA" @@ -379,7 +379,7 @@ other types of metals and chemistry for reagents). desc = "A cryostasis beaker that allows for chemical storage without reactions. Can hold up to 50 units." id = "splitbeaker" req_tech = list(TECH_MATERIAL = 2) - materials = list("metal" = 3000) + materials = list(DEFAULT_WALL_MATERIAL = 3000) build_path = /obj/item/weapon/reagent_containers/glass/beaker/noreact sort_string = "MADAA" @@ -388,15 +388,15 @@ other types of metals and chemistry for reagents). 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" req_tech = list(TECH_BLUESPACE = 2, TECH_MATERIAL = 6) - materials = list("metal" = 3000, "phoron" = 3000, "diamond" = 500) + materials = list(DEFAULT_WALL_MATERIAL = 3000, "phoron" = 3000, "diamond" = 500) build_path = /obj/item/weapon/reagent_containers/glass/beaker/bluespace sort_string = "MADAB" /datum/design/item/medical/nanopaste desc = "A tube of paste containing swarms of repair nanites. Very effective in repairing robotic machinery." - id = "nanopaste" + id = "nanopaste" req_tech = list(TECH_MATERIAL = 4, TECH_ENGINEERING = 3) - materials = list("metal" = 7000, "glass" = 7000) + materials = list(DEFAULT_WALL_MATERIAL = 7000, "glass" = 7000) build_path = /obj/item/stack/nanopaste sort_string = "MBAAA" @@ -405,7 +405,7 @@ other types of metals and chemistry for reagents). desc = "A scalpel augmented with a directed laser, for more precise cutting without blood entering the field. This one looks basic and could be improved." id = "scalpel_laser1" req_tech = list(TECH_BIO = 2, TECH_MATERIAL = 2, TECH_MAGNET = 2) - materials = list("metal" = 12500, "glass" = 7500) + materials = list(DEFAULT_WALL_MATERIAL = 12500, "glass" = 7500) build_path = /obj/item/weapon/scalpel/laser1 sort_string = "MBBAA" @@ -414,7 +414,7 @@ other types of metals and chemistry for reagents). desc = "A scalpel augmented with a directed laser, for more precise cutting without blood entering the field. This one looks somewhat advanced." id = "scalpel_laser2" req_tech = list(TECH_BIO = 3, TECH_MATERIAL = 4, TECH_MAGNET = 4) - materials = list("metal" = 12500, "glass" = 7500, "silver" = 2500) + materials = list(DEFAULT_WALL_MATERIAL = 12500, "glass" = 7500, "silver" = 2500) build_path = /obj/item/weapon/scalpel/laser2 sort_string = "MBBAB" @@ -423,7 +423,7 @@ other types of metals and chemistry for reagents). desc = "A scalpel augmented with a directed laser, for more precise cutting without blood entering the field. This one looks to be the pinnacle of precision energy cutlery!" id = "scalpel_laser3" req_tech = list(TECH_BIO = 4, TECH_MATERIAL = 6, TECH_MAGNET = 5) - materials = list("metal" = 12500, "glass" = 7500, "silver" = 2000, "gold" = 1500) + materials = list(DEFAULT_WALL_MATERIAL = 12500, "glass" = 7500, "silver" = 2000, "gold" = 1500) build_path = /obj/item/weapon/scalpel/laser3 sort_string = "MBBAC" @@ -432,12 +432,12 @@ other types of metals and chemistry for reagents). desc = "A true extension of the surgeon's body, this marvel instantly and completely prepares an incision allowing for the immediate commencement of therapeutic steps." id = "scalpel_manager" req_tech = list(TECH_BIO = 4, TECH_MATERIAL = 7, TECH_MAGNET = 5, TECH_DATA = 4) - materials = list ("metal" = 12500, "glass" = 7500, "silver" = 1500, "gold" = 1500, "diamond" = 750) + materials = list (DEFAULT_WALL_MATERIAL = 12500, "glass" = 7500, "silver" = 1500, "gold" = 1500, "diamond" = 750) build_path = /obj/item/weapon/scalpel/manager sort_string = "MBBAD" /datum/design/item/implant - materials = list("metal" = 50, "glass" = 50) + materials = list(DEFAULT_WALL_MATERIAL = 50, "glass" = 50) /datum/design/item/implant/AssembleDesignName() ..() @@ -471,14 +471,14 @@ other types of metals and chemistry for reagents). /datum/design/item/weapon/stunrevolver id = "stunrevolver" req_tech = list(TECH_COMBAT = 3, TECH_MATERIAL = 3, TECH_POWER = 2) - materials = list("metal" = 4000) + materials = list(DEFAULT_WALL_MATERIAL = 4000) build_path = /obj/item/weapon/gun/energy/stunrevolver sort_string = "TAAAA" /datum/design/item/weapon/nuclear_gun id = "nuclear_gun" req_tech = list(TECH_COMBAT = 3, TECH_MATERIAL = 5, TECH_POWER = 3) - materials = list("metal" = 5000, "glass" = 1000, "uranium" = 500) + materials = list(DEFAULT_WALL_MATERIAL = 5000, "glass" = 1000, "uranium" = 500) build_path = /obj/item/weapon/gun/energy/gun/nuclear sort_string = "TAAAB" @@ -486,14 +486,14 @@ other types of metals and chemistry for reagents). desc = "The lasing medium of this prototype is enclosed in a tube lined with uranium-235 and subjected to high neutron flux in a nuclear reactor core." id = "lasercannon" req_tech = list(TECH_COMBAT = 4, TECH_MATERIAL = 3, TECH_POWER = 3) - materials = list("metal" = 10000, "glass" = 1000, "diamond" = 2000) + materials = list(DEFAULT_WALL_MATERIAL = 10000, "glass" = 1000, "diamond" = 2000) build_path = /obj/item/weapon/gun/energy/lasercannon sort_string = "TAAAC" /datum/design/item/weapon/phoronpistol id = "ppistol" req_tech = list(TECH_COMBAT = 5, TECH_PHORON = 4) - materials = list("metal" = 5000, "glass" = 1000, "phoron" = 3000) + materials = list(DEFAULT_WALL_MATERIAL = 5000, "glass" = 1000, "phoron" = 3000) build_path = /obj/item/weapon/gun/energy/toxgun sort_string = "TAAAD" @@ -507,14 +507,14 @@ other types of metals and chemistry for reagents). /datum/design/item/weapon/smg id = "smg" req_tech = list(TECH_COMBAT = 4, TECH_MATERIAL = 3) - materials = list("metal" = 8000, "silver" = 2000, "diamond" = 1000) + materials = list(DEFAULT_WALL_MATERIAL = 8000, "silver" = 2000, "diamond" = 1000) build_path = /obj/item/weapon/gun/projectile/automatic sort_string = "TAABA" /datum/design/item/weapon/ammo_9mm id = "ammo_9mm" req_tech = list(TECH_COMBAT = 4, TECH_MATERIAL = 3) - materials = list("metal" = 3750, "silver" = 100) + materials = list(DEFAULT_WALL_MATERIAL = 3750, "silver" = 100) build_path = /obj/item/ammo_magazine/c9mm sort_string = "TAACA" @@ -522,22 +522,22 @@ other types of metals and chemistry for reagents). desc = "A stunning shell for a shotgun." id = "stunshell" req_tech = list(TECH_COMBAT = 3, TECH_MATERIAL = 3) - materials = list("metal" = 4000) + materials = list(DEFAULT_WALL_MATERIAL = 4000) build_path = /obj/item/ammo_casing/shotgun/stunshell sort_string = "TAACB" /datum/design/item/weapon/chemsprayer desc = "An advanced chem spraying device." - id = "chemsprayer" + id = "chemsprayer" req_tech = list(TECH_MATERIAL = 3, TECH_ENGINEERING = 3, TECH_BIO = 2) - materials = list("metal" = 5000, "glass" = 1000) + materials = list(DEFAULT_WALL_MATERIAL = 5000, "glass" = 1000) build_path = /obj/item/weapon/reagent_containers/spray/chemsprayer sort_string = "TABAA" /datum/design/item/weapon/rapidsyringe - id = "rapidsyringe" + id = "rapidsyringe" req_tech = list(TECH_COMBAT = 3, TECH_MATERIAL = 3, TECH_ENGINEERING = 3, TECH_BIO = 2) - materials = list("metal" = 5000, "glass" = 1000) + materials = list(DEFAULT_WALL_MATERIAL = 5000, "glass" = 1000) build_path = /obj/item/weapon/gun/launcher/syringe/rapid sort_string = "TABAB" @@ -545,56 +545,56 @@ other types of metals and chemistry for reagents). desc = "A gun that shoots high-powered glass-encased energy temperature bullets." id = "temp_gun" req_tech = list(TECH_COMBAT = 3, TECH_MATERIAL = 4, TECH_POWER = 3, TECH_MAGNET = 2) - materials = list("metal" = 5000, "glass" = 500, "silver" = 3000) + materials = list(DEFAULT_WALL_MATERIAL = 5000, "glass" = 500, "silver" = 3000) build_path = /obj/item/weapon/gun/energy/temperature sort_string = "TABAC" /datum/design/item/weapon/large_grenade id = "large_Grenade" req_tech = list(TECH_COMBAT = 3, TECH_MATERIAL = 2) - materials = list("metal" = 3000) + materials = list(DEFAULT_WALL_MATERIAL = 3000) build_path = /obj/item/weapon/grenade/chem_grenade/large sort_string = "TACAA" /datum/design/item/weapon/flora_gun id = "flora_gun" req_tech = list(TECH_MATERIAL = 2, TECH_BIO = 3, TECH_POWER = 3) - materials = list("metal" = 2000, "glass" = 500, "uranium" = 500) + materials = list(DEFAULT_WALL_MATERIAL = 2000, "glass" = 500, "uranium" = 500) build_path = /obj/item/weapon/gun/energy/floragun sort_string = "TBAAA" /datum/design/item/stock_part/subspace_ansible id = "s-ansible" req_tech = list(TECH_DATA = 3, TECH_MAGNET = 4, TECH_MATERIAL = 4, TECH_BLUESPACE = 2) - materials = list("metal" = 80, "silver" = 20) + materials = list(DEFAULT_WALL_MATERIAL = 80, "silver" = 20) build_path = /obj/item/weapon/stock_parts/subspace/ansible sort_string = "UAAAA" /datum/design/item/stock_part/hyperwave_filter id = "s-filter" req_tech = list(TECH_DATA = 3, TECH_MAGNET = 3) - materials = list("metal" = 40, "silver" = 10) + materials = list(DEFAULT_WALL_MATERIAL = 40, "silver" = 10) build_path = /obj/item/weapon/stock_parts/subspace/filter sort_string = "UAAAB" /datum/design/item/stock_part/subspace_amplifier id = "s-amplifier" req_tech = list(TECH_DATA = 3, TECH_MAGNET = 4, TECH_MATERIAL = 4, TECH_BLUESPACE = 2) - materials = list("metal" = 10, "gold" = 30, "uranium" = 15) + materials = list(DEFAULT_WALL_MATERIAL = 10, "gold" = 30, "uranium" = 15) build_path = /obj/item/weapon/stock_parts/subspace/amplifier sort_string = "UAAAC" /datum/design/item/stock_part/subspace_treatment id = "s-treatment" req_tech = list(TECH_DATA = 3, TECH_MAGNET = 2, TECH_MATERIAL = 4, TECH_BLUESPACE = 2) - materials = list("metal" = 10, "silver" = 20) + materials = list(DEFAULT_WALL_MATERIAL = 10, "silver" = 20) build_path = /obj/item/weapon/stock_parts/subspace/treatment sort_string = "UAAAD" /datum/design/item/stock_part/subspace_analyzer id = "s-analyzer" req_tech = list(TECH_DATA = 3, TECH_MAGNET = 4, TECH_MATERIAL = 4, TECH_BLUESPACE = 2) - materials = list("metal" = 10, "gold" = 15) + materials = list(DEFAULT_WALL_MATERIAL = 10, "gold" = 15) build_path = /obj/item/weapon/stock_parts/subspace/analyzer sort_string = "UAAAE" @@ -617,7 +617,7 @@ other types of metals and chemistry for reagents). desc = "A device to automatically replace lights. Refill with working lightbulbs." id = "light_replacer" req_tech = list(TECH_MAGNET = 3, TECH_MATERIAL = 4) - materials = list("metal" = 1500, "silver" = 150, "glass" = 3000) + materials = list(DEFAULT_WALL_MATERIAL = 1500, "silver" = 150, "glass" = 3000) build_path = /obj/item/device/lightreplacer sort_string = "VAAAH" @@ -625,7 +625,7 @@ other types of metals and chemistry for reagents). name = "'pAI', personal artificial intelligence device" id = "paicard" req_tech = list(TECH_DATA = 2) - materials = list("glass" = 500, "metal" = 500) + materials = list("glass" = 500, DEFAULT_WALL_MATERIAL = 500) build_path = /obj/item/device/paicard sort_string = "VABAI" @@ -639,26 +639,31 @@ other types of metals and chemistry for reagents). sort_string = "VACAA" /datum/design/item/posibrain - id = "posibrain" + name = "Positronic brain" + id = "posibrain" req_tech = list(TECH_ENGINEERING = 4, TECH_MATERIAL = 6, TECH_BLUESPACE = 2, TECH_DATA = 4) - materials = list("metal" = 2000, "glass" = 1000, "silver" = 1000, "gold" = 500, "phoron" = 500, "diamond" = 100) + build_type = PROTOLATHE | MECHFAB + materials = list(DEFAULT_WALL_MATERIAL = 2000, "glass" = 1000, "silver" = 1000, "gold" = 500, "phoron" = 500, "diamond" = 100) build_path = /obj/item/device/mmi/digital/posibrain + category = "Misc" sort_string = "VACAB" -/datum/design/item/medical/mmi +/datum/design/item/mmi + name = "Man-machine interface" id = "mmi" req_tech = list(TECH_DATA = 2, TECH_BIO = 3) build_type = PROTOLATHE | MECHFAB - materials = list("metal" = 1000, "glass" = 500) + materials = list(DEFAULT_WALL_MATERIAL = 1000, "glass" = 500) build_path = /obj/item/device/mmi category = "Misc" sort_string = "VACBA" -/datum/design/item/medical/mmi_radio +/datum/design/item/mmi_radio + name = "Radio-enabled man-machine interface" id = "mmi_radio" req_tech = list(TECH_DATA = 2, TECH_BIO = 4) build_type = PROTOLATHE | MECHFAB - materials = list("metal" = 1200, "glass" = 500) + materials = list(DEFAULT_WALL_MATERIAL = 1200, "glass" = 500) build_path = /obj/item/device/mmi/radio_enabled category = "Misc" sort_string = "VACBB" @@ -667,7 +672,7 @@ other types of metals and chemistry for reagents). name = "Bluespace tracking beacon design" id = "beacon" req_tech = list(TECH_BLUESPACE = 1) - materials = list ("metal" = 20, "glass" = 10) + materials = list (DEFAULT_WALL_MATERIAL = 20, "glass" = 10) build_path = /obj/item/device/radio/beacon sort_string = "VADAA" @@ -685,7 +690,7 @@ other types of metals and chemistry for reagents). desc = "Allows for deciphering the binary channel on-the-fly." id = "binaryencrypt" req_tech = list(TECH_ILLEGAL = 2) - materials = list("metal" = 300, "glass" = 300) + materials = list(DEFAULT_WALL_MATERIAL = 300, "glass" = 300) build_path = /obj/item/device/encryptionkey/binary sort_string = "VASAA" @@ -694,7 +699,7 @@ other types of metals and chemistry for reagents). desc = "A kit of dangerous, high-tech equipment with changeable looks." id = "chameleon" req_tech = list(TECH_ILLEGAL = 2) - materials = list("metal" = 500) + materials = list(DEFAULT_WALL_MATERIAL = 500) build_path = /obj/item/weapon/storage/box/syndie_kit/chameleon sort_string = "VASBA" @@ -1349,16 +1354,16 @@ CIRCUITS BELOW /datum/design/item/pda name = "PDA design" desc = "Cheaper than whiny non-digital assistants." - id = "pda" + id = "pda" req_tech = list(TECH_ENGINEERING = 2, TECH_POWER = 3) - materials = list("metal" = 50, "glass" = 50) + materials = list(DEFAULT_WALL_MATERIAL = 50, "glass" = 50) build_path = /obj/item/device/pda sort_string = "VAAAA" // Cartridges -/datum/design/item/pda_cartridge +/datum/design/item/pda_cartridge req_tech = list(TECH_ENGINEERING = 2, TECH_POWER = 3) - materials = list("metal" = 50, "glass" = 50) + materials = list(DEFAULT_WALL_MATERIAL = 50, "glass" = 50) /datum/design/item/pda_cartridge/AssembleDesignName() ..() @@ -1438,155 +1443,7 @@ CIRCUITS BELOW id = "cart_captain" build_path = /obj/item/weapon/cartridge/captain sort_string = "VBAAO" - -/* -MECHAS BELOW -*/ - -/datum/design/item/mecha - build_type = MECHFAB - req_tech = list(TECH_COMBAT = 3) - category = "Exosuit Equipment" - -/datum/design/item/mecha/AssembleDesignName() - ..() - name = "Exosuit module design ([item_name])" - -/datum/design/item/mecha/weapon/AssembleDesignName() - ..() - name = "Exosuit weapon design ([item_name])" - -/datum/design/item/mecha/AssembleDesignDesc() - if(!desc) - desc = "Allows for the construction of \a '[item_name]' exosuit module." - -// *** Weapon modules -/datum/design/item/mecha/weapon/scattershot - id = "mech_scattershot" - req_tech = list(TECH_COMBAT = 4) - build_path = /obj/item/mecha_parts/mecha_equipment/weapon/ballistic/scattershot - -/datum/design/item/mecha/weapon/laser - id = "mech_laser" - req_tech = list(TECH_COMBAT = 3, TECH_MAGNET = 3) - build_path = /obj/item/mecha_parts/mecha_equipment/weapon/energy/laser - -/datum/design/item/mecha/weapon/laser_rigged - desc = "Allows for the construction of a welder-laser assembly package for non-combat exosuits." - id = "mech_laser_rigged" - req_tech = list(TECH_COMBAT = 2, TECH_MAGNET = 2) - build_path = /obj/item/mecha_parts/mecha_equipment/weapon/energy/riggedlaser - -/datum/design/item/mecha/weapon/laser_heavy - id = "mech_laser_heavy" - req_tech = list(TECH_COMBAT = 4, TECH_MAGNET = 4) - build_path = /obj/item/mecha_parts/mecha_equipment/weapon/energy/laser/heavy - -/datum/design/item/mecha/weapon/ion - id = "mech_ion" - req_tech = list(TECH_COMBAT = 4, TECH_MAGNET = 4) - build_path = /obj/item/mecha_parts/mecha_equipment/weapon/energy/ion - -/datum/design/item/mecha/weapon/grenade_launcher - id = "mech_grenade_launcher" - req_tech = list(TECH_COMBAT = 3) - build_path = /obj/item/mecha_parts/mecha_equipment/weapon/ballistic/missile_rack/flashbang - -/datum/design/item/mecha/weapon/clusterbang_launcher - desc = "A weapon that violates the Geneva Convention at 6 rounds per minute." - id = "clusterbang_launcher" - req_tech = list(TECH_COMBAT= 5, TECH_MATERIAL = 5, TECH_ILLEGAL = 3) - build_path = /obj/item/mecha_parts/mecha_equipment/weapon/ballistic/missile_rack/flashbang/clusterbang/limited - -// *** Nonweapon modules -/datum/design/item/mecha/wormhole_gen - desc = "An exosuit module that can generate small quasi-stable wormholes." - id = "mech_wormhole_gen" - req_tech = list(TECH_BLUESPACE = 3, TECH_MAGNET = 2) - build_path = /obj/item/mecha_parts/mecha_equipment/wormhole_generator - -/datum/design/item/mecha/teleporter - desc = "An exosuit module that allows teleportation to any position in view." - id = "mech_teleporter" - req_tech = list(TECH_BLUESPACE = 10, TECH_MAGNET = 5) - build_path = /obj/item/mecha_parts/mecha_equipment/teleporter - -/datum/design/item/mecha/rcd - desc = "An exosuit-mounted rapid construction device." - id = "mech_rcd" - req_tech = list(TECH_MATERIAL = 4, TECH_BLUESPACE = 3, TECH_MAGNET = 4, TECH_POWER=4, TECH_ENGINEERING = 4) - build_path = /obj/item/mecha_parts/mecha_equipment/tool/rcd - -/datum/design/item/mecha/gravcatapult - desc = "An exosuit-mounted gravitational catapult." - id = "mech_gravcatapult" - req_tech = list(TECH_BLUESPACE = 2, TECH_MAGNET = 3, TECH_ENGINEERING = 3) - build_path = /obj/item/mecha_parts/mecha_equipment/gravcatapult - -/datum/design/item/mecha/repair_droid - desc = "Automated repair droid, exosuits' best companion. BEEP BOOP" - id = "mech_repair_droid" - req_tech = list(TECH_MAGNET = 3, TECH_DATA = 3, TECH_ENGINEERING = 3) - build_path = /obj/item/mecha_parts/mecha_equipment/repair_droid - -/datum/design/item/mecha/phoron_generator - desc = "Exosuit-mounted phoron generator." - id = "mech_phoron_generator" - req_tech = list(TECH_PHORON = 2, TECH_POWER= 2, TECH_ENGINEERING = 2) - build_path = /obj/item/mecha_parts/mecha_equipment/generator - -/datum/design/item/mecha/energy_relay - id = "mech_energy_relay" - req_tech = list(TECH_MAGNET = 4, TECH_POWER = 3) - build_path = /obj/item/mecha_parts/mecha_equipment/tesla_energy_relay - -/datum/design/item/mecha/ccw_armor - desc = "Exosuit close-combat armor booster." - id = "mech_ccw_armor" - req_tech = list(TECH_MATERIAL = 5, TECH_COMBAT = 4) - build_path = /obj/item/mecha_parts/mecha_equipment/anticcw_armor_booster - -/datum/design/item/mecha/proj_armor - desc = "Exosuit projectile armor booster." - id = "mech_proj_armor" - req_tech = list(TECH_MATERIAL = 5, TECH_COMBAT = 5, TECH_ENGINEERING=3) - build_path = /obj/item/mecha_parts/mecha_equipment/antiproj_armor_booster - -/datum/design/item/mecha/syringe_gun - desc = "Exosuit-mounted syringe gun and chemical synthesizer." - id = "mech_syringe_gun" - req_tech = list(TECH_MATERIAL = 3, TECH_BIO=4, TECH_MAGNET=4, TECH_DATA=3) - build_path = /obj/item/mecha_parts/mecha_equipment/tool/syringe_gun - -/datum/design/item/mecha/diamond_drill - desc = "A diamond version of the exosuit drill. It's harder, better, faster, stronger." - id = "mech_diamond_drill" - req_tech = list(TECH_MATERIAL = 4, TECH_ENGINEERING = 3) - build_path = /obj/item/mecha_parts/mecha_equipment/tool/drill/diamonddrill - -/datum/design/item/mecha/generator_nuclear - desc = "Exosuit-held nuclear reactor. Converts uranium and everyone's health to energy." - id = "mech_generator_nuclear" - req_tech = list(TECH_POWER= 3, TECH_ENGINEERING = 3, TECH_MATERIAL = 3) - build_path = /obj/item/mecha_parts/mecha_equipment/generator/nuclear - -/datum/design/item/synthetic_flash - id = "sflash" - req_tech = list(TECH_MAGNET = 3, TECH_COMBAT = 2) - build_type = MECHFAB - materials = list("metal" = 750, "glass" = 750) - build_path = /obj/item/device/flash/synthetic - category = "Misc" - -/datum/design/item/borg_syndicate_module - name = "Cyborg lethal weapons upgrade" - desc = "Allows for the construction of lethal upgrades for cyborgs." - id = "borg_syndicate_module" - build_type = MECHFAB - req_tech = list(TECH_COMBAT = 4, TECH_ILLEGAL = 3) - build_path = /obj/item/borg/upgrade/syndicate - category = "Cyborg Upgrade Modules" - + /* Uncomment if someone makes these buildable /datum/design/circuit/general_alert name = "general alert console" @@ -1598,7 +1455,7 @@ MECHAS BELOW name = "loyalty" id = "implant_loyal" req_tech = list(TECH_MATERIAL = 2, TECH_BIO = 3) - materials = list("metal" = 7000, "glass" = 7000) + materials = list(DEFAULT_WALL_MATERIAL = 7000, "glass" = 7000) build_path = /obj/item/weapon/implantcase/loyalty" /datum/design/rust_core_control diff --git a/code/modules/research/mechfab_designs.dm b/code/modules/research/mechfab_designs.dm new file mode 100644 index 0000000000..cfdce572b1 --- /dev/null +++ b/code/modules/research/mechfab_designs.dm @@ -0,0 +1,589 @@ +/datum/design/item/mechfab + build_type = MECHFAB + category = "Misc" + req_tech = list(TECH_MATERIAL = 1) + +/datum/design/item/mechfab/robot + category = "Robot" + +/datum/design/item/mechfab/robot/exoskeleton + name = "Robot exoskeleton" + id = "robot_exoskeleton" + build_path = /obj/item/robot_parts/robot_suit + time = 50 + materials = list(DEFAULT_WALL_MATERIAL = 50000) + +/datum/design/item/mechfab/robot/torso + name = "Robot torso" + id = "robot_torso" + build_path = /obj/item/robot_parts/chest + time = 35 + materials = list(DEFAULT_WALL_MATERIAL = 40000) + +/datum/design/item/mechfab/robot/head + name = "Robot head" + id = "robot_head" + build_path = /obj/item/robot_parts/head + time = 35 + materials = list(DEFAULT_WALL_MATERIAL = 25000) + +/datum/design/item/mechfab/robot/l_arm + name = "Robot left arm" + id = "robot_l_arm" + build_path = /obj/item/robot_parts/l_arm + time = 20 + materials = list(DEFAULT_WALL_MATERIAL = 18000) + +/datum/design/item/mechfab/robot/r_arm + name = "Robot right arm" + id = "robot_r_arm" + build_path = /obj/item/robot_parts/r_arm + time = 20 + materials = list(DEFAULT_WALL_MATERIAL = 18000) + +/datum/design/item/mechfab/robot/l_leg + name = "Robot left leg" + id = "robot_l_leg" + build_path = /obj/item/robot_parts/l_leg + time = 20 + materials = list(DEFAULT_WALL_MATERIAL = 15000) + +/datum/design/item/mechfab/robot/r_leg + name = "Robot right leg" + id = "robot_r_leg" + build_path = /obj/item/robot_parts/r_leg + time = 20 + materials = list(DEFAULT_WALL_MATERIAL = 15000) + +/datum/design/item/mechfab/robot/component + time = 20 + materials = list(DEFAULT_WALL_MATERIAL = 5000) + +/datum/design/item/mechfab/robot/component/binary_communication_device + name = "Binary communication device" + id = "binary_communication_device" + build_path = /obj/item/robot_parts/robot_component/binary_communication_device + +/datum/design/item/mechfab/robot/component/radio + name = "Radio" + id = "radio" + build_path = /obj/item/robot_parts/robot_component/radio + +/datum/design/item/mechfab/robot/component/actuator + name = "Actuator" + id = "actuator" + build_path = /obj/item/robot_parts/robot_component/actuator + +/datum/design/item/mechfab/robot/component/diagnosis_unit + name = "Diagnosis unit" + id = "diagnosis_unit" + build_path = /obj/item/robot_parts/robot_component/diagnosis_unit + +/datum/design/item/mechfab/robot/component/camera + name = "Camera" + id = "camera" + build_path = /obj/item/robot_parts/robot_component/camera + +/datum/design/item/mechfab/robot/component/armour + name = "Armour plating" + id = "armour" + build_path = /obj/item/robot_parts/robot_component/armour + +/datum/design/item/mechfab/ripley + category = "Ripley" + +/datum/design/item/mechfab/ripley/chassis + name = "Ripley chassis" + id = "ripley_chassis" + build_path = /obj/item/mecha_parts/chassis/ripley + time = 10 + materials = list(DEFAULT_WALL_MATERIAL = 20000) + +/datum/design/item/mechfab/ripley/chassis/firefighter + name = "Firefigher chassis" + id = "firefighter_chassis" + build_path = /obj/item/mecha_parts/chassis/firefighter + +/datum/design/item/mechfab/ripley/torso + name = "Ripley torso" + id = "ripley_torso" + build_path = /obj/item/mecha_parts/part/ripley_torso + time = 20 + materials = list(DEFAULT_WALL_MATERIAL = 40000, "glass" = 15000) + +/datum/design/item/mechfab/ripley/left_arm + name = "Ripley left arm" + id = "ripley_left_arm" + build_path = /obj/item/mecha_parts/part/ripley_left_arm + time = 15 + materials = list(DEFAULT_WALL_MATERIAL = 25000) + +/datum/design/item/mechfab/ripley/right_arm + name = "Ripley right arm" + id = "ripley_right_arm" + build_path = /obj/item/mecha_parts/part/ripley_right_arm + time = 15 + materials = list(DEFAULT_WALL_MATERIAL = 25000) + +/datum/design/item/mechfab/ripley/left_leg + name = "Ripley left leg" + id = "ripley_left_leg" + build_path = /obj/item/mecha_parts/part/ripley_left_leg + time = 15 + materials = list(DEFAULT_WALL_MATERIAL = 30000) + +/datum/design/item/mechfab/ripley/right_leg + name = "Ripley right leg" + id = "ripley_right_leg" + build_path = /obj/item/mecha_parts/part/ripley_right_leg + time = 15 + materials = list(DEFAULT_WALL_MATERIAL = 30000) + +/datum/design/item/mechfab/odysseus + category = "Odysseus" + +/datum/design/item/mechfab/odysseus/chassis + name = "Odysseus chassis" + id = "odysseus_chassis" + build_path = /obj/item/mecha_parts/chassis/odysseus + time = 10 + materials = list(DEFAULT_WALL_MATERIAL = 20000) + +/datum/design/item/mechfab/odysseus/torso + name = "Odysseus torso" + id = "odysseus_torso" + build_path = /obj/item/mecha_parts/part/odysseus_torso + time = 18 + materials = list(DEFAULT_WALL_MATERIAL = 25000) + +/datum/design/item/mechfab/odysseus/head + name = "Odysseus head" + id = "odysseus_head" + build_path = /obj/item/mecha_parts/part/odysseus_head + time = 10 + materials = list(DEFAULT_WALL_MATERIAL = 2000, "glass" = 10000) + +/datum/design/item/mechfab/odysseus/left_arm + name = "Odysseus left arm" + id = "odysseus_left_arm" + build_path = /obj/item/mecha_parts/part/odysseus_left_arm + time = 12 + materials = list(DEFAULT_WALL_MATERIAL = 10000) + +/datum/design/item/mechfab/odysseus/right_arm + name = "Odysseus right arm" + id = "odysseus_right_arm" + build_path = /obj/item/mecha_parts/part/odysseus_right_arm + time = 12 + materials = list(DEFAULT_WALL_MATERIAL = 10000) + +/datum/design/item/mechfab/odysseus/left_leg + name = "Odysseus left leg" + id = "odysseus_left_leg" + build_path = /obj/item/mecha_parts/part/odysseus_left_leg + time = 13 + materials = list(DEFAULT_WALL_MATERIAL = 15000) + +/datum/design/item/mechfab/odysseus/right_leg + name = "Odysseus right leg" + id = "odysseus_right_leg" + build_path = /obj/item/mecha_parts/part/odysseus_right_leg + time = 13 + materials = list(DEFAULT_WALL_MATERIAL = 15000) + +/datum/design/item/mechfab/gygax + category = "Gygax" + +/datum/design/item/mechfab/gygax/chassis + name = "Gygax chassis" + id = "gygax_chassis" + build_path = /obj/item/mecha_parts/chassis/gygax + time = 10 + materials = list(DEFAULT_WALL_MATERIAL = 25000) + +/datum/design/item/mechfab/gygax/torso + name = "Gygax torso" + id = "gygax_torso" + build_path = /obj/item/mecha_parts/part/gygax_torso + time = 30 + materials = list(DEFAULT_WALL_MATERIAL = 50000, "glass" = 20000) + +/datum/design/item/mechfab/gygax/head + name = "Gygax head" + id = "gygax_head" + build_path = /obj/item/mecha_parts/part/gygax_head + time = 20 + materials = list(DEFAULT_WALL_MATERIAL = 20000, "glass" = 10000) + +/datum/design/item/mechfab/gygax/left_arm + name = "Gygax left arm" + id = "gygax_left_arm" + build_path = /obj/item/mecha_parts/part/gygax_left_arm + time = 20 + materials = list(DEFAULT_WALL_MATERIAL = 30000) + +/datum/design/item/mechfab/gygax/right_arm + name = "Gygax right arm" + id = "gygax_right_arm" + build_path = /obj/item/mecha_parts/part/gygax_right_arm + time = 20 + materials = list(DEFAULT_WALL_MATERIAL = 30000) + +/datum/design/item/mechfab/gygax/left_leg + name = "Gygax left leg" + id = "gygax_left_leg" + build_path = /obj/item/mecha_parts/part/gygax_left_leg + time = 20 + materials = list(DEFAULT_WALL_MATERIAL = 35000) + +/datum/design/item/mechfab/gygax/right_leg + name = "Gygax right leg" + id = "gygax_right_leg" + build_path = /obj/item/mecha_parts/part/gygax_right_leg + time = 20 + materials = list(DEFAULT_WALL_MATERIAL = 35000) + +/datum/design/item/mechfab/gygax/armour + name = "Gygax armour plates" + id = "gygax_armour" + build_path = /obj/item/mecha_parts/part/gygax_armour + time = 60 + materials = list(DEFAULT_WALL_MATERIAL = 50000, "diamond" = 10000) + +/datum/design/item/mechfab/durand + category = "Durand" + +/datum/design/item/mechfab/durand/chassis + name = "Durand chassis" + id = "durand_chassis" + build_path = /obj/item/mecha_parts/chassis/durand + time = 10 + materials = list(DEFAULT_WALL_MATERIAL = 25000) + +/datum/design/item/mechfab/durand/torso + name = "Durand torso" + id = "durand_torso" + build_path = /obj/item/mecha_parts/part/durand_torso + time = 30 + materials = list(DEFAULT_WALL_MATERIAL = 55000, "glass" = 20000, "silver" = 10000) + +/datum/design/item/mechfab/durand/head + name = "Durand head" + id = "durand_head" + build_path = /obj/item/mecha_parts/part/durand_head + time = 20 + materials = list(DEFAULT_WALL_MATERIAL = 25000, "glass" = 10000, "silver" = 3000) + +/datum/design/item/mechfab/durand/left_arm + name = "Durand left arm" + id = "durand_left_arm" + build_path = /obj/item/mecha_parts/part/durand_left_arm + time = 20 + materials = list(DEFAULT_WALL_MATERIAL = 35000, "silver" = 3000) + +/datum/design/item/mechfab/durand/right_arm + name = "Durand right arm" + id = "durand_right_arm" + build_path = /obj/item/mecha_parts/part/durand_right_arm + time = 20 + materials = list(DEFAULT_WALL_MATERIAL = 35000, "silver" = 3000) + +/datum/design/item/mechfab/durand/left_leg + name = "Durand left leg" + id = "durand_left_leg" + build_path = /obj/item/mecha_parts/part/durand_left_leg + time = 20 + materials = list(DEFAULT_WALL_MATERIAL = 40000, "silver" = 3000) + +/datum/design/item/mechfab/durand/right_leg + name = "Durand right leg" + id = "durand_right_leg" + build_path = /obj/item/mecha_parts/part/durand_right_leg + time = 20 + materials = list(DEFAULT_WALL_MATERIAL = 40000, "silver" = 3000) + +/datum/design/item/mechfab/durand/armour + name = "Durand armour plates" + id = "durand_armour" + build_path = /obj/item/mecha_parts/part/durand_armour + time = 60 + materials = list(DEFAULT_WALL_MATERIAL = 50000, "uranium" = 10000) + +/datum/design/item/robot_upgrade + build_type = MECHFAB + time = 12 + materials = list(DEFAULT_WALL_MATERIAL = 10000) + category = "Cyborg Upgrade Modules" + +/datum/design/item/robot_upgrade/rename + name = "Rename module" + desc = "Used to rename a cyborg." + id = "borg_rename_module" + build_path = /obj/item/borg/upgrade/rename + +/datum/design/item/robot_upgrade/reset + name = "Reset module" + desc = "Used to reset a cyborg's module. Destroys any other upgrades applied to the robot." + id = "borg_reset_module" + build_path = /obj/item/borg/upgrade/reset + +/datum/design/item/robot_upgrade/restart + name = "Emergency restart module" + desc = "Used to force a restart of a disabled-but-repaired robot, bringing it back online." + id = "borg_restart_module" + materials = list(DEFAULT_WALL_MATERIAL = 60000, "glass" = 5000) + build_path = /obj/item/borg/upgrade/restart + +/datum/design/item/robot_upgrade/vtec + name = "VTEC module" + desc = "Used to kick in a robot's VTEC systems, increasing their speed." + id = "borg_vtec_module" + materials = list(DEFAULT_WALL_MATERIAL = 80000, "glass" = 6000, "gold" = 5000) + build_path = /obj/item/borg/upgrade/vtec + +/datum/design/item/robot_upgrade/tasercooler + name = "Rapid taser cooling module" + desc = "Used to cool a mounted taser, increasing the potential current in it and thus its recharge rate." + id = "borg_taser_module" + materials = list(DEFAULT_WALL_MATERIAL = 80000, "glass" = 6000, "gold" = 2000, "diamond" = 500) + build_path = /obj/item/borg/upgrade/tasercooler + +/datum/design/item/robot_upgrade/jetpack + name = "Jetpack module" + desc = "A carbon dioxide jetpack suitable for low-gravity mining operations." + id = "borg_jetpack_module" + materials = list(DEFAULT_WALL_MATERIAL = 10000, "phoron" = 15000, "uranium" = 20000) + build_path = /obj/item/borg/upgrade/jetpack + +/datum/design/item/robot_upgrade/syndicate + name = "Illegal upgrade" + desc = "Allows for the construction of lethal upgrades for cyborgs." + id = "borg_syndicate_module" + req_tech = list(TECH_COMBAT = 4, TECH_ILLEGAL = 3) + materials = list(DEFAULT_WALL_MATERIAL = 10000, "glass" = 15000, "diamond" = 10000) + build_path = /obj/item/borg/upgrade/syndicate + +/datum/design/item/mecha_tracking + name = "Exosuit tracking beacon" + build_type = MECHFAB + time = 5 + materials = list(DEFAULT_WALL_MATERIAL = 500) + build_path = /obj/item/mecha_parts/mecha_tracking + category = "Misc" + +/datum/design/item/mecha + build_type = MECHFAB + category = "Exosuit Equipment" + time = 10 + materials = list(DEFAULT_WALL_MATERIAL = 10000) + +/datum/design/item/mecha/AssembleDesignDesc() + if(!desc) + desc = "Allows for the construction of \a '[item_name]' exosuit module." + +/datum/design/item/mecha/hydraulic_clamp + name = "Hydraulic clamp" + id = "hydraulic_clamp" + build_path = /obj/item/mecha_parts/mecha_equipment/tool/hydraulic_clamp + +/datum/design/item/mecha/drill + name = "Drill" + id = "drill" + build_path = /obj/item/mecha_parts/mecha_equipment/tool/drill + +/datum/design/item/mecha/extinguisher + name = "Extinguisher" + id = "extinguisher" + build_path = /obj/item/mecha_parts/mecha_equipment/tool/extinguisher + +/datum/design/item/mecha/cable_layer + name = "Cable layer" + id = "mech_cable_layer" + build_path = /obj/item/mecha_parts/mecha_equipment/tool/cable_layer + +/datum/design/item/mecha/sleeper + name = "Sleeper" + id = "mech_sleeper" + build_path = /obj/item/mecha_parts/mecha_equipment/tool/sleeper + materials = list(DEFAULT_WALL_MATERIAL = 5000, "glass" = 10000) + +/datum/design/item/mecha/syringe_gun + name = "Syringe gun" + id = "mech_syringe_gun" + build_path = /obj/item/mecha_parts/mecha_equipment/tool/syringe_gun + time = 20 + materials = list(DEFAULT_WALL_MATERIAL = 3000, "glass" = 2000) + +/* +/datum/design/item/mecha/syringe_gun + desc = "Exosuit-mounted syringe gun and chemical synthesizer." + id = "mech_syringe_gun" + req_tech = list(TECH_MATERIAL = 3, TECH_BIO = 4, TECH_MAGNET = 4, TECH_DATA = 3) + build_path = /obj/item/mecha_parts/mecha_equipment/tool/syringe_gun + */ + +/datum/design/item/mecha/passenger + name = "Passenger compartment" + id = "mech_passenger" + build_path = /obj/item/mecha_parts/mecha_equipment/tool/passenger + materials = list(DEFAULT_WALL_MATERIAL = 5000, "glass" = 5000) + +//obj/item/mecha_parts/mecha_equipment/repair_droid, +//obj/item/mecha_parts/mecha_equipment/jetpack, //TODO MECHA JETPACK SPRITE MISSING + +/datum/design/item/mecha/generator + name = "Phoron generator" + id = "mech_generator" + build_path = /obj/item/mecha_parts/mecha_equipment/generator + +/datum/design/item/mecha/taser + name = "PBT \"Pacifier\" mounted taser" + id = "mech_taser" + build_path = /obj/item/mecha_parts/mecha_equipment/weapon/energy/taser + +/datum/design/item/mecha/lmg + name = "Ultra AC 2" + id = "mech_lmg" + build_path = /obj/item/mecha_parts/mecha_equipment/weapon/ballistic/lmg + +/datum/design/item/mecha/weapon + req_tech = list(TECH_COMBAT = 3) + +// *** Weapon modules +/datum/design/item/mecha/weapon/scattershot + name = "LBX AC 10 \"Scattershot\"" + id = "mech_scattershot" + req_tech = list(TECH_COMBAT = 4) + build_path = /obj/item/mecha_parts/mecha_equipment/weapon/ballistic/scattershot + +/datum/design/item/mecha/weapon/laser + name = "CH-PS \"Immolator\" laser" + id = "mech_laser" + req_tech = list(TECH_COMBAT = 3, TECH_MAGNET = 3) + build_path = /obj/item/mecha_parts/mecha_equipment/weapon/energy/laser + +/datum/design/item/mecha/weapon/laser_rigged + name = "Jury-rigged welder-laser" + desc = "Allows for the construction of a welder-laser assembly package for non-combat exosuits." + id = "mech_laser_rigged" + req_tech = list(TECH_COMBAT = 2, TECH_MAGNET = 2) + build_path = /obj/item/mecha_parts/mecha_equipment/weapon/energy/riggedlaser + +/datum/design/item/mecha/weapon/laser_heavy + name = "CH-LC \"Solaris\" laser cannon" + id = "mech_laser_heavy" + req_tech = list(TECH_COMBAT = 4, TECH_MAGNET = 4) + build_path = /obj/item/mecha_parts/mecha_equipment/weapon/energy/laser/heavy + +/datum/design/item/mecha/weapon/ion + name = "mkIV ion heavy cannon" + id = "mech_ion" + req_tech = list(TECH_COMBAT = 4, TECH_MAGNET = 4) + build_path = /obj/item/mecha_parts/mecha_equipment/weapon/energy/ion + +/datum/design/item/mecha/weapon/grenade_launcher + name = "SGL-6 grenade launcher" + id = "mech_grenade_launcher" + req_tech = list(TECH_COMBAT = 3) + build_path = /obj/item/mecha_parts/mecha_equipment/weapon/ballistic/missile_rack/flashbang + +/datum/design/item/mecha/weapon/clusterbang_launcher + name = "SOP-6 grenade launcher" + desc = "A weapon that violates the Geneva Convention at 6 rounds per minute." + id = "clusterbang_launcher" + req_tech = list(TECH_COMBAT= 5, TECH_MATERIAL = 5, TECH_ILLEGAL = 3) + materials = list(DEFAULT_WALL_MATERIAL = 20000, "gold" = 6000, "uranium" = 6000) + build_path = /obj/item/mecha_parts/mecha_equipment/weapon/ballistic/missile_rack/flashbang/clusterbang/limited + +// *** Nonweapon modules +/datum/design/item/mecha/wormhole_gen + name = "Wormhole generator" + desc = "An exosuit module that can generate small quasi-stable wormholes." + id = "mech_wormhole_gen" + req_tech = list(TECH_BLUESPACE = 3, TECH_MAGNET = 2) + build_path = /obj/item/mecha_parts/mecha_equipment/wormhole_generator + +/datum/design/item/mecha/teleporter + name = "Teleporter" + desc = "An exosuit module that allows teleportation to any position in view." + id = "mech_teleporter" + req_tech = list(TECH_BLUESPACE = 10, TECH_MAGNET = 5) + build_path = /obj/item/mecha_parts/mecha_equipment/teleporter + +/datum/design/item/mecha/rcd + name = "RCD" + desc = "An exosuit-mounted rapid construction device." + id = "mech_rcd" + time = 120 + materials = list(DEFAULT_WALL_MATERIAL = 30000, "phoron" = 25000, "silver" = 20000, "gold" = 20000) + req_tech = list(TECH_MATERIAL = 4, TECH_BLUESPACE = 3, TECH_MAGNET = 4, TECH_POWER = 4, TECH_ENGINEERING = 4) + build_path = /obj/item/mecha_parts/mecha_equipment/tool/rcd + +/datum/design/item/mecha/gravcatapult + name = "Gravitational catapult" + desc = "An exosuit-mounted gravitational catapult." + id = "mech_gravcatapult" + req_tech = list(TECH_BLUESPACE = 2, TECH_MAGNET = 3, TECH_ENGINEERING = 3) + build_path = /obj/item/mecha_parts/mecha_equipment/gravcatapult + +/datum/design/item/mecha/repair_droid + name = "Repair droid" + desc = "Automated repair droid, exosuits' best companion. BEEP BOOP" + id = "mech_repair_droid" + req_tech = list(TECH_MAGNET = 3, TECH_DATA = 3, TECH_ENGINEERING = 3) + materials = list(DEFAULT_WALL_MATERIAL = 10000, "gold" = 1000, "silver" = 2000, "glass" = 5000) + build_path = /obj/item/mecha_parts/mecha_equipment/repair_droid + +/datum/design/item/mecha/phoron_generator + desc = "Phoron reactor." + id = "mech_phoron_generator" + req_tech = list(TECH_PHORON = 2, TECH_POWER= 2, TECH_ENGINEERING = 2) + build_path = /obj/item/mecha_parts/mecha_equipment/generator + materials = list(DEFAULT_WALL_MATERIAL = 10000, "silver" = 500, "glass" = 1000) + +/datum/design/item/mecha/energy_relay + name = "Energy relay" + id = "mech_energy_relay" + req_tech = list(TECH_MAGNET = 4, TECH_POWER = 3) + materials = list(DEFAULT_WALL_MATERIAL = 10000, "gold" = 2000, "silver" = 3000, "glass" = 2000) + build_path = /obj/item/mecha_parts/mecha_equipment/tesla_energy_relay + +/datum/design/item/mecha/ccw_armor + name = "CCW armor booster" + desc = "Exosuit close-combat armor booster." + id = "mech_ccw_armor" + req_tech = list(TECH_MATERIAL = 5, TECH_COMBAT = 4) + materials = list(DEFAULT_WALL_MATERIAL = 20000, "silver" = 5000) + build_path = /obj/item/mecha_parts/mecha_equipment/anticcw_armor_booster + +/datum/design/item/mecha/proj_armor + desc = "Exosuit projectile armor booster." + id = "mech_proj_armor" + req_tech = list(TECH_MATERIAL = 5, TECH_COMBAT = 5, TECH_ENGINEERING = 3) + materials = list(DEFAULT_WALL_MATERIAL = 20000, "gold" = 5000) + build_path = /obj/item/mecha_parts/mecha_equipment/antiproj_armor_booster + +/datum/design/item/mecha/diamond_drill + name = "Diamond drill" + desc = "A diamond version of the exosuit drill. It's harder, better, faster, stronger." + id = "mech_diamond_drill" + req_tech = list(TECH_MATERIAL = 4, TECH_ENGINEERING = 3) + materials = list(DEFAULT_WALL_MATERIAL = 10000, "diamond" = 6500) + build_path = /obj/item/mecha_parts/mecha_equipment/tool/drill/diamonddrill + +/datum/design/item/mecha/generator_nuclear + name = "Nuclear reactor" + desc = "Exosuit-held nuclear reactor. Converts uranium and everyone's health to energy." + id = "mech_generator_nuclear" + req_tech = list(TECH_POWER= 3, TECH_ENGINEERING = 3, TECH_MATERIAL = 3) + materials = list(DEFAULT_WALL_MATERIAL = 10000, "silver" = 500, "glass" = 1000) + build_path = /obj/item/mecha_parts/mecha_equipment/generator/nuclear + +/datum/design/item/synthetic_flash + name = "Synthetic flash" + id = "sflash" + req_tech = list(TECH_MAGNET = 3, TECH_COMBAT = 2) + build_type = MECHFAB + materials = list(DEFAULT_WALL_MATERIAL = 750, "glass" = 750) + build_path = /obj/item/device/flash/synthetic + category = "Misc" \ No newline at end of file diff --git a/code/modules/research/protolathe.dm b/code/modules/research/protolathe.dm index 5ff3d23c74..9cb029f58e 100644 --- a/code/modules/research/protolathe.dm +++ b/code/modules/research/protolathe.dm @@ -8,7 +8,7 @@ active_power_usage = 5000 var/max_material_storage = 100000 - var/list/materials = list("metal" = 0, "glass" = 0, "gold" = 0, "silver" = 0, "phoron" = 0, "uranium" = 0, "diamond" = 0) + var/list/materials = list(DEFAULT_WALL_MATERIAL = 0, "glass" = 0, "gold" = 0, "silver" = 0, "phoron" = 0, "uranium" = 0, "diamond" = 0) var/list/datum/design/queue = list() var/progress = 0 diff --git a/code/modules/research/rdmachines.dm b/code/modules/research/rdmachines.dm index 3f73929aad..031c82a958 100644 --- a/code/modules/research/rdmachines.dm +++ b/code/modules/research/rdmachines.dm @@ -16,7 +16,7 @@ /obj/machinery/r_n_d/proc/getMaterialType(var/name) switch(name) - if("metal") + if(DEFAULT_WALL_MATERIAL) return /obj/item/stack/material/steel if("glass") return /obj/item/stack/material/glass @@ -35,7 +35,7 @@ /obj/machinery/r_n_d/proc/getMaterialName(var/type) switch(type) if(/obj/item/stack/material/steel) - return "metal" + return DEFAULT_WALL_MATERIAL if(/obj/item/stack/material/glass) return "glass" if(/obj/item/stack/material/gold) diff --git a/code/modules/research/research.dm b/code/modules/research/research.dm index ae928749e2..8dc8a12263 100644 --- a/code/modules/research/research.dm +++ b/code/modules/research/research.dm @@ -98,7 +98,7 @@ research holder datum. var/datum/design/A = known_designs[i] if(A.id == D.id) // We are guaranteed to reach this if the ids are the same, because sort_string will also be the same return - if(A.sort_string >= D.sort_string) + if(A.sort_string > D.sort_string) known_designs.Insert(i, D) return known_designs.Add(D) diff --git a/html/changelogs/Kelenius-ofMechbabAndPanic.yml b/html/changelogs/Kelenius-ofMechbabAndPanic.yml new file mode 100644 index 0000000000..67f0c0806c --- /dev/null +++ b/html/changelogs/Kelenius-ofMechbabAndPanic.yml @@ -0,0 +1,6 @@ +author: Kelenius + +delete-after: True + +changes: + - tweak: "Mechfab can now be upgraded using RPED, and now uses NanoUI." diff --git a/maps/exodus-1.dmm b/maps/exodus-1.dmm index 2817a737ae..567252183f 100644 --- a/maps/exodus-1.dmm +++ b/maps/exodus-1.dmm @@ -7067,12 +7067,12 @@ "cFU" = (/obj/machinery/light/small,/obj/machinery/camera/network/engineering{c_tag = "Atmospherics Tank - Carbon Dioxide"; dir = 1},/turf/simulated/floor/reinforced/carbon_dioxide,/area/engineering/atmos) "cFV" = (/obj/machinery/light/small,/obj/machinery/camera/network/engineering{c_tag = "Atmospherics Tank - Phoron"; dir = 1},/turf/simulated/floor/reinforced/phoron,/area/engineering/atmos) "cFW" = (/obj/machinery/light/small,/obj/machinery/camera/network/engineering{c_tag = "Atmospherics Tank - Nitrous Oxide"; dir = 1},/turf/simulated/floor/reinforced/n20,/area/engineering/atmos) -"cFX" = (/obj/structure/grille,/obj/structure/window/reinforced,/obj/structure/window/reinforced{dir = 4},/obj/structure/window/reinforced{dir = 1},/turf/simulated/floor/plating,/area/engineering/drone_fabrication) +"cFX" = (/obj/structure/grille,/obj/structure/window/reinforced,/obj/structure/window/reinforced{dir = 4},/obj/structure/window/reinforced{dir = 1},/turf/simulated/floor/plating,/area/engineering/drone_fabrication) "cFY" = (/obj/structure/grille,/obj/structure/window/reinforced,/obj/structure/window/reinforced{dir = 8},/turf/simulated/floor/plating,/area/engineering/drone_fabrication) "cFZ" = (/obj/machinery/camera/network/engineering{c_tag = "Atmospherics Tank - Gas Mixing"; dir = 1},/turf/simulated/floor/reinforced/airless,/area/engineering/atmos) "cGa" = (/obj/machinery/computer/drone_control,/obj/effect/floor_decal/industrial/warning,/turf/simulated/floor/plating,/area/engineering/drone_fabrication) -"cGb" = (/obj/machinery/alarm{dir = 1; icon_state = "alarm0"; pixel_y = -22},/obj/machinery/light,/obj/machinery/mecha_part_fabricator{output_dir = 1},/obj/effect/floor_decal/industrial/warning{dir = 10},/turf/simulated/floor/plating,/area/engineering/drone_fabrication) -"cGc" = (/obj/machinery/light,/obj/machinery/power/apc{dir = 2; name = "south bump"; pixel_y = -24},/obj/structure/cable{icon_state = "0-4"; d2 = 4},/obj/machinery/power/sensor{name = "Powernet Sensor - Master Grid"; name_tag = "Master"},/obj/effect/floor_decal/industrial/warning{dir = 6},/turf/simulated/floor/plating,/area/engineering/drone_fabrication) +"cGb" = (/obj/machinery/alarm{dir = 1; icon_state = "alarm0"; pixel_y = -22},/obj/machinery/light,/obj/machinery/mecha_part_fabricator,/obj/effect/floor_decal/industrial/warning{dir = 10},/turf/simulated/floor/plating,/area/engineering/drone_fabrication) +"cGc" = (/obj/machinery/light,/obj/machinery/power/apc{dir = 2; name = "south bump"; pixel_y = -24},/obj/structure/cable{icon_state = "0-4"; d2 = 4},/obj/machinery/power/sensor{name = "Powernet Sensor - Master Grid"; name_tag = "Master"},/obj/effect/floor_decal/industrial/warning{dir = 6},/turf/simulated/floor/plating,/area/engineering/drone_fabrication) "cGd" = (/obj/structure/cable{d1 = 1; d2 = 8; icon_state = "1-8"},/obj/structure/cable{d1 = 1; d2 = 2; icon_state = "1-2"},/obj/machinery/atmospherics/pipe/simple/hidden/scrubbers,/obj/machinery/atmospherics/pipe/simple/hidden/supply,/turf/simulated/floor/plating,/area/engineering/drone_fabrication) "cGe" = (/obj/structure/bed/chair{dir = 8},/obj/effect/floor_decal/industrial/warning,/turf/simulated/floor/plating,/area/engineering/drone_fabrication) "cGf" = (/obj/machinery/power/smes/buildable{charge = 1e+007; cur_coils = 4; input_attempt = 1; input_level = 500000; output_level = 500000; RCon_tag = "Engine - Main"},/obj/structure/cable,/turf/simulated/floor/plating,/area/engineering/engine_smes) diff --git a/nano/templates/mechfab.tmpl b/nano/templates/mechfab.tmpl new file mode 100644 index 0000000000..8fcc82f877 --- /dev/null +++ b/nano/templates/mechfab.tmpl @@ -0,0 +1,81 @@ +

Exosuit Fabricator

+
+
+ {{:helper.link("Sync", null, {'sync' : 1})}} + {{:data.sync}} +
+ {{if data.manufacturers}} +
+ {{for data.manufacturers}} + {{:helper.link(value.company, null, {'manufacturer' : value.id}, value.id == data.manufacturer ? 'selected' : null)}} + {{/for}} +
+ {{/if}} +
+ {{for data.categories}} + {{:helper.link(value, null, {'category' : value}, value == data.category ? 'selected' : null)}} + {{empty}} + There are no known designs + {{/for}} +
+ {{for data.buildable}} + {{if value.category == data.category}} +
+
+ {{:helper.link(value.name, null, {'build' : value.id})}} +
+
+ {{:value.resourses}}, {{:value.time}} +
+
+ {{/if}} + {{/for}} +
+
+
+ Queue contains: +
+ {{if data.current}} +
+
+ Now: {{:data.current}} ({{:data.builtperc}}% ready) +
+
+ {{:helper.link('Cancel', null, {'remove' : 1})}} +
+
+ {{for data.queue}} +
+
+ {{:index + 2}}: {{:value}} +
+
+ {{:helper.link('Remove', null, {'remove' : index + 2})}} +
+ {{empty}} +
+ The queue is empty +
+ {{/for}} + {{else}} +
+ Nothing +
+ {{/if}} + Materials: + {{for data.materials}} +
+
+ {{:value.mat}}: {{:value.amt}}/{{:data.maxres}} +
+
+ {{:helper.link('x1', null, {'eject' : value.mat, 'amount' : 1}, value.amt > 2000 ? null : 'disabled')}} + {{:helper.link('x5', null, {'eject' : value.mat, 'amount' : 5}, value.amt > 10000 ? null : 'disabled')}} + {{:helper.link('x10', null, {'eject' : value.mat, 'amount' : 10}, value.amt > 20000 ? null : 'disabled')}} + {{:helper.link('Stack', null, {'eject' : value.mat, 'amount' : 0})}} + {{:helper.link('All', null, {'eject' : value.mat, 'amount' : -1})}} +
+
+ {{/for}} +
+