diff --git a/code/_helpers/unsorted.dm b/code/_helpers/unsorted.dm index a2589ecc110cf..1be2c37610e49 100644 --- a/code/_helpers/unsorted.dm +++ b/code/_helpers/unsorted.dm @@ -528,9 +528,12 @@ proc/GaussRandRound(var/sigma,var/roundto) return round(GaussRand(sigma),roundto) //Will return the contents of an atom recursivly to a depth of 'searchDepth' -/atom/proc/GetAllContents(searchDepth = 5) +/atom/proc/GetAllContents(searchDepth = 5, var/includeSelf = FALSE) var/list/toReturn = list() + if (includeSelf) + toReturn += src + for(var/atom/part in contents) toReturn += part if(part.contents.len && searchDepth) diff --git a/code/datums/autolathe/autolathe_datums.dm b/code/datums/autolathe/autolathe_datums.dm index 787ede7e76c6d..2a71c51a2fdd0 100644 --- a/code/datums/autolathe/autolathe_datums.dm +++ b/code/datums/autolathe/autolathe_datums.dm @@ -88,7 +88,9 @@ other types of metals and chemistry for reagents). var/list/mats = O.matter if (mats && mats.len) + for(var/a in mats) + var/amount = mats[a] * multiplier if(amount) LAZYAPLUS(materials, a, amount) diff --git a/code/datums/autolathe/tools.dm b/code/datums/autolathe/tools.dm index 21bb9c2cab155..f0a2e3f3f2a42 100644 --- a/code/datums/autolathe/tools.dm +++ b/code/datums/autolathe/tools.dm @@ -136,4 +136,12 @@ /datum/design/autolathe/tool/pneumatic_crowbar name = "pneumatic crowbar" - build_path = /obj/item/weapon/tool/crowbar/pneumatic \ No newline at end of file + build_path = /obj/item/weapon/tool/crowbar/pneumatic + +/datum/design/autolathe/tool/sawblade + name = "sawblade" + build_path = /obj/item/ammo_casing/sawblade + +/datum/design/autolathe/tool/sawblade + name = "diamond blade" + build_path = /obj/item/ammo_casing/sawblade/diamond \ No newline at end of file diff --git a/code/game/machinery/autolathe.dm b/code/game/machinery/autolathe.dm index cb24718c9e3f9..c74bb29eed1ac 100644 --- a/code/game/machinery/autolathe.dm +++ b/code/game/machinery/autolathe.dm @@ -43,9 +43,9 @@ var/datum/computer_file/binary/design/current_file = null var/list/queue = list() - var/queue_max = 8 + var/queue_max = 12 - var/speed = 2 + var/speed = 1 var/progress = 0 diff --git a/code/game/objects/items/devices/binoculars.dm b/code/game/objects/items/devices/binoculars.dm index 90345fd37cd17..e6e2d04967f48 100644 --- a/code/game/objects/items/devices/binoculars.dm +++ b/code/game/objects/items/devices/binoculars.dm @@ -12,7 +12,7 @@ throw_range = 15 throw_speed = 3 - //matter = list("metal" = 50,MATERIAL_GLASS = 50) + //matter = list(MATERIAL_STEEL = 50,MATERIAL_GLASS = 50) /obj/item/device/binoculars/attack_self(mob/user) diff --git a/code/game/objects/items/weapons/ecigs.dm b/code/game/objects/items/weapons/ecigs.dm index bcda9dde5751f..bde52c976dca4 100644 --- a/code/game/objects/items/weapons/ecigs.dm +++ b/code/game/objects/items/weapons/ecigs.dm @@ -216,7 +216,7 @@ obj/item/clothing/mask/smokable/ecig/util/examine(mob/user) w_class = ITEM_SIZE_TINY icon = 'icons/obj/ecig.dmi' icon_state = "ecartridge" - matter = list("metal" = 50, MATERIAL_GLASS = 10) + matter = list(MATERIAL_STEEL = 50, MATERIAL_GLASS = 10) volume = 20 atom_flags = ATOM_FLAG_OPEN_CONTAINER diff --git a/code/modules/client/asset_cache.dm b/code/modules/client/asset_cache.dm index 2bb8ecd5c67cc..2ee2ec11b9ab6 100644 --- a/code/modules/client/asset_cache.dm +++ b/code/modules/client/asset_cache.dm @@ -198,6 +198,19 @@ You can set verify to TRUE if you want send() to sleep until the client has the //DEFINITIONS FOR ASSET DATUMS START HERE. + +//This loads little icons used for proto/autolathe +/datum/asset/simple/design_icons/register() + for(var/D in SSresearch.all_designs) + var/datum/design/design = D + + var/filename = sanitizeFileName("[design.build_path].png") + var/icon/I = getFlatTypeIcon(design.build_path) + register_asset(filename, I) + assets[filename] = I + + design.ui_data["icon"] = filename + /datum/asset/simple/tgui isTrivial = FALSE assets = list( diff --git a/code/modules/integrated_electronics/tools.dm b/code/modules/integrated_electronics/tools.dm index 7b6149d9ccaca..6a2ce48deb465 100644 --- a/code/modules/integrated_electronics/tools.dm +++ b/code/modules/integrated_electronics/tools.dm @@ -11,7 +11,7 @@ used for power or data transmission." icon = 'icons/obj/electronic_assemblies.dmi' icon_state = "wirer-wire" - matter = list("metal" = 147, MATERIAL_GLASS = 64) + matter = list(MATERIAL_STEEL = 147, MATERIAL_GLASS = 64) obj_flags = OBJ_FLAG_CONDUCTIBLE w_class = ITEM_SIZE_SMALL var/datum/integrated_io/selected_io = null @@ -95,7 +95,7 @@ settings to specific circuits, or for debugging purposes. It can also pulse activation pins." icon = 'icons/obj/electronic_assemblies.dmi' icon_state = "debugger" - matter = list("metal" = 151, MATERIAL_GLASS = 82) + matter = list(MATERIAL_STEEL = 151, MATERIAL_GLASS = 82) obj_flags = OBJ_FLAG_CONDUCTIBLE w_class = ITEM_SIZE_SMALL description_info = "Ref scanning is done by click-drag-dropping the debugger unto an adjacent object that you wish to scan." @@ -159,7 +159,7 @@ desc = "This tool allows one to analyze custom assemblies and their components from a distance." icon = 'icons/obj/electronic_assemblies.dmi' icon_state = "analyzer" - matter = list("metal" = 156, MATERIAL_GLASS = 67) + matter = list(MATERIAL_STEEL = 156, MATERIAL_GLASS = 67) obj_flags = OBJ_FLAG_CONDUCTIBLE w_class = 2 var/last_scan = "" diff --git a/code/modules/power/cell.dm b/code/modules/power/cell.dm index 33a137b4cf2e0..71d84ea709621 100644 --- a/code/modules/power/cell.dm +++ b/code/modules/power/cell.dm @@ -15,7 +15,7 @@ var/charge // Current charge var/maxcharge = 1000 // Capacity in Wh var/overlay_state - matter = list(MATERIAL_STEEL = 700, MATERIAL_GLASS = 50) + matter = list(MATERIAL_STEEL = 700, MATERIAL_SILVER = 50) /obj/item/weapon/cell/New() @@ -162,7 +162,7 @@ throw_speed = 5 throw_range = 7 maxcharge = 100 - matter = list("metal" = 70, MATERIAL_GLASS = 5) + matter = list(MATERIAL_STEEL = 70, MATERIAL_SILVER = 5) /obj/item/weapon/cell/device/variable/New(newloc, charge_amount) maxcharge = charge_amount @@ -177,14 +177,14 @@ desc = "A small power cell designed to power more energy-demanding devices." icon_state = "hdevice" maxcharge = 100 - matter = list("metal" = 70, MATERIAL_GLASS = 6) + matter = list(MATERIAL_STEEL = 70, MATERIAL_SILVER = 6) /obj/item/weapon/cell/crap name = "old power cell" desc = "A cheap old power cell. It's probably been in use for quite some time now." origin_tech = list(TECH_POWER = 0) maxcharge = 100 - matter = list(MATERIAL_STEEL = 700, MATERIAL_GLASS = 40) + matter = list(MATERIAL_STEEL = 700, MATERIAL_SILVER = 40) /obj/item/weapon/cell/crap/empty charge = 0 @@ -194,7 +194,7 @@ desc = "A standard and relatively cheap power cell, commonly used." origin_tech = list(TECH_POWER = 0) maxcharge = 250 - matter = list(MATERIAL_STEEL = 700, MATERIAL_GLASS = 40) + matter = list(MATERIAL_STEEL = 700, MATERIAL_SILVER = 40) /obj/item/weapon/cell/crap/empty/New() ..() @@ -206,7 +206,7 @@ desc = "A special power cell designed for heavy-duty use in area power controllers." origin_tech = list(TECH_POWER = 1) maxcharge = 500 - matter = list(MATERIAL_STEEL = 700, MATERIAL_GLASS = 50) + matter = list(MATERIAL_STEEL = 700, MATERIAL_SILVER = 50) /obj/item/weapon/cell/high @@ -215,7 +215,7 @@ origin_tech = list(TECH_POWER = 2) icon_state = "hcell" maxcharge = 1000 - matter = list(MATERIAL_STEEL = 700, MATERIAL_GLASS = 60) + matter = list(MATERIAL_STEEL = 700, MATERIAL_SILVER = 60) /obj/item/weapon/cell/high/empty/New() ..() @@ -228,7 +228,7 @@ origin_tech = list(TECH_POWER = 3) icon_state = "hcell" maxcharge = 1500 - matter = list(MATERIAL_STEEL = 700, MATERIAL_GLASS = 70) + matter = list(MATERIAL_STEEL = 700, MATERIAL_SILVER = 70) /obj/item/weapon/cell/super @@ -237,7 +237,7 @@ origin_tech = list(TECH_POWER = 5) icon_state = "scell" maxcharge = 2000 - matter = list(MATERIAL_STEEL = 700, MATERIAL_GLASS = 70) + matter = list(MATERIAL_STEEL = 700, MATERIAL_SILVER = 70) /obj/item/weapon/cell/super/empty/New() ..() @@ -250,7 +250,7 @@ origin_tech = list(TECH_POWER = 6) icon_state = "hpcell" maxcharge = 3000 - matter = list(MATERIAL_STEEL = 700, MATERIAL_GLASS = 80) + matter = list(MATERIAL_STEEL = 700, MATERIAL_SILVER = 80) /obj/item/weapon/cell/hyper/empty/New() ..() @@ -263,7 +263,7 @@ icon_state = "icell" origin_tech = null maxcharge = 3000 - matter = list(MATERIAL_STEEL = 700, MATERIAL_GLASS = 80) + matter = list(MATERIAL_STEEL = 700, MATERIAL_SILVER = 80) /obj/item/weapon/cell/infinite/check_charge() return 1 diff --git a/code/modules/projectiles/ammunition/bullets.dm b/code/modules/projectiles/ammunition/bullets.dm index 84724b09cacd2..518ebabe528ad 100644 --- a/code/modules/projectiles/ammunition/bullets.dm +++ b/code/modules/projectiles/ammunition/bullets.dm @@ -110,7 +110,7 @@ icon_state = "pshell" spent_icon = "pshell-spent" projectile_type = /obj/item/projectile/bullet/shotgun/practice - matter = list("metal" = 90) + matter = list(MATERIAL_STEEL = 90) /obj/item/ammo_casing/shotgun/beanbag name = "beanbag shell" diff --git a/code/modules/reagents/reagent_containers/food/snacks.dm b/code/modules/reagents/reagent_containers/food/snacks.dm index bcbf4bba2d0b9..89cd3271f820e 100644 --- a/code/modules/reagents/reagent_containers/food/snacks.dm +++ b/code/modules/reagents/reagent_containers/food/snacks.dm @@ -691,7 +691,7 @@ icon_state = "roburger" filling_color = "#cccccc" center_of_mass = "x=16;y=11" - nutriment_desc = list("bun" = 2, "metal" = 3) + nutriment_desc = list("bun" = 2, "iron" = 3) nutriment_amt = 2 /obj/item/weapon/reagent_containers/food/snacks/roburger/New() ..() @@ -990,7 +990,7 @@ trash = /obj/item/stack/rods filling_color = "#fffee0" center_of_mass = "x=17;y=15" - nutriment_desc = list("tofu" = 3, "metal" = 1) + nutriment_desc = list("tofu" = 3, "iron" = 1) nutriment_amt = 8 /obj/item/weapon/reagent_containers/food/snacks/tofukabob/New() ..() diff --git a/nano/templates/autolathe.tmpl b/nano/templates/autolathe.tmpl index 6c971c34d1f16..5f6cfdfae132e 100644 --- a/nano/templates/autolathe.tmpl +++ b/nano/templates/autolathe.tmpl @@ -89,10 +89,10 @@ Used In File(s): \code\game\machinery\autolathe.dm