mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-10 10:12:45 +00:00
Adds new autolathe interface for testing before sending to polaris/virgo
This commit is contained in:
@@ -17,4 +17,5 @@
|
||||
#define PROTOLATHE 0x0002 //New stuff. Uses glass/metal/chemicals
|
||||
#define MECHFAB 0x0004 //Mechfab
|
||||
#define CHASSIS 0x0008 //For protolathe, but differently
|
||||
#define PROSFAB 0x0010 //For prosthetics fab
|
||||
#define PROSFAB 0x0010 //For prosthetics fab
|
||||
#define AUTOLATHE 0x0012
|
||||
272
code/datums/autolathe/arms_1.dm
Normal file
272
code/datums/autolathe/arms_1.dm
Normal file
@@ -0,0 +1,272 @@
|
||||
/datum/design/item/autolathe
|
||||
var/hidden = 0
|
||||
build_type = AUTOLATHE //Flag as to what kind machine the design is built in. See defines.
|
||||
|
||||
/datum/design/item/autolathe/arms //Datum for object designs, used in construction //IDs of that techs the object originated from and the minimum level requirements.
|
||||
category = "Arms and Ammunition" //category item goes to
|
||||
|
||||
|
||||
////////////////
|
||||
/*Ammo casings*/
|
||||
////////////////
|
||||
//Shotgun
|
||||
|
||||
/datum/design/item/autolathe/arms/shotgun_blanks
|
||||
name = "ammunition (12g, blank)"
|
||||
id = "shotgun_blanks"
|
||||
build_path = /obj/item/ammo_casing/a12g/blank
|
||||
time = 10
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 112)
|
||||
|
||||
/datum/design/item/autolathe/arms/shotgun_beanbag
|
||||
name = "ammunition (12g, beanbag)"
|
||||
id = "shotgun_beanbag"
|
||||
build_path = /obj/item/ammo_casing/a12g/beanbag
|
||||
time = 10
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 225)
|
||||
|
||||
/datum/design/item/autolathe/arms/shotgun_flash
|
||||
name = "ammunition (12g, flash)"
|
||||
id = "shotgun_flash"
|
||||
build_path = /obj/item/ammo_casing/a12g/flash
|
||||
time = 10
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 112, "glass" = 112)
|
||||
|
||||
/datum/design/item/autolathe/arms/shotgun_slug
|
||||
name = "ammunition (12g, slug)"
|
||||
id = "shotgun_slug"
|
||||
build_path = /obj/item/ammo_casing/a12g
|
||||
time = 10
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 450)
|
||||
hidden = 1
|
||||
|
||||
/datum/design/item/autolathe/arms/shotgun_pellet
|
||||
name = "ammunition (12g, pellet)"
|
||||
id = "shotgun_pellet"
|
||||
build_path = /obj/item/ammo_casing/a12g/pellet
|
||||
time = 10
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 450)
|
||||
hidden = 1
|
||||
|
||||
/datum/design/item/autolathe/arms/stunshell
|
||||
name = "ammunition (stun cartridge, shotgun)"
|
||||
id = "stunshell"
|
||||
build_path = /obj/item/ammo_casing/a12g/stunshell
|
||||
time = 10
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 450, "glass" = 900)
|
||||
hidden = 1
|
||||
|
||||
//////////////////
|
||||
/*Ammo magazines*/
|
||||
//////////////////
|
||||
|
||||
/////// .45
|
||||
/datum/design/item/autolathe/arms/pistol_45
|
||||
name = "pistol magazine (.45)"
|
||||
id = "pistol_45"
|
||||
build_path = /obj/item/ammo_magazine/m45
|
||||
time = 10
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 656)
|
||||
hidden = 1
|
||||
|
||||
/datum/design/item/autolathe/arms/pistol_45p
|
||||
name = "pistol magazine (.45 practice)"
|
||||
id = "pistol_45p"
|
||||
build_path = /obj/item/ammo_magazine/m45/practice
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 656)
|
||||
|
||||
|
||||
/datum/design/item/autolathe/arms/pistol_45r
|
||||
name = "pistol magazine (.45 rubber)"
|
||||
id = "pistol_45r"
|
||||
build_path = /obj/item/ammo_magazine/m45/rubber
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 656)
|
||||
|
||||
/datum/design/item/autolathe/arms/pistol_45f
|
||||
name = "pistol magazine (.45 flash)"
|
||||
id = "pistol_45f"
|
||||
build_path = /obj/item/ammo_magazine/m45/flash
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 656)
|
||||
|
||||
/datum/design/item/autolathe/arms/tommymag
|
||||
name = "Tommy Gun magazine (.45)"
|
||||
id = "tommymag"
|
||||
build_path = /obj/item/ammo_magazine/m45tommy
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 1875)
|
||||
hidden = 1
|
||||
|
||||
/datum/design/item/autolathe/arms/tommydrum
|
||||
name = "Tommy Gun drum magazine (.45)"
|
||||
id = "tommydrum"
|
||||
build_path = /obj/item/ammo_magazine/m45tommydrum
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 4687)
|
||||
hidden = 1
|
||||
|
||||
/////// 9mm
|
||||
|
||||
// Full size pistol mags.
|
||||
|
||||
/datum/design/item/autolathe/arms/pistol_9mm
|
||||
name = "pistol magazine (9mm)"
|
||||
id = "pistol_9mm"
|
||||
build_path = /obj/item/ammo_magazine/m9mm
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 750)
|
||||
hidden = 1
|
||||
|
||||
/datum/design/item/autolathe/arms/pistol_9mmr
|
||||
name = "pistol magazine (9mm rubber)"
|
||||
id = "pistol_9mm_rubber"
|
||||
build_path = /obj/item/ammo_magazine/m9mm/rubber
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 750)
|
||||
|
||||
|
||||
/datum/design/item/autolathe/arms/pistol_9mmp
|
||||
name = "pistol magazine (9mm practice)"
|
||||
id = "pistol_9mm_rubber"
|
||||
build_path = /obj/item/ammo_magazine/m9mm/practice
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 750)
|
||||
|
||||
/datum/design/item/autolathe/arms/pistol_9mmf
|
||||
name = "pistol magazine (9mm flash)"
|
||||
id = "pistol_9mm_flash"
|
||||
build_path = /obj/item/ammo_magazine/m9mm/flash
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 750)
|
||||
|
||||
/////// 10mm
|
||||
|
||||
/datum/design/item/autolathe/arms/smg_10mm
|
||||
name = "SMG magazine (10mm)"
|
||||
id = "smg_10mm"
|
||||
build_path = /obj/item/ammo_magazine/m10mm
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 1875)
|
||||
|
||||
/datum/design/item/autolathe/arms/pistol_44
|
||||
name = "pistol magazine (.44)"
|
||||
id = "pistol_44"
|
||||
build_path = /obj/item/ammo_magazine/m44
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 1575)
|
||||
|
||||
/////// 5.45mm
|
||||
/datum/design/item/autolathe/arms/rifle_545
|
||||
name = "rifle magazine (5.45mm)"
|
||||
id = "rifle_545"
|
||||
build_path = /obj/item/ammo_magazine/m545
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 2250)
|
||||
hidden = 1
|
||||
|
||||
/datum/design/item/autolathe/arms/rifle_545p
|
||||
name = "rifle magazine (5.45mm practice)"
|
||||
id = "rifle_545_practice"
|
||||
build_path = /obj/item/ammo_magazine/m545/practice
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 2250)
|
||||
|
||||
/datum/design/item/autolathe/arms/machinegun_545
|
||||
name = "machinegun box magazine (5.45)"
|
||||
id = "machinegun_545"
|
||||
build_path = /obj/item/ammo_magazine/m545saw
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 12500)
|
||||
hidden = 1
|
||||
|
||||
/////// 7.62
|
||||
|
||||
/datum/design/item/autolathe/arms/rifle_762
|
||||
name = "rifle magazine (7.62mm)"
|
||||
id = "rifle_762"
|
||||
build_path = /obj/item/ammo_magazine/m762
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 2500)
|
||||
hidden = 1
|
||||
|
||||
|
||||
/////// Shotgun
|
||||
|
||||
/datum/design/item/autolathe/arms/shotgun_clip_beanbag
|
||||
name = "2-round 12g speedloader (beanbag)"
|
||||
id = "shotgun_speedloader_beanbag"
|
||||
build_path = /obj/item/ammo_magazine/clip/c12g/beanbag
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 887)
|
||||
|
||||
/datum/design/item/autolathe/arms/shotgun_clip_pellet
|
||||
name = "2-round 12g speedloader (pellet)"
|
||||
id = "shotgun_speedloader_pellet"
|
||||
build_path = /obj/item/ammo_magazine/clip/c12g/pellet
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 1337)
|
||||
|
||||
|
||||
///////////////////////////////
|
||||
/*Ammo clips and Speedloaders*/
|
||||
///////////////////////////////
|
||||
|
||||
/datum/design/item/autolathe/arms/speedloader_357
|
||||
name = "speedloader (.357)"
|
||||
id = "speedloader_357"
|
||||
build_path = /obj/item/ammo_magazine/s357
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 1575)
|
||||
hidden = 1
|
||||
|
||||
/datum/design/item/autolathe/arms/speedloader_38
|
||||
name = "speedloader (.38)"
|
||||
id = "speedloader_38"
|
||||
build_path = /obj/item/ammo_magazine/s38
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 450)
|
||||
hidden = 1
|
||||
|
||||
/datum/design/item/autolathe/arms/speedloader_38r
|
||||
name = "speedloader (.38 rubber)"
|
||||
id = "speedloader_38_rubber"
|
||||
build_path = /obj/item/ammo_magazine/s38/rubber
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 450)
|
||||
|
||||
/datum/design/item/autolathe/arms/speedloader_45
|
||||
name = "speedloader (.45)"
|
||||
id = "speedloader_45"
|
||||
build_path = /obj/item/ammo_magazine/s45
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 656)
|
||||
hidden = 1
|
||||
|
||||
/datum/design/item/autolathe/arms/speedloader_45r
|
||||
name = "speedloader (.45 rubber)"
|
||||
id = "speedloader_45_rubber"
|
||||
build_path = /obj/item/ammo_magazine/s45/rubber
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 656)
|
||||
|
||||
/datum/design/item/autolathe/arms/rifle_clip_545
|
||||
name = "ammo clip (5.45mm)"
|
||||
id = "rifle_clip_545"
|
||||
build_path = /obj/item/ammo_magazine/clip/c545
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 565)
|
||||
hidden = 1
|
||||
|
||||
/datum/design/item/autolathe/arms/rifle_clip_545_practice
|
||||
name = "ammo clip (5.45mm practice)"
|
||||
id = "rifle_clip_545p"
|
||||
build_path = /obj/item/ammo_magazine/clip/c545/practice
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 565)
|
||||
|
||||
/datum/design/item/autolathe/arms/rifle_clip_762
|
||||
name = "ammo clip (7.62mm)"
|
||||
id = "rifle_clip_762"
|
||||
build_path = /obj/item/ammo_magazine/clip/c762
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 1250)
|
||||
hidden = 1
|
||||
|
||||
/datum/design/item/autolathe/arms/rifle_clip_762_practice
|
||||
name = "ammo clip (7.62mm practice)"
|
||||
id = "rifle_clip_762p"
|
||||
build_path = /obj/item/ammo_magazine/clip/c762/practice
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 1250)
|
||||
|
||||
/datum/design/item/autolathe/arms/knuckledusters
|
||||
name = "knuckle dusters"
|
||||
id = "knuckledusters"
|
||||
build_path = /obj/item/clothing/gloves/knuckledusters
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 625)
|
||||
hidden = 1
|
||||
|
||||
/datum/design/item/autolathe/arms/flamethrower
|
||||
name = "flamethrower"
|
||||
id = "flamethrower"
|
||||
build_path = /obj/item/weapon/flamethrower/full
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 625)
|
||||
hidden = 1
|
||||
|
||||
|
||||
56
code/datums/autolathe/arms_1_vr.dm
Normal file
56
code/datums/autolathe/arms_1_vr.dm
Normal file
@@ -0,0 +1,56 @@
|
||||
/datum/design/item/autolathe/arms/speedloader_357_flash
|
||||
name = "speedloader (.357 flash)"
|
||||
id = "speedloader_357f"
|
||||
build_path = /obj/item/ammo_magazine/s357/flash
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 1575)
|
||||
hidden = 1
|
||||
|
||||
/datum/design/item/autolathe/arms/speedloader_357_stun
|
||||
name = "speedloader (.357 stun)"
|
||||
id = "speedloader_357s"
|
||||
build_path = /obj/item/ammo_magazine/s357/stun
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 1575)
|
||||
hidden = 1
|
||||
|
||||
/datum/design/item/autolathe/arms/speedloader_357_rubber
|
||||
name = "speedloader (.357 rubber)"
|
||||
id = "speedloader_357r"
|
||||
build_path = /obj/item/ammo_magazine/s357/rubber
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 1575)
|
||||
hidden = 1
|
||||
|
||||
/datum/design/item/autolathe/arms/speedloader_44
|
||||
name = "speedloader (.44)"
|
||||
id = "speedloader_44"
|
||||
build_path = /obj/item/ammo_magazine/s44
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 1575)
|
||||
hidden = 1
|
||||
|
||||
/datum/design/item/autolathe/arms/speedloader_44_rubber
|
||||
name = "speedloader (.44)"
|
||||
id = "speedloader_44r"
|
||||
build_path = /obj/item/ammo_magazine/s44/rubber
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 1575)
|
||||
hidden = 1
|
||||
|
||||
/datum/design/item/autolathe/arms/mag_44
|
||||
name = "magazine (.44)"
|
||||
id = "mag_44"
|
||||
build_path = /obj/item/ammo_magazine/m44
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 1575)
|
||||
hidden = 1
|
||||
|
||||
/datum/design/item/autolathe/arms/mag_44_rubber
|
||||
name = "magazine (.44 rubber)"
|
||||
id = "mag_44r"
|
||||
build_path = /obj/item/ammo_magazine/m44/rubber
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 1575)
|
||||
hidden = 1
|
||||
|
||||
/datum/design/item/autolathe/arms/classic_smg_9mm
|
||||
name = "SMG magazine (9mm)"
|
||||
id = "classic_smg_9mm"
|
||||
build_path = /obj/item/ammo_magazine/m9mml
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 2250)
|
||||
hidden = 1
|
||||
|
||||
6
code/datums/autolathe/arms_1_yw.dm
Normal file
6
code/datums/autolathe/arms_1_yw.dm
Normal file
@@ -0,0 +1,6 @@
|
||||
/datum/design/item/autolathe/arms/shotgun_scatter
|
||||
name = "ammunition (12g, scatter)"
|
||||
id = "shotgun_scatter"
|
||||
build_path = /obj/item/ammo_casing/a12g/scatter
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 450)
|
||||
hidden = 1
|
||||
503
code/datums/autolathe/autolathe_yw.dm
Normal file
503
code/datums/autolathe/autolathe_yw.dm
Normal file
@@ -0,0 +1,503 @@
|
||||
#define AUTOLATHE_MAIN_MENU 1
|
||||
#define AUTOLATHE_CATEGORY_MENU 2
|
||||
#define AUTOLATHE_SEARCH_MENU 3
|
||||
|
||||
/obj/machinery/autolathe
|
||||
name = "autolathe"
|
||||
desc = "It produces items using metal and glass."
|
||||
icon = 'icons/obj/stationobjs_vr.dmi'
|
||||
icon_state = "autolathe"
|
||||
density = 1
|
||||
anchored = 1
|
||||
use_power = USE_POWER_IDLE
|
||||
idle_power_usage = 10
|
||||
active_power_usage = 2000
|
||||
clicksound = "keyboard"
|
||||
clickvol = 30
|
||||
|
||||
circuit = /obj/item/weapon/circuitboard/autolathe
|
||||
var/list/stored_material = list(DEFAULT_WALL_MATERIAL = 0, "glass" = 0)
|
||||
var/list/storage_capacity = list(DEFAULT_WALL_MATERIAL = 0, "glass" = 0)
|
||||
|
||||
var/hacked = 0
|
||||
var/disabled = 0
|
||||
var/shocked = 0
|
||||
var/busy = 0
|
||||
var/operating = 0.0
|
||||
var/list/queue = list()
|
||||
var/queue_max_len = 12
|
||||
var/turf/BuildTurf
|
||||
var/list/L = list()
|
||||
var/list/LL = list()
|
||||
var/prod_coeff
|
||||
var/list/being_built = list()
|
||||
var/datum/research/files
|
||||
|
||||
var/mat_efficiency = 1
|
||||
var/build_time = 50
|
||||
var/list/datum/design/item/autolathe/matching_designs
|
||||
var/temp_search
|
||||
var/selected_category
|
||||
var/screen = 1
|
||||
var/list/categories = list("Arms and Ammunition", "Devices", "Engineering", "General", "Security", "Medical", "Tools")
|
||||
|
||||
var/datum/wires/autolathe/wires = null
|
||||
|
||||
/obj/machinery/autolathe/New()
|
||||
..()
|
||||
wires = new(src)
|
||||
component_parts = list()
|
||||
component_parts += new /obj/item/weapon/stock_parts/matter_bin(src)
|
||||
component_parts += new /obj/item/weapon/stock_parts/matter_bin(src)
|
||||
component_parts += new /obj/item/weapon/stock_parts/matter_bin(src)
|
||||
component_parts += new /obj/item/weapon/stock_parts/manipulator(src)
|
||||
component_parts += new /obj/item/weapon/stock_parts/console_screen(src)
|
||||
RefreshParts()
|
||||
files = new /datum/research/autolathe(src)
|
||||
matching_designs = list()
|
||||
|
||||
/obj/machinery/autolathe/Destroy()
|
||||
qdel(wires)
|
||||
wires = null
|
||||
return ..()
|
||||
|
||||
/obj/machinery/autolathe/attack_hand(mob/user)
|
||||
|
||||
if(..() || (disabled && !panel_open))
|
||||
to_chat(user, "<span class='danger'>\The [src] is disabled!</span>")
|
||||
return
|
||||
|
||||
if(shocked)
|
||||
shock(user, 50)
|
||||
else
|
||||
ui_interact(user)
|
||||
|
||||
/obj/machinery/autolathe/dismantle()
|
||||
for(var/mat in stored_material)
|
||||
var/material/M = get_material_by_name(mat)
|
||||
if(!istype(M))
|
||||
continue
|
||||
var/obj/item/stack/material/S = new M.stack_type(get_turf(src))
|
||||
if(stored_material[mat] > S.perunit)
|
||||
S.amount = round(stored_material[mat] / S.perunit)
|
||||
else
|
||||
qdel(S)
|
||||
..()
|
||||
return 1
|
||||
|
||||
/obj/machinery/autolathe/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1)
|
||||
user.set_machine(src)
|
||||
var/data[0]
|
||||
data["screen"] = screen
|
||||
data["total_amount"] = (stored_material[DEFAULT_WALL_MATERIAL] + stored_material["glass"])
|
||||
data["max_amount"] = (storage_capacity[DEFAULT_WALL_MATERIAL] + storage_capacity["glass"])
|
||||
data["metal_amount"] = stored_material[DEFAULT_WALL_MATERIAL]
|
||||
data["glass_amount"] = stored_material["glass"]
|
||||
switch(screen)
|
||||
if(AUTOLATHE_MAIN_MENU)
|
||||
data["uid"] = "\ref[src]"
|
||||
data["categories"] = categories
|
||||
if(AUTOLATHE_CATEGORY_MENU)
|
||||
data["selected_category"] = selected_category
|
||||
var/list/designs = list()
|
||||
data["designs"] = designs
|
||||
for(var/datum/design/item/autolathe/D in files.known_designs)
|
||||
if(D.hidden && !hacked || selected_category != D.category)
|
||||
continue
|
||||
var/list/design = list()
|
||||
designs[++designs.len] = design
|
||||
design["name"] = D.name
|
||||
design["id"] = D.id
|
||||
design["disabled"] = disabled || !can_build(D) ? "disabled" : null
|
||||
if(ispath(D.build_path, /obj/item/stack))
|
||||
design["max_multiplier"] = min(D.maxstack, D.materials[DEFAULT_WALL_MATERIAL] ? round(stored_material[DEFAULT_WALL_MATERIAL] / D.materials[DEFAULT_WALL_MATERIAL]) : INFINITY, D.materials["glass"] ? round(stored_material["glass"] / D.materials["glass"]) : INFINITY)
|
||||
else
|
||||
design["max_multiplier"] = null
|
||||
design["materials"] = design_cost_data(D)
|
||||
if(AUTOLATHE_SEARCH_MENU)
|
||||
data["search"] = temp_search
|
||||
var/list/designs = list()
|
||||
data["designs"] = designs
|
||||
for(var/datum/design/item/autolathe/D in matching_designs)
|
||||
var/list/design = list()
|
||||
designs[++designs.len] = design
|
||||
design["name"] = D.name
|
||||
design["id"] = D.id
|
||||
design["disabled"] = disabled || !can_build(D) ? "disabled" : null
|
||||
if(ispath(D.build_path, /obj/item/stack))
|
||||
design["max_multiplier"] = min(D.maxstack, D.materials[DEFAULT_WALL_MATERIAL] ? round(stored_material[DEFAULT_WALL_MATERIAL] / D.materials[DEFAULT_WALL_MATERIAL]) : INFINITY, D.materials["glass"] ? round(stored_material["glass"] / D.materials["glass"]) : INFINITY)
|
||||
else
|
||||
design["max_multiplier"] = null
|
||||
design["materials"] = design_cost_data(D)
|
||||
|
||||
data = queue_data(data)
|
||||
|
||||
ui = SSnanoui.try_update_ui(user, src, ui_key, ui, data, force_open)
|
||||
if(!ui)
|
||||
ui = new(user, src, ui_key, "autolathe.tmpl", name, 800, 550)
|
||||
ui.set_initial_data(data)
|
||||
ui.open()
|
||||
|
||||
return data
|
||||
|
||||
/obj/machinery/autolathe/Topic(href, href_list)
|
||||
if(..())
|
||||
return
|
||||
add_fingerprint(usr)
|
||||
|
||||
if(href_list["menu"])
|
||||
screen = text2num(href_list["menu"])
|
||||
|
||||
if(href_list["category"])
|
||||
selected_category = href_list["category"]
|
||||
screen = AUTOLATHE_CATEGORY_MENU
|
||||
|
||||
if(href_list["make"])
|
||||
BuildTurf = loc
|
||||
|
||||
/////////////////
|
||||
//href protection
|
||||
var/datum/design/design_last_ordered
|
||||
design_last_ordered = FindDesign(href_list["make"]) //check if it's a valid design
|
||||
if(!design_last_ordered)
|
||||
return
|
||||
if(!(design_last_ordered.build_type & AUTOLATHE))
|
||||
return
|
||||
|
||||
//multiplier checks : only stacks can have one and its value is 1, 10 ,25 or max_multiplier
|
||||
var/multiplier = text2num(href_list["multiplier"])
|
||||
var/max_multiplier = min(design_last_ordered.maxstack, design_last_ordered.materials[DEFAULT_WALL_MATERIAL] ?round(stored_material[DEFAULT_WALL_MATERIAL]/design_last_ordered.materials[DEFAULT_WALL_MATERIAL]):INFINITY,design_last_ordered.materials["glass"]?round(stored_material["glass"]/design_last_ordered.materials["glass"]):INFINITY)
|
||||
var/is_stack = ispath(design_last_ordered.build_path, /obj/item/stack)
|
||||
|
||||
if(!is_stack && (multiplier > 1))
|
||||
return
|
||||
if(!(multiplier in list(1, 10, 25, max_multiplier))) //"enough materials ?" is checked in the build proc
|
||||
return
|
||||
/////////////////
|
||||
|
||||
if((queue.len + 1) < queue_max_len)
|
||||
add_to_queue(design_last_ordered,multiplier)
|
||||
else
|
||||
to_chat(usr, "<span class='warning'>The autolathe queue is full!</span>")
|
||||
if(!busy)
|
||||
busy = 1
|
||||
process_queue()
|
||||
busy = 0
|
||||
|
||||
if(href_list["remove_from_queue"])
|
||||
var/index = text2num(href_list["remove_from_queue"])
|
||||
if(isnum(index) && ISINRANGE(index, 1, queue.len))
|
||||
remove_from_queue(index)
|
||||
if(href_list["queue_move"] && href_list["index"])
|
||||
var/index = text2num(href_list["index"])
|
||||
var/new_index = index + text2num(href_list["queue_move"])
|
||||
if(isnum(index) && isnum(new_index))
|
||||
if(ISINRANGE(new_index, 1, queue.len))
|
||||
queue.Swap(index,new_index)
|
||||
if(href_list["clear_queue"])
|
||||
queue = list()
|
||||
if(href_list["search"])
|
||||
if(href_list["to_search"])
|
||||
temp_search = href_list["to_search"]
|
||||
if(!temp_search)
|
||||
return
|
||||
to_chat(world, (href_list["to_search"]))
|
||||
matching_designs.Cut()
|
||||
|
||||
for(var/datum/design/item/autolathe/D in files.known_designs)
|
||||
if(findtext(D.name, temp_search))
|
||||
matching_designs.Add(D)
|
||||
|
||||
screen = AUTOLATHE_SEARCH_MENU
|
||||
|
||||
SSnanoui.update_uis(src)
|
||||
return 1
|
||||
|
||||
/obj/machinery/autolathe/update_icon()
|
||||
if(panel_open)
|
||||
icon_state = "autolathe_t"
|
||||
else if(busy)
|
||||
icon_state = "autolathe_n"
|
||||
else
|
||||
if(icon_state == "autolathe_n")
|
||||
flick("autolathe_u", src) // If lid WAS closed, show opening animation
|
||||
icon_state = "autolathe"
|
||||
|
||||
/obj/machinery/autolathe/RefreshParts()
|
||||
..()
|
||||
var/mb_rating = 0
|
||||
var/man_rating = 0
|
||||
for(var/obj/item/weapon/stock_parts/matter_bin/MB in component_parts)
|
||||
mb_rating += MB.rating
|
||||
for(var/obj/item/weapon/stock_parts/manipulator/M in component_parts)
|
||||
man_rating += M.rating
|
||||
|
||||
storage_capacity[DEFAULT_WALL_MATERIAL] = mb_rating * 25000
|
||||
storage_capacity["glass"] = mb_rating * 12500
|
||||
build_time = 50 / man_rating
|
||||
mat_efficiency = 1.1 - man_rating * 0.1// Normally, price is 1.25 the amount of material, so this shouldn't go higher than 0.6. Maximum rating of parts is 5
|
||||
|
||||
|
||||
/obj/machinery/autolathe/proc/design_cost_data(datum/design/D)
|
||||
var/list/data = list()
|
||||
var/coeff = get_coeff(D)
|
||||
var/has_metal = 1
|
||||
if(D.materials[DEFAULT_WALL_MATERIAL] && (stored_material[DEFAULT_WALL_MATERIAL] < (D.materials[DEFAULT_WALL_MATERIAL] * coeff)))
|
||||
has_metal = 0
|
||||
var/has_glass = 1
|
||||
if(D.materials["glass"] && (stored_material["glass"] < (D.materials["glass"] * coeff)))
|
||||
has_glass = 0
|
||||
|
||||
data[++data.len] = list("name" = "metal", "amount" = D.materials[DEFAULT_WALL_MATERIAL] * coeff, "is_red" = !has_metal)
|
||||
data[++data.len] = list("name" = "glass", "amount" = D.materials["glass"] * coeff, "is_red" = !has_glass)
|
||||
|
||||
return data
|
||||
|
||||
/obj/machinery/autolathe/proc/queue_data(list/data)
|
||||
var/temp_metal = stored_material[DEFAULT_WALL_MATERIAL]
|
||||
var/temp_glass = stored_material["glass"]
|
||||
data["processing"] = being_built.len ? get_processing_line() : null
|
||||
if(istype(queue) && queue.len)
|
||||
var/list/data_queue = list()
|
||||
for(var/list/L in queue)
|
||||
var/datum/design/item/autolathe/D = L[1]
|
||||
var/list/LL = get_design_cost_as_list(D, L[2])
|
||||
data_queue[++data_queue.len] = list("name" = initial(D.name), "can_build" = can_build(D, L[2], temp_metal, temp_glass), "multiplier" = L[2])
|
||||
temp_metal = max(temp_metal - LL[1], 1)
|
||||
temp_glass = max(temp_glass - LL[2], 1)
|
||||
data["queue"] = data_queue
|
||||
data["queue_len"] = data_queue.len
|
||||
else
|
||||
data["queue"] = null
|
||||
return data
|
||||
|
||||
/obj/machinery/autolathe/proc/get_coeff(datum/design/D)
|
||||
var/coeff = (ispath(D.build_path,/obj/item/stack) ? 1 : mat_efficiency)//stacks are unaffected by production coefficient
|
||||
return coeff
|
||||
|
||||
/obj/machinery/autolathe/proc/build_item(datum/design/D, multiplier)
|
||||
desc = initial(desc)+"\nIt's building \a [initial(D.name)]."
|
||||
var/is_stack = ispath(D.build_path, /obj/item/stack)
|
||||
var/coeff = get_coeff(D)
|
||||
var/metal_cost = D.materials[DEFAULT_WALL_MATERIAL]
|
||||
var/glass_cost = D.materials["glass"]
|
||||
var/power = max(2000, (metal_cost+glass_cost)*multiplier/5)
|
||||
if(can_build(D, multiplier))
|
||||
being_built = list(D, multiplier)
|
||||
use_power(power)
|
||||
icon_state = "autolathe"
|
||||
flick("autolathe_n",src)
|
||||
if(is_stack)
|
||||
var/list/materials_used = list(DEFAULT_WALL_MATERIAL=metal_cost*multiplier, "glass"=glass_cost*multiplier)
|
||||
//stored_material = list(DEFAULT_WALL_MATERIAL -= materials_used[DEFAULT_WALL_MATERIAL], "glass" -= materials_used["glass"])
|
||||
stored_material[DEFAULT_WALL_MATERIAL] -= materials_used[DEFAULT_WALL_MATERIAL]
|
||||
stored_material["glass"] -= materials_used["glass"]
|
||||
else
|
||||
var/list/materials_used = list(DEFAULT_WALL_MATERIAL=metal_cost*coeff, "glass"=glass_cost*coeff)
|
||||
stored_material[DEFAULT_WALL_MATERIAL] -= materials_used[DEFAULT_WALL_MATERIAL]
|
||||
stored_material["glass"] -= materials_used["glass"]
|
||||
SSnanoui.update_uis(src)
|
||||
sleep(32*coeff)
|
||||
if(is_stack)
|
||||
var/obj/item/stack/S = new D.build_path(BuildTurf)
|
||||
S.amount = multiplier
|
||||
else
|
||||
var/obj/item/new_item = new D.build_path(BuildTurf)
|
||||
new_item.matter[DEFAULT_WALL_MATERIAL] *= coeff
|
||||
new_item.matter["glass"] *= coeff
|
||||
SSnanoui.update_uis(src)
|
||||
desc = initial(desc)
|
||||
|
||||
/obj/machinery/autolathe/proc/can_build(var/datum/design/D, var/multiplier = 1, custom_metal, custom_glass)
|
||||
if(D.chemicals.len)
|
||||
return 0
|
||||
|
||||
var/coeff = get_coeff(D)
|
||||
var/metal_amount = stored_material[DEFAULT_WALL_MATERIAL]
|
||||
if(custom_metal)
|
||||
metal_amount = custom_metal
|
||||
var/glass_amount = stored_material["glass"]
|
||||
if(custom_glass)
|
||||
glass_amount = custom_glass
|
||||
|
||||
if(D.materials[DEFAULT_WALL_MATERIAL] && (metal_amount < (multiplier*D.materials[DEFAULT_WALL_MATERIAL] * coeff)))
|
||||
return 0
|
||||
if(D.materials["glass"] && (glass_amount < (multiplier*D.materials["glass"] * coeff)))
|
||||
return 0
|
||||
return 1
|
||||
|
||||
/obj/machinery/autolathe/proc/get_design_cost_as_list(datum/design/D, multiplier = 1)
|
||||
var/list/OutputList = list(0,0)
|
||||
var/coeff = get_coeff(D)
|
||||
if(D.materials[DEFAULT_WALL_MATERIAL])
|
||||
OutputList[1] = (D.materials[DEFAULT_WALL_MATERIAL] * coeff)*multiplier
|
||||
if(D.materials["glass"])
|
||||
OutputList[2] = (D.materials["glass"] * coeff)*multiplier
|
||||
return OutputList
|
||||
|
||||
/obj/machinery/autolathe/proc/get_processing_line()
|
||||
var/datum/design/D = being_built[1]
|
||||
var/multiplier = being_built[2]
|
||||
var/is_stack = (multiplier>1)
|
||||
var/output = "PROCESSING: [initial(D.name)][is_stack?" (x[multiplier])":null]"
|
||||
return output
|
||||
|
||||
/obj/machinery/autolathe/proc/add_to_queue(D, multiplier)
|
||||
if(!istype(queue))
|
||||
queue = list()
|
||||
if(D)
|
||||
queue.Add(list(list(D,multiplier)))
|
||||
return queue.len
|
||||
|
||||
/obj/machinery/autolathe/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/autolathe/proc/process_queue()
|
||||
var/datum/design/D = queue[1][1]
|
||||
var/multiplier = queue[1][2]
|
||||
if(!D)
|
||||
remove_from_queue(1)
|
||||
if(queue.len)
|
||||
return process_queue()
|
||||
else
|
||||
return
|
||||
while(D)
|
||||
if(stat & (NOPOWER|BROKEN))
|
||||
being_built = new /list()
|
||||
return 0
|
||||
if(!can_build(D, multiplier))
|
||||
visible_message("[bicon(src)] <b>\The [src]</b> beeps, \"Not enough resources. Queue processing terminated.\"")
|
||||
queue = list()
|
||||
being_built = new /list()
|
||||
return 0
|
||||
|
||||
remove_from_queue(1)
|
||||
build_item(D,multiplier)
|
||||
D = listgetindex(listgetindex(queue, 1),1)
|
||||
multiplier = listgetindex(listgetindex(queue,1),2)
|
||||
being_built = new /list()
|
||||
|
||||
|
||||
/datum/research/autolathe
|
||||
|
||||
/datum/research/autolathe/DesignHasReqs(var/datum/design/D)
|
||||
return D && (D.build_type & AUTOLATHE)
|
||||
|
||||
/datum/research/autolathe/AddDesign2Known(var/datum/design/D)
|
||||
if(!(D.build_type & AUTOLATHE))
|
||||
return
|
||||
..()
|
||||
|
||||
//datum/research/proc/FindDesignByID(var/id)
|
||||
//return known_designs[id]
|
||||
|
||||
///obj/machinery/autolathe/proc/FindDesignByID(var/id)
|
||||
//return files.known_designs[id]
|
||||
|
||||
/obj/machinery/autolathe/proc/FindDesign(var/id)
|
||||
for(var/datum/design/item/autolathe/desired_design in files.known_designs)
|
||||
if(desired_design.id == id)
|
||||
return desired_design
|
||||
return
|
||||
|
||||
/obj/machinery/autolathe/attackby(var/obj/item/O as obj, var/mob/user as mob)
|
||||
if(busy)
|
||||
to_chat(user, "<span class='notice'>\The [src] is busy. Please wait for completion of previous operation.</span>")
|
||||
return
|
||||
|
||||
if(default_deconstruction_screwdriver(user, O))
|
||||
updateUsrDialog()
|
||||
return
|
||||
if(default_deconstruction_crowbar(user, O))
|
||||
return
|
||||
if(default_part_replacement(user, O))
|
||||
return
|
||||
|
||||
if(stat)
|
||||
return
|
||||
|
||||
if(panel_open)
|
||||
//Don't eat multitools or wirecutters used on an open lathe.
|
||||
if(O.is_multitool() || O.is_wirecutter())
|
||||
wires.Interact(user)
|
||||
return
|
||||
|
||||
if(O.loc != user && !(istype(O,/obj/item/stack)))
|
||||
return 0
|
||||
|
||||
if(is_robot_module(O))
|
||||
return 0
|
||||
|
||||
if(istype(O,/obj/item/ammo_magazine/clip) || istype(O,/obj/item/ammo_magazine/s357) || istype(O,/obj/item/ammo_magazine/s38) || istype (O,/obj/item/ammo_magazine/s44)/* VOREstation Edit*/) // Prevents ammo recycling exploit with speedloaders.
|
||||
to_chat(user, "\The [O] is too hazardous to recycle with the autolathe!")
|
||||
return
|
||||
/* ToDo: Make this actually check for ammo and change the value of the magazine if it's empty. -Spades
|
||||
var/obj/item/ammo_magazine/speedloader = O
|
||||
if(speedloader.stored_ammo)
|
||||
to_chat(user, "\The [speedloader] is too hazardous to put back into the autolathe while there's ammunition inside of it!")
|
||||
return
|
||||
else
|
||||
speedloader.matter = list(DEFAULT_WALL_MATERIAL = 75) // It's just a hunk of scrap metal now.
|
||||
if(istype(O,/obj/item/ammo_magazine)) // This was just for immersion consistency with above.
|
||||
var/obj/item/ammo_magazine/mag = O
|
||||
if(mag.stored_ammo)
|
||||
to_chat(user, "\The [mag] is too hazardous to put back into the autolathe while there's ammunition inside of it!")
|
||||
return*/
|
||||
|
||||
//Resources are being loaded.
|
||||
var/obj/item/eating = O
|
||||
if(!eating.matter)
|
||||
to_chat(user, "\The [eating] does not contain significant amounts of useful materials and cannot be accepted.")
|
||||
return
|
||||
|
||||
var/filltype = 0 // Used to determine message.
|
||||
var/total_used = 0 // Amount of material used.
|
||||
var/mass_per_sheet = 0 // Amount of material constituting one sheet.
|
||||
|
||||
for(var/material in eating.matter)
|
||||
|
||||
if(isnull(stored_material[material]) || isnull(storage_capacity[material]))
|
||||
continue
|
||||
|
||||
if(stored_material[material] >= storage_capacity[material])
|
||||
continue
|
||||
|
||||
var/total_material = eating.matter[material]
|
||||
|
||||
//If it's a stack, we eat multiple sheets.
|
||||
if(istype(eating,/obj/item/stack))
|
||||
var/obj/item/stack/stack = eating
|
||||
total_material *= stack.get_amount()
|
||||
|
||||
if(stored_material[material] + total_material > storage_capacity[material])
|
||||
total_material = storage_capacity[material] - stored_material[material]
|
||||
filltype = 1
|
||||
else
|
||||
filltype = 2
|
||||
|
||||
stored_material[material] += total_material
|
||||
total_used += total_material
|
||||
mass_per_sheet += eating.matter[material]
|
||||
|
||||
if(!filltype)
|
||||
to_chat(user, "<span class='notice'>\The [src] is full. Please remove material from the autolathe in order to insert more.</span>")
|
||||
return
|
||||
else if(filltype == 1)
|
||||
to_chat(user, "You fill \the [src] to capacity with \the [eating].")
|
||||
else
|
||||
to_chat(user, "You fill \the [src] with \the [eating].")
|
||||
|
||||
flick("autolathe_o", src) // Plays metal insertion animation. Work out a good way to work out a fitting animation. ~Z
|
||||
|
||||
if(istype(eating,/obj/item/stack))
|
||||
var/obj/item/stack/stack = eating
|
||||
stack.use(max(1, round(total_used/mass_per_sheet))) // Always use at least 1 to prevent infinite materials.
|
||||
else
|
||||
user.remove_from_mob(O)
|
||||
qdel(O)
|
||||
|
||||
updateUsrDialog()
|
||||
return
|
||||
45
code/datums/autolathe/devices_1.dm
Normal file
45
code/datums/autolathe/devices_1.dm
Normal file
@@ -0,0 +1,45 @@
|
||||
/datum/design/item/autolathe/devices //Datum for object designs, used in construction //IDs of that techs the object originated from and the minimum level requirements.
|
||||
category = "Devices" //category item goes to
|
||||
|
||||
/datum/design/item/autolathe/devices/consolescreen
|
||||
name = "console screen"
|
||||
id = "console_screen"
|
||||
build_path = /obj/item/weapon/stock_parts/console_screen
|
||||
materials = list("glass" = 200)
|
||||
|
||||
/datum/design/item/autolathe/devices/igniter
|
||||
name = "igniter"
|
||||
id = "igniter"
|
||||
build_path = /obj/item/device/assembly/igniter
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 625, "glass" = 62)
|
||||
|
||||
/datum/design/item/autolathe/devices/signaler
|
||||
name = "signaler"
|
||||
id = "signaler"
|
||||
build_path = /obj/item/device/assembly/signaler
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 1250, "glass" = 250)
|
||||
|
||||
/datum/design/item/autolathe/devices/sensor_infra
|
||||
name = "infrared sensor"
|
||||
id = "infrared_sensor"
|
||||
build_path = /obj/item/device/assembly/signaler
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 1250, "glass" = 625)
|
||||
|
||||
/datum/design/item/autolathe/devices/sensor_prox
|
||||
name = "proximity sensor"
|
||||
id = "proximity_sensor"
|
||||
build_path = /obj/item/device/assembly/signaler
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 1000, "glass" = 250)
|
||||
|
||||
/datum/design/item/autolathe/devices/beartrap
|
||||
name = "mechanical trap"
|
||||
id = "beartrap"
|
||||
build_path = /obj/item/weapon/beartrap
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 23437)
|
||||
|
||||
/datum/design/item/autolathe/devices/electropack
|
||||
name = "electropack"
|
||||
id = "electropack"
|
||||
build_path = /obj/item/device/radio/electropack
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 12500, "glass" = 3125)
|
||||
hidden = 1
|
||||
5
code/datums/autolathe/devices_1_vr.dm
Normal file
5
code/datums/autolathe/devices_1_vr.dm
Normal file
@@ -0,0 +1,5 @@
|
||||
/datum/design/item/autolathe/devices/sleevecard
|
||||
name = "sleevecard"
|
||||
id = "sleevecard"
|
||||
build_path = /obj/item/device/sleevecard
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 5000, "glass" = 5000)
|
||||
140
code/datums/autolathe/engineering_1.dm
Normal file
140
code/datums/autolathe/engineering_1.dm
Normal file
@@ -0,0 +1,140 @@
|
||||
/datum/design/item/autolathe/engineering //Datum for object designs, used in construction //IDs of that techs the object originated from and the minimum level requirements.
|
||||
category = "Engineering" //category item goes to
|
||||
|
||||
/datum/design/item/autolathe/engineering/airlockmodule
|
||||
name = "airlock electronics"
|
||||
id = "airlock_electronics"
|
||||
build_path = /obj/item/weapon/airlock_electronics
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62, "glass" = 62)
|
||||
|
||||
/datum/design/item/autolathe/engineering/airalarm
|
||||
name = "air alarm electronics"
|
||||
id = "airalarm_electronics"
|
||||
build_path = /obj/item/weapon/circuitboard/airalarm
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62, "glass" = 62)
|
||||
|
||||
/datum/design/item/autolathe/engineering/firealarm
|
||||
name = "fire alarm electronics"
|
||||
id = "firealarm_electronics"
|
||||
build_path = /obj/item/weapon/circuitboard/firealarm
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62, "glass" = 62)
|
||||
|
||||
/datum/design/item/autolathe/engineering/statusdisplay
|
||||
name = "ai status display electronics"
|
||||
id = "statusdisplay_electronics"
|
||||
build_path = /obj/item/weapon/circuitboard/ai_status_display
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62, "glass" = 62)
|
||||
|
||||
/datum/design/item/autolathe/engineering/newscaster
|
||||
name = "newscaster electronics"
|
||||
id = "newscaster_electronics"
|
||||
build_path = /obj/item/weapon/circuitboard/newscaster
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62, "glass" = 62)
|
||||
|
||||
/datum/design/item/autolathe/engineering/atm
|
||||
name = "atm electronics"
|
||||
id = "atm_electronics"
|
||||
build_path = /obj/item/weapon/circuitboard/atm
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62, "glass" = 62)
|
||||
|
||||
/datum/design/item/autolathe/engineering/intercom
|
||||
name = "intercom electronics"
|
||||
id = "intercom_electronics"
|
||||
build_path = /obj/item/weapon/circuitboard/intercom
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62, "glass" = 62)
|
||||
|
||||
/datum/design/item/autolathe/engineering/holopad
|
||||
name = "holopad electronics"
|
||||
id = "holopad_electronics"
|
||||
build_path = /obj/item/weapon/circuitboard/holopad
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62, "glass" = 62)
|
||||
|
||||
/datum/design/item/autolathe/engineering/guestpass
|
||||
name = "guestpass console electronics"
|
||||
id = "guestpass_electronics"
|
||||
build_path = /obj/item/weapon/circuitboard/guestpass
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62, "glass" = 62)
|
||||
|
||||
/datum/design/item/autolathe/engineering/entertainment
|
||||
name = "entertainment camera electronics"
|
||||
id = "entertainmentcamera_electronics"
|
||||
build_path = /obj/item/weapon/circuitboard/security/telescreen/entertainment
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62, "glass" = 62)
|
||||
|
||||
/datum/design/item/autolathe/engineering/keycard_auth
|
||||
name = "keycard authenticator electronics"
|
||||
id = "keycardauth_electronics"
|
||||
build_path = /obj/item/weapon/circuitboard/keycard_auth
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62, "glass" = 62)
|
||||
|
||||
/datum/design/item/autolathe/engineering/photocopier
|
||||
name = "photocop<6F>er electronics"
|
||||
id = "photocopier_electronics"
|
||||
build_path = /obj/item/weapon/circuitboard/photocopier
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62, "glass" = 62)
|
||||
|
||||
/datum/design/item/autolathe/engineering/fax
|
||||
name = "fax machine electronics"
|
||||
id = "fax_machine_electronics"
|
||||
build_path = /obj/item/weapon/circuitboard/fax
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62, "glass" = 62)
|
||||
|
||||
/datum/design/item/autolathe/engineering/papershredder
|
||||
name = "paper shredder electronics"
|
||||
id = "papershredder_electronics"
|
||||
build_path = /obj/item/weapon/circuitboard/papershredder
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62, "glass" = 62)
|
||||
|
||||
/datum/design/item/autolathe/engineering/microwave
|
||||
name = "microwave electronics"
|
||||
id = "microwave_electronics"
|
||||
build_path = /obj/item/weapon/circuitboard/microwave
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62, "glass" = 62)
|
||||
|
||||
/datum/design/item/autolathe/engineering/washing
|
||||
name = "washing machine electronics"
|
||||
id = "washingmachine_electronics"
|
||||
build_path = /obj/item/weapon/circuitboard/washing
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62, "glass" = 62)
|
||||
|
||||
/datum/design/item/autolathe/engineering/request
|
||||
name = "request console electronics"
|
||||
id = "requestconsole_electronics"
|
||||
build_path = /obj/item/weapon/circuitboard/request
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62, "glass" = 62)
|
||||
|
||||
/datum/design/item/autolathe/engineering/motor
|
||||
name = "motor"
|
||||
id = "motor"
|
||||
build_path = /obj/item/weapon/stock_parts/motor
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 75, "glass" = 12)
|
||||
|
||||
/datum/design/item/autolathe/engineering/gear
|
||||
name = "gear"
|
||||
id = "gear"
|
||||
build_path = /obj/item/weapon/stock_parts/gear
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62)
|
||||
|
||||
/datum/design/item/autolathe/engineering/spring
|
||||
name = "spring"
|
||||
id = "spring"
|
||||
build_path = /obj/item/weapon/stock_parts/gear
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 50)
|
||||
|
||||
/datum/design/item/autolathe/engineering/rcd_ammo
|
||||
name = "matter cartridge"
|
||||
id = "rcd_ammo"
|
||||
build_path = /obj/item/weapon/rcd_ammo
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 30000, "glass" = 15000)
|
||||
|
||||
/datum/design/item/autolathe/engineering/rcd
|
||||
name = "rapid construction device"
|
||||
id = "rcd"
|
||||
build_path = /obj/item/weapon/rcd
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62500)
|
||||
|
||||
/datum/design/item/autolathe/engineering/camera_assembly
|
||||
name = "camera assembly"
|
||||
id = "camera"
|
||||
build_path = /obj/item/weapon/rcd
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 875, "glass" = 375)
|
||||
11
code/datums/autolathe/engineering_1_vr.dm
Normal file
11
code/datums/autolathe/engineering_1_vr.dm
Normal file
@@ -0,0 +1,11 @@
|
||||
/datum/design/item/autolathe/engineering/timeclock
|
||||
name = "timeclock electronics"
|
||||
id = "timeclock_electronics"
|
||||
build_path = /obj/item/weapon/circuitboard/timeclock
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62, "glass" = 62)
|
||||
|
||||
/datum/design/item/autolathe/engineering/id_restorer
|
||||
name = "ID restoration console electronics"
|
||||
id = "idrestorer_electronics"
|
||||
build_path = /obj/item/weapon/circuitboard/id_restorer
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62, "glass" = 62)
|
||||
209
code/datums/autolathe/general_1.dm
Normal file
209
code/datums/autolathe/general_1.dm
Normal file
@@ -0,0 +1,209 @@
|
||||
/datum/design/item/autolathe/general //Datum for object designs, used in construction //IDs of that techs the object originated from and the minimum level requirements.
|
||||
category = "General" //category item goes to
|
||||
|
||||
/datum/design/item/autolathe/general/bucket
|
||||
name = "bucket"
|
||||
id = "bucket"
|
||||
build_path = /obj/item/weapon/reagent_containers/glass/bucket
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 250)
|
||||
|
||||
|
||||
/datum/design/item/autolathe/general/cooler_bottle
|
||||
name = "water cooler bottle"
|
||||
id = "cooler_bottle"
|
||||
build_path = /obj/item/weapon/reagent_containers/glass/cooler_bottle
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 15000)
|
||||
|
||||
/datum/design/item/autolathe/general/drinkingglass_square
|
||||
name = "half-pint glass"
|
||||
id = "halfpint_glass"
|
||||
build_path = /obj/item/weapon/reagent_containers/food/drinks/glass2/square
|
||||
materials = list("glass" = 75)
|
||||
|
||||
/datum/design/item/autolathe/general/drinkingglass_rocks
|
||||
name = "rocks glass"
|
||||
id = "rocks_glass"
|
||||
build_path = /obj/item/weapon/reagent_containers/food/drinks/glass2/rocks
|
||||
materials = list("glass" = 50)
|
||||
|
||||
/datum/design/item/autolathe/general/drinkingglass_shake
|
||||
name = "milkshake glass"
|
||||
id = "milkshake_glass"
|
||||
build_path = /obj/item/weapon/reagent_containers/food/drinks/glass2/shake
|
||||
materials = list("glass" = 37)
|
||||
|
||||
/datum/design/item/autolathe/general/drinkingglass_cocktail
|
||||
name = "cocktail glass"
|
||||
id = "cocktail_glass"
|
||||
build_path = /obj/item/weapon/reagent_containers/food/drinks/glass2/cocktail
|
||||
materials = list("glass" = 37)
|
||||
|
||||
/datum/design/item/autolathe/general/drinkingglass_shot
|
||||
name = "shot glass"
|
||||
id = "shot_glass"
|
||||
build_path = /obj/item/weapon/reagent_containers/food/drinks/glass2/shot
|
||||
materials = list("glass" = 75)
|
||||
|
||||
/datum/design/item/autolathe/general/drinkingglass_pint
|
||||
name = "pint glass"
|
||||
id = "pint_glass"
|
||||
build_path = /obj/item/weapon/reagent_containers/food/drinks/glass2/pint
|
||||
materials = list("glass" = 150)
|
||||
|
||||
/datum/design/item/autolathe/general/drinkingglass_mug
|
||||
name = "glass mug"
|
||||
id = "mug_glass"
|
||||
build_path = /obj/item/weapon/reagent_containers/food/drinks/glass2/mug
|
||||
materials = list("glass" = 100)
|
||||
|
||||
/datum/design/item/autolathe/general/drinkingglass_wine
|
||||
name = "wine glass"
|
||||
id = "wine_glass"
|
||||
build_path = /obj/item/weapon/reagent_containers/food/drinks/glass2/wine
|
||||
materials = list("glass" = 62)
|
||||
|
||||
/datum/design/item/autolathe/general/flashlight
|
||||
name = "flashlight"
|
||||
id = "flashlight"
|
||||
build_path = /obj/item/device/flashlight
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62, "glass" = 25)
|
||||
|
||||
|
||||
/datum/design/item/autolathe/general/floor_light
|
||||
name = "floor light"
|
||||
id = "floor_light"
|
||||
build_path = /obj/machinery/floor_light
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 3125, "glass" = 3437)
|
||||
|
||||
/datum/design/item/autolathe/general/extinguisher
|
||||
name = "fire extinguisher"
|
||||
id = "fire_extinguisher"
|
||||
build_path = /obj/item/weapon/extinguisher
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 112)
|
||||
|
||||
/datum/design/item/autolathe/general/jar
|
||||
name = "jar"
|
||||
id = "glass_jar"
|
||||
build_path = /obj/item/glass_jar
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 250)
|
||||
|
||||
/datum/design/item/autolathe/general/radio_headset
|
||||
name = "radio headset"
|
||||
id = "radio_headset"
|
||||
build_path = /obj/item/device/radio/headset
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 93)
|
||||
|
||||
/datum/design/item/autolathe/general/radio_bounced
|
||||
name = "station bounced radio"
|
||||
id = "radio_bounced"
|
||||
build_path = /obj/item/device/radio/off
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 93, "glass" = 31)
|
||||
|
||||
/datum/design/item/autolathe/general/suit_cooler
|
||||
name = "suit cooling unit"
|
||||
id = "suit_cooler"
|
||||
build_path = /obj/item/device/suit_cooling_unit
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 18750, "glass" = 4375)
|
||||
|
||||
/datum/design/item/autolathe/general/weldermask
|
||||
name = "welding mask"
|
||||
id = "weldermask"
|
||||
build_path = /obj/item/clothing/head/welding
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 3750, "glass" = 1250)
|
||||
|
||||
/datum/design/item/autolathe/general/metal
|
||||
name = "steel sheets"
|
||||
id = "steel_sheets"
|
||||
build_path = /obj/item/stack/material/steel
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 2000)
|
||||
maxstack = 50
|
||||
|
||||
/datum/design/item/autolathe/general/glass
|
||||
name = "glass sheets"
|
||||
id = "glass_sheets"
|
||||
build_path = /obj/item/stack/material/glass
|
||||
materials = list("glass" = 2000)
|
||||
maxstack = 50
|
||||
|
||||
/datum/design/item/autolathe/general/rglass
|
||||
name = "reinforced glass sheets"
|
||||
id = "reinforcedglass_sheets"
|
||||
build_path = /obj/item/stack/material/glass/reinforced
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 1000, "glass" = 2000)
|
||||
maxstack = 50
|
||||
|
||||
/datum/design/item/autolathe/general/rods
|
||||
name = "metal rods"
|
||||
id = "metal_rods"
|
||||
build_path = /obj/item/stack/rods
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 500)
|
||||
maxstack = 60
|
||||
|
||||
/datum/design/item/autolathe/general/spraybottle
|
||||
name = "empty spray bottle"
|
||||
id = "spraybottle"
|
||||
build_path = /obj/item/stack/rods
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 375, "glass" = 375)
|
||||
|
||||
/datum/design/item/autolathe/general/knife
|
||||
name = "kitchen knife"
|
||||
id = "kitchen_knife"
|
||||
build_path = /obj/item/weapon/material/knife
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 375)
|
||||
|
||||
/datum/design/item/autolathe/general/taperecorder
|
||||
name = "tape recorder"
|
||||
id = "taperecorder"
|
||||
build_path = /obj/item/device/taperecorder
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 75, "glass" = 37)
|
||||
|
||||
/datum/design/item/autolathe/general/light_tube
|
||||
name = "light tube"
|
||||
id = "light_tube"
|
||||
build_path = /obj/item/weapon/light/tube
|
||||
materials = list("glass" = 125)
|
||||
|
||||
/datum/design/item/autolathe/general/light_bulb
|
||||
name = "light bulb"
|
||||
id = "light_bulb"
|
||||
build_path = /obj/item/weapon/light/bulb
|
||||
materials = list("glass" = 125)
|
||||
|
||||
/datum/design/item/autolathe/general/ashtray_glass
|
||||
name = "glass ashtray"
|
||||
id = "ashtray_glass"
|
||||
build_path = /obj/item/weapon/material/ashtray/glass
|
||||
materials = list("glass" = 250)
|
||||
|
||||
/datum/design/item/autolathe/general/weldinggoggles
|
||||
name = "welding goggles"
|
||||
id = "weldinggoggles"
|
||||
build_path = /obj/item/clothing/glasses/welding
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 1875, "glass" = 1250)
|
||||
|
||||
/datum/design/item/autolathe/general/maglight
|
||||
name = "maglight"
|
||||
id = "maglight"
|
||||
build_path = /obj/item/device/flashlight/maglight
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 250, "glass" = 62)
|
||||
|
||||
/datum/design/item/autolathe/general/emergency_cell
|
||||
name = "light fixture battery"
|
||||
id = "emergency_cell"
|
||||
build_path = /obj/item/weapon/cell/emergency_light
|
||||
materials = list("glass" = 25)
|
||||
|
||||
/datum/design/item/autolathe/general/handcuffs
|
||||
name = "handcuffs"
|
||||
id = "handcuffs"
|
||||
build_path = /obj/item/weapon/handcuffs
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 625)
|
||||
hidden = 1
|
||||
|
||||
/datum/design/item/autolathe/general/legcuffs
|
||||
name = "legcuffs"
|
||||
id = "legcuffs"
|
||||
build_path = /obj/item/weapon/handcuffs/legcuffs
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 625)
|
||||
hidden = 1
|
||||
|
||||
23
code/datums/autolathe/general_1_vr.dm
Normal file
23
code/datums/autolathe/general_1_vr.dm
Normal file
@@ -0,0 +1,23 @@
|
||||
/datum/design/item/autolathe/general/holocollar
|
||||
name = "Holo-collar"
|
||||
id = "holocollar"
|
||||
build_path = /obj/item/clothing/accessory/collar/holo
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62)
|
||||
|
||||
/datum/design/item/autolathe/general/metaglass
|
||||
name = "metamorphic glass"
|
||||
id = "metaglass"
|
||||
build_path = /obj/item/weapon/reagent_containers/food/drinks/metaglass
|
||||
materials = list("glass" = 625)
|
||||
|
||||
/datum/design/item/autolathe/general/drinkingglass_carafe
|
||||
name = "glass carafe"
|
||||
id = "carafe_glass"
|
||||
build_path = /obj/item/weapon/reagent_containers/food/drinks/glass2/carafe
|
||||
materials = list("glass" = 62)
|
||||
|
||||
/datum/design/item/autolathe/general/drinkingglass_pitcher
|
||||
name = "pitcher"
|
||||
id = "pitcher_glass"
|
||||
build_path = /obj/item/weapon/reagent_containers/food/drinks/glass2/pitcher
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62)
|
||||
71
code/datums/autolathe/medical_1.dm
Normal file
71
code/datums/autolathe/medical_1.dm
Normal file
@@ -0,0 +1,71 @@
|
||||
/datum/design/item/autolathe/medical //Datum for object designs, used in construction //IDs of that techs the object originated from and the minimum level requirements.
|
||||
category = "Medical" //category item goes to
|
||||
|
||||
/datum/design/item/autolathe/medical/scalpel
|
||||
name = "scalpel"
|
||||
id = "scalpel"
|
||||
build_path = /obj/item/weapon/surgical/scalpel
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 12500, "glass" = 6250)
|
||||
|
||||
/datum/design/item/autolathe/medical/circularsaw
|
||||
name = "circular saw"
|
||||
id = "circularsaw"
|
||||
build_path = /obj/item/weapon/surgical/circular_saw
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 25000, "glass" = 12500)
|
||||
|
||||
/datum/design/item/autolathe/medical/surgicaldrill
|
||||
name = "surgical drill"
|
||||
id = "surgicaldrill"
|
||||
build_path = /obj/item/weapon/surgical/surgicaldrill
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 18750, "glass" = 12500)
|
||||
|
||||
/datum/design/item/autolathe/medical/retractor
|
||||
name = "retractor"
|
||||
id = "retractor"
|
||||
build_path = /obj/item/weapon/surgical/retractor
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 12500, "glass" = 6250)
|
||||
|
||||
/datum/design/item/autolathe/medical/cautery
|
||||
name = "cautery"
|
||||
id = "cautery"
|
||||
build_path = /obj/item/weapon/surgical/cautery
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 6250, "glass" = 3125)
|
||||
|
||||
/datum/design/item/autolathe/medical/hemostat
|
||||
name = "hemostat"
|
||||
id = "hemostat"
|
||||
build_path = /obj/item/weapon/surgical/hemostat
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 6250, "glass" = 3125)
|
||||
|
||||
/datum/design/item/autolathe/medical/beaker
|
||||
name = "glass beaker"
|
||||
id = "beaker"
|
||||
build_path = /obj/item/weapon/reagent_containers/glass/beaker
|
||||
materials = list("glass" = 625)
|
||||
|
||||
/datum/design/item/autolathe/medical/large_beaker
|
||||
name = "large glass beaker"
|
||||
id = "large_beaker"
|
||||
build_path = /obj/item/weapon/reagent_containers/glass/beaker/large
|
||||
materials = list("glass" = 1300)
|
||||
|
||||
/datum/design/item/autolathe/medical/vial
|
||||
name = "glass vial"
|
||||
id = "vial"
|
||||
build_path = /obj/item/weapon/reagent_containers/glass/beaker/vial
|
||||
materials = list("glass" = 312)
|
||||
|
||||
/datum/design/item/autolathe/medical/syringe
|
||||
name = "syringe"
|
||||
id = "syringe"
|
||||
build_path = /obj/item/weapon/reagent_containers/syringe
|
||||
materials = list("glass" = 187)
|
||||
|
||||
/datum/design/item/autolathe/medical/implanter
|
||||
name = "implanter"
|
||||
id = "implanter"
|
||||
build_path = /obj/item/weapon/implanter
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 1250, "glass" = 1250)
|
||||
|
||||
|
||||
|
||||
5
code/datums/autolathe/medical_1_vr.dm
Normal file
5
code/datums/autolathe/medical_1_vr.dm
Normal file
@@ -0,0 +1,5 @@
|
||||
/datum/design/item/autolathe/medical/autoinjector
|
||||
name = "empty autoinjector"
|
||||
id = "autoinjector"
|
||||
build_path = /obj/item/weapon/reagent_containers/hypospray/autoinjector/empty
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 100)
|
||||
69
code/datums/autolathe/tools_1.dm
Normal file
69
code/datums/autolathe/tools_1.dm
Normal file
@@ -0,0 +1,69 @@
|
||||
/datum/design/item/autolathe/tools //Datum for object designs, used in construction //IDs of that techs the object originated from and the minimum level requirements.
|
||||
category = "Tools" //category item goes to
|
||||
|
||||
/datum/design/item/autolathe/tools/crowbar
|
||||
name = "crowbar"
|
||||
id = "crowbar"
|
||||
build_path = /obj/item/weapon/tool/crowbar
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62)
|
||||
|
||||
/datum/design/item/autolathe/tools/multitool
|
||||
name = "multitool"
|
||||
id = "multitool"
|
||||
build_path = /obj/item/device/multitool
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62, "glass" = 25)
|
||||
|
||||
/datum/design/item/autolathe/tools/t_scanner
|
||||
name = "T-ray scanner"
|
||||
id = "t_scanner"
|
||||
build_path = /obj/item/device/t_scanner
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 187)
|
||||
|
||||
/datum/design/item/autolathe/tools/weldertool
|
||||
name = "welding tool"
|
||||
id = "weldertool"
|
||||
build_path = /obj/item/weapon/weldingtool
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 87, "glass" = 37)
|
||||
|
||||
/datum/design/item/autolathe/tools/electric_welder
|
||||
name = "electric welding tool"
|
||||
id = "electric_welder"
|
||||
build_path = /obj/item/weapon/weldingtool/electric/unloaded
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 87, "glass" = 37)
|
||||
hidden = 1
|
||||
|
||||
/datum/design/item/autolathe/tools/screwdriver
|
||||
name = "screwdriver"
|
||||
id = "screwdriver"
|
||||
build_path = /obj/item/weapon/tool/screwdriver
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 93)
|
||||
|
||||
/datum/design/item/autolathe/tools/wirecutters
|
||||
name = "wirecutters"
|
||||
id = "wirecutters"
|
||||
build_path = /obj/item/weapon/tool/wirecutters
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 100)
|
||||
|
||||
/datum/design/item/autolathe/tools/wrench
|
||||
name = "wrench"
|
||||
id = "wrench"
|
||||
build_path = /obj/item/weapon/tool/wrench
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 187)
|
||||
|
||||
/datum/design/item/autolathe/tools/hatchet
|
||||
name = "hatchet"
|
||||
id = "hatchet"
|
||||
build_path = /obj/item/weapon/material/knife/machete/hatchet
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 500)
|
||||
|
||||
/datum/design/item/autolathe/tools/minihoe
|
||||
name = "mini hoe"
|
||||
id = "minihoe"
|
||||
build_path = /obj/item/weapon/material/minihoe
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 625)
|
||||
|
||||
/datum/design/item/autolathe/tools/welder_industrial
|
||||
name = "industrial welding tool"
|
||||
id = "welder_industrial"
|
||||
build_path = /obj/item/weapon/weldingtool/largetank
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 87, "glass" = 75)
|
||||
5
code/datums/autolathe/tools_1_vr.dm
Normal file
5
code/datums/autolathe/tools_1_vr.dm
Normal file
@@ -0,0 +1,5 @@
|
||||
/datum/design/item/autolathe/tools/prybar
|
||||
name = "prybar"
|
||||
id = "prybar"
|
||||
build_path = /obj/item/weapon/tool/prybar
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 37)
|
||||
15
code/datums/autolathe/tools_1_yw.dm
Normal file
15
code/datums/autolathe/tools_1_yw.dm
Normal file
@@ -0,0 +1,15 @@
|
||||
/datum/design/item/autolathe/tools/ice_pick
|
||||
name = "ice pick"
|
||||
id = "ice_pick"
|
||||
build_path = /obj/item/weapon/ice_pick
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 15000)
|
||||
|
||||
/datum/design/item/autolathe/tools/shovel
|
||||
name = "shovel"
|
||||
id = "shovel"
|
||||
build_path = /obj/item/weapon/shovel
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62)
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -26,6 +26,8 @@
|
||||
matter = list(DEFAULT_WALL_MATERIAL = 50, "glass" = 50)
|
||||
req_components = list()
|
||||
|
||||
/datum/category_item/autolathe/engineering/grounding_rod
|
||||
name = "grounding rod electronics"
|
||||
path = /obj/item/weapon/circuitboard/grounding_rod
|
||||
/datum/design/item/autolathe/engineering/grounding_rod //yw add turned into a design for new autolathe
|
||||
name = "grouding rod electronics"
|
||||
id = "grounding_rods"
|
||||
build_path = /obj/item/weapon/circuitboard/grounding_rod
|
||||
materials = list(DEFAULT_WALL_MATERIAL = 62, "glass" = 62)// yw add end turned into a design for new autolathe
|
||||
|
||||
@@ -31,6 +31,7 @@ other types of metals and chemistry for reagents).
|
||||
var/time = 10 //How many ticks it requires to build
|
||||
var/category = null //Primarily used for Mech Fabricators, but can be used for anything.
|
||||
var/sort_string = "ZZZZZ" //Sorting order
|
||||
var/maxstack = 1 // yw edit, used by autolathe, says how many stacks a item can have or the limit of how many you can spawn at once
|
||||
|
||||
/datum/design/New()
|
||||
..()
|
||||
|
||||
150
nano/templates/autolathe.tmpl
Normal file
150
nano/templates/autolathe.tmpl
Normal file
@@ -0,0 +1,150 @@
|
||||
<!--
|
||||
Title: Autolathe UI
|
||||
Used In File(s): \code\game\machinery\autolathe_yw.dm
|
||||
-->
|
||||
|
||||
<!--
|
||||
#define AUTOLATHE_MAIN_MENU 1
|
||||
#define AUTOLATHE_CATEGORY_MENU 2
|
||||
#define AUTOLATHE_SEARCH_MENU 3
|
||||
-->
|
||||
|
||||
<style type="text/css">
|
||||
input[type=text], input[type=submit] {
|
||||
border: 1px solid #161616;
|
||||
background-color: #40628a;
|
||||
color: #FFFFFF;
|
||||
padding: 4px;
|
||||
}
|
||||
input[type=submit]:hover {
|
||||
background-color: #507aac;
|
||||
}
|
||||
</style>
|
||||
|
||||
{{if data.screen == 2 || data.screen == 3}}
|
||||
<div class='item'>
|
||||
{{:helper.link('Main Menu', 'reply', {'menu' : 1})}}
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
<table style='width:100%'><tr>
|
||||
<td valign='top' style='margin-right: 300px'>
|
||||
<div class='statusDisplay'>
|
||||
{{if data.screen == 1}} <!-- AUTOLATHE_MAIN_MENU -->
|
||||
<h3>Autolathe Menu</h3>
|
||||
<div class='itemLabelWidest'><table>
|
||||
<tr>
|
||||
<td><b>Total amount:</b></td><td>{{:data.total_amount}} / {{:data.max_amount}} cm<sup>3</sup></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><b>Metal amount:</b></td><td>{{:data.metal_amount}} cm<sup>3</sup></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><b>Glass amount:</b></td><td>{{:data.glass_amount}} cm<sup>3</sup></td>
|
||||
</tr>
|
||||
</table></div>
|
||||
<form action='?src={{:data.uid}}' method='get'>
|
||||
<input type='hidden' name='src' value='{{:data.uid}}'>
|
||||
<input type='hidden' name='search' value='1'>
|
||||
<input type='text' id='to_search' name='to_search'> <input type='submit' value='Search'>
|
||||
</form>
|
||||
|
||||
<hr>
|
||||
<table class='item'><tr>
|
||||
{{for data.categories}}
|
||||
{{if (index & 1) == 0 && index != 0}}
|
||||
</tr><tr>
|
||||
{{/if}}
|
||||
<td>{{:helper.link(value, 'arrow-right', {'category': value})}}</td>
|
||||
{{/for}}
|
||||
</tr></table>
|
||||
{{else data.screen == 2 || data.screen == 3}}
|
||||
{{if data.screen == 2}} <!-- AUTOLATHE_CATEGORY_MENU -->
|
||||
<h3>Viewing Category {{:data.selected_category}}:</h3>
|
||||
{{else data.screen == 3}} <!-- AUTOLATHE_SEARCH_MENU -->
|
||||
<h3>Search Results for '{{:data.search}}':</h3>
|
||||
{{/if}}
|
||||
<div class='itemLabelWidest'><table>
|
||||
<tr>
|
||||
<td><b>Total amount:</b></td><td>{{:data.total_amount}} / {{:data.max_amount}} cm<sup>3</sup></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><b>Metal amount:</b></td><td>{{:data.metal_amount}} cm<sup>3</sup></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><b>Glass amount:</b></td><td>{{:data.glass_amount}} cm<sup>3</sup></td>
|
||||
</tr>
|
||||
</table></div>
|
||||
<table>
|
||||
{{for data.designs}}
|
||||
<tr>
|
||||
<td>{{:helper.link(value.name, 'print', {'make' : value.id, 'multiplier' : 1}, value.disabled)}}</td>
|
||||
<td>{{if value.max_multiplier > 10}}
|
||||
{{:helper.link('x10', null, {'make' : value.id, 'multiplier' : 10}, value.disabled)}}
|
||||
{{/if}}</td>
|
||||
<td>{{if value.max_multiplier > 25}}
|
||||
{{:helper.link('x25', null, {'make' : value.id, 'multiplier' : 25}, value.disabled)}}
|
||||
{{/if}}</td>
|
||||
<td>{{if value.max_multiplier}}
|
||||
{{:helper.link('x' + value.max_multiplier, null, {'make' : value.id, 'multiplier' : value.max_multiplier}, value.disabled)}}
|
||||
{{/if}}</td>
|
||||
<td>
|
||||
{{for value.materials : material : i}}
|
||||
{{if material.amount}}
|
||||
|
|
||||
{{if material.is_red}}
|
||||
<span class='bad'>
|
||||
{{/if}}
|
||||
{{:material.amount}} {{:material.name}}
|
||||
{{if material.is_red}}
|
||||
</span>
|
||||
{{/if}}
|
||||
{{/if}}
|
||||
{{/for}}
|
||||
</td>
|
||||
</tr>
|
||||
{{/for}}
|
||||
</table>
|
||||
{{/if}}
|
||||
</div>
|
||||
</td>
|
||||
<td valign='top' style='width: 300px'>
|
||||
<div class="statusDisplay">
|
||||
<h3>Queue contains:</h3>
|
||||
{{if data.queue}}
|
||||
{{if data.processing}}
|
||||
<ol class='good'>{{:data.processing}}</ol>
|
||||
{{/if}}
|
||||
<ol>
|
||||
{{for data.queue}}
|
||||
<li>
|
||||
{{if !value.can_build}}
|
||||
<span class='bad'>
|
||||
{{/if}}
|
||||
{{:value.name}} {{:value.multiplier > 1 ? '(' + value.multiplier + ')' : ''}}
|
||||
{{if !value.can_build}}
|
||||
</span>
|
||||
{{/if}}
|
||||
<div class='item'>
|
||||
{{if index + 1 > 1}}
|
||||
{{:helper.link('', 'arrow-up', {'queue_move' : -1, 'index' : index + 1})}}
|
||||
{{/if}}
|
||||
{{if index + 1 < data.queue_len}}
|
||||
{{:helper.link('', 'arrow-down', {'queue_move' : +1, 'index' : index + 1})}}
|
||||
{{/if}}
|
||||
{{:helper.link('Remove', 'times', {'remove_from_queue' : index + 1})}}
|
||||
</div>
|
||||
</li>
|
||||
{{/for}}
|
||||
</ol>
|
||||
{{:helper.link('Clear queue', 'trash', {'clear_queue' : 1})}}
|
||||
{{else}}
|
||||
{{if data.processing}}
|
||||
<ol class='good'>{{:data.processing}}</ol>
|
||||
{{else}}
|
||||
<ol class='average'>Nothing</ol>
|
||||
{{/if}}
|
||||
{{/if}}
|
||||
</div>
|
||||
</td>
|
||||
</tr></table>
|
||||
@@ -306,21 +306,21 @@
|
||||
#include "code\datums\soul_link.dm"
|
||||
#include "code\datums\sun.dm"
|
||||
#include "code\datums\weakref.dm"
|
||||
#include "code\datums\autolathe\arms.dm"
|
||||
#include "code\datums\autolathe\arms_vr.dm"
|
||||
#include "code\datums\autolathe\arms_yw.dm"
|
||||
#include "code\datums\autolathe\autolathe.dm"
|
||||
#include "code\datums\autolathe\devices.dm"
|
||||
#include "code\datums\autolathe\devices_vr.dm"
|
||||
#include "code\datums\autolathe\engineering.dm"
|
||||
#include "code\datums\autolathe\engineering_vr.dm"
|
||||
#include "code\datums\autolathe\general.dm"
|
||||
#include "code\datums\autolathe\general_vr.dm"
|
||||
#include "code\datums\autolathe\medical.dm"
|
||||
#include "code\datums\autolathe\medical_vr.dm"
|
||||
#include "code\datums\autolathe\tools.dm"
|
||||
#include "code\datums\autolathe\tools_vr.dm"
|
||||
#include "code\datums\autolathe\tools_yw.dm"
|
||||
#include "code\datums\autolathe\arms_1.dm"
|
||||
#include "code\datums\autolathe\arms_1_vr.dm"
|
||||
#include "code\datums\autolathe\arms_1_yw.dm"
|
||||
#include "code\datums\autolathe\autolathe_yw.dm"
|
||||
#include "code\datums\autolathe\devices_1.dm"
|
||||
#include "code\datums\autolathe\devices_1_vr.dm"
|
||||
#include "code\datums\autolathe\engineering_1.dm"
|
||||
#include "code\datums\autolathe\engineering_1_vr.dm"
|
||||
#include "code\datums\autolathe\general_1.dm"
|
||||
#include "code\datums\autolathe\general_1_vr.dm"
|
||||
#include "code\datums\autolathe\medical_1.dm"
|
||||
#include "code\datums\autolathe\medical_1_vr.dm"
|
||||
#include "code\datums\autolathe\tools_1.dm"
|
||||
#include "code\datums\autolathe\tools_1_vr.dm"
|
||||
#include "code\datums\autolathe\tools_1_yw.dm"
|
||||
#include "code\datums\helper_datums\construction_datum.dm"
|
||||
#include "code\datums\helper_datums\events.dm"
|
||||
#include "code\datums\helper_datums\getrev.dm"
|
||||
@@ -762,7 +762,6 @@
|
||||
#include "code\game\machinery\airconditioner_vr.dm"
|
||||
#include "code\game\machinery\airconditioner_yw.dm"
|
||||
#include "code\game\machinery\atmo_control.dm"
|
||||
#include "code\game\machinery\autolathe.dm"
|
||||
#include "code\game\machinery\Beacon.dm"
|
||||
#include "code\game\machinery\biogenerator.dm"
|
||||
#include "code\game\machinery\bioprinter.dm"
|
||||
|
||||
Reference in New Issue
Block a user