The Great Device Resprite and Contained Sprite-ening (#20344)

Don't let the large file size scare you, it's just mostly splitting
stuff into contained sprites and putting them in the correct place.

Anyway, resprites most non-resprited devices in devices.dmi, and puts
them in contained sprites.
Also puts any related /obj/item/device into contained sprites too.
That's basically the long and short of it.
This commit is contained in:
Wowzewow (Wezzy)
2025-01-24 12:16:30 +00:00
committed by GitHub
parent e9fd65e0af
commit e7232d04fc
188 changed files with 319 additions and 355 deletions
+1 -1
View File
@@ -1,5 +1,5 @@
/obj/item/device/assembly_holder
name = "Assembly"
name = "assembly"
icon = 'icons/obj/assemblies/new_assemblies.dmi'
icon_state = "holder"
item_state = "assembly"
+1 -1
View File
@@ -1,7 +1,7 @@
/obj/item/export_scanner
name = "export scanner"
desc = "A device used to check objects against NanoTrasen exports and bounty database."
icon = 'icons/obj/device.dmi'
icon = 'icons/obj/item/device/price_scanner.dmi'
icon_state = "price_scanner"
slot_flags = SLOT_BELT
item_flags = ITEM_FLAG_NO_BLUDGEON
+3 -2
View File
@@ -570,8 +570,8 @@
/obj/item/device/kinetic_analyzer
name = "kinetic analyzer"
desc = "Analyzes the kinetic accelerator and prints useful information on it's statistics."
icon = 'icons/obj/device.dmi'
icon_state = "kinetic_anal"
icon = 'icons/obj/item/device/kinetic_analyzer.dmi'
icon_state = "kinetic_analyzer"
/obj/item/device/kinetic_analyzer/afterattack(var/atom/target, var/mob/living/user, proximity, params)
@@ -580,6 +580,7 @@
SPAN_WARNING("\The [user] scans \the [target] with \the [src]."),
SPAN_ALERT("You scan \the [target] with \the [src]."))
flick("kinetic_analyzer_scan", src)
if(istype(target,/obj/item/gun/custom_ka))
playsound(src, 'sound/machines/ping.ogg', 10, 1)
+2 -1
View File
@@ -1,10 +1,11 @@
/obj/item/device/uv_light
name = "\improper UV light"
desc = "A small handheld black light."
icon = 'icons/obj/item/device/uv_light.dmi'
icon_state = "uv_off"
item_state = "electronic"
slot_flags = SLOT_BELT
w_class = WEIGHT_CLASS_SMALL
item_state = "electronic"
matter = list(DEFAULT_WALL_MATERIAL = 150)
origin_tech = list(TECH_MAGNET = 1, TECH_ENGINEERING = 1)
var/list/scanned = list()
+2 -1
View File
@@ -1,8 +1,9 @@
/obj/item/device/eftpos
name = "\improper EFTPOS scanner"
desc = "Swipe your ID card to make purchases electronically."
icon = 'icons/obj/device.dmi'
icon = 'icons/obj/item/device/eftpos.dmi'
icon_state = "eftpos"
item_state = "electronic"
w_class = WEIGHT_CLASS_TINY
var/machine_id = ""
var/eftpos_name = "Default EFTPOS scanner"
+2 -1
View File
@@ -3,8 +3,9 @@
/obj/item/device/quikpay
name = "\improper Idris Quik-Pay"
desc = "Swipe your ID to make direct company purchases."
icon = 'icons/obj/device.dmi'
icon = 'icons/obj/item/device/eftpos.dmi'
icon_state = "quikpay"
item_state = "electronic"
w_class = WEIGHT_CLASS_SMALL
slot_flags = SLOT_BELT
var/machine_id = ""
+4 -3
View File
@@ -2,9 +2,10 @@
/obj/item/portable_map_reader
name = "portable map reader"
desc = "Displays a map of the local space, as well as any marked points of interest."
icon = 'icons/obj/device.dmi'
icon_state = "depthscanner"
icon = 'icons/obj/item/device/gps.dmi'
icon_state = "gps"
item_state = "radio"
contained_sprite = TRUE
/// The map reader only shows that z-level (and any z-levels that z-level is connected to).
/// It will not show other z-levels, like if the user were to transport it elsewhere on a shuttle.
var/list/connected_z_levels = null
+1 -2
View File
@@ -22,10 +22,9 @@
/obj/item/device/analyzer/plant_analyzer
name = "plant analyzer"
icon = 'icons/obj/item/tools/plant_analyzer.dmi'
icon = 'icons/obj/item/device/plant_analyzer.dmi'
icon_state = "hydro"
item_state = "hydro"
contained_sprite = TRUE
var/form_title
var/last_data
matter = list(DEFAULT_WALL_MATERIAL = 80, MATERIAL_GLASS = 20)
@@ -406,7 +406,10 @@
name = "global positioning system"
desc = "This allows you to easily know the position of a machine containing this device."
extended_desc = "The GPS's coordinates it gives is absolute, not relative."
icon = 'icons/obj/item/device/gps.dmi'
icon_state = "gps"
item_state = "radio"
contained_sprite = TRUE
complexity = 4
inputs = list()
outputs = list(
+4 -3
View File
@@ -1,9 +1,10 @@
/obj/item/mining_scanner
name = "deep ore scanner"
desc = "A complex device used to locate ore deep underground."
icon = 'icons/obj/device.dmi'
icon_state = "forensic0-old" //GET A BETTER SPRITE.
item_state = "electronic"
icon = 'icons/obj/item/mining_scanner.dmi'
icon_state = "manual_mining"
item_state = "manual_mining"
contained_sprite = TRUE
origin_tech = list(TECH_MAGNET = 1, TECH_ENGINEERING = 1)
matter = list(DEFAULT_WALL_MATERIAL = 150)
+8 -8
View File
@@ -200,7 +200,7 @@
/obj/item/pickaxe/drill
name = "mining drill" // Can dig sand as well!
desc = "Yours is the drill that will pierce through the rock walls."
icon = 'icons/obj/item/tools/drills.dmi'
icon = 'icons/obj/item/drills.dmi'
icon_state = "miningdrill"
item_state = "miningdrill"
contained_sprite = TRUE
@@ -221,8 +221,8 @@
/obj/item/pickaxe/drill/weak
name = "shaft drill"
desc = "Baby's first mining drill. Slow, but reliable."
icon_state = "babydrill"
item_state = "babydrill"
icon_state = "drill"
item_state = "drill"
digspeed = 5
digspeed_unwielded = 10
excavation_amount = 80
@@ -231,7 +231,7 @@
/obj/item/pickaxe/jackhammer
name = "sonic jackhammer"
desc = "Cracks rocks with sonic blasts, perfect for killing cave lizards."
icon = 'icons/obj/item/tools/drills.dmi'
icon = 'icons/obj/item/drills.dmi'
icon_state = "jackhammer"
item_state = "jackhammer"
contained_sprite = TRUE
@@ -275,7 +275,7 @@
/obj/item/pickaxe/diamonddrill //When people ask about the badass leader of the mining tools, they are talking about ME!
name = "diamond mining drill"
icon = 'icons/obj/item/tools/drills.dmi'
icon = 'icons/obj/item/drills.dmi'
icon_state = "diamonddrill"
item_state = "diamonddrill"
contained_sprite = TRUE
@@ -296,7 +296,7 @@
/obj/item/pickaxe/borgdrill
name = "cyborg mining drill"
icon = 'icons/obj/item/tools/drills.dmi'
icon = 'icons/obj/item/drills.dmi'
icon_state = "diamonddrill"
item_state = "jackhammer"
contained_sprite = TRUE
@@ -616,7 +616,7 @@
/obj/item/ore_radar
name = "scanner pad"
desc = "An antiquated device that can detect ore in a wide radius around the user."
icon = 'icons/obj/device.dmi'
icon = 'icons/obj/item/pinpointer.dmi'
icon_state = "pinoff"
obj_flags = OBJ_FLAG_CONDUCTABLE
slot_flags = SLOT_BELT
@@ -1166,7 +1166,7 @@ var/list/total_extraction_beacons = list()
/obj/item/autochisel
name = "auto-chisel"
desc = "With an integrated AI chip and hair-trigger precision, this baby makes sculpting almost automatic!"
icon = 'icons/obj/item/tools/drills.dmi'
icon = 'icons/obj/item/drills.dmi'
icon_state = "chisel"
item_state = "jackhammer"
contained_sprite = TRUE
+4 -5
View File
@@ -9,9 +9,8 @@
/obj/item/ore_detector
name = "ore detector"
desc = "A device capable of locating and displaying ores to the average untrained hole explorer."
icon = 'icons/obj/item/tools/ore_scanner.dmi'
icon_state = "ore_scanner"
item_state = "ore_scanner"
icon = 'icons/obj/item/adv_mining_scanner.dmi'
icon_state = "advmining0"
w_class = WEIGHT_CLASS_SMALL
slot_flags = SLOT_BELT
force = 1
@@ -42,7 +41,7 @@
return ..()
/obj/item/ore_detector/update_icon()
icon_state = "ore_scanner[active ? "-active" : ""]"
icon_state = "advmining[active]"
/obj/item/ore_detector/attack_self(mob/user)
ui_interact(user)
@@ -130,7 +129,7 @@
found_ores = TRUE
if(found_ores)
var/image/ore_ping = image(icon = 'icons/obj/item/tools/ore_scanner.dmi', icon_state = "signal_overlay", loc = anchor, layer = UNDER_HUD_LAYER)
var/image/ore_ping = image(icon = 'icons/obj/item/adv_mining_scanner.dmi', icon_state = "signal_overlay", loc = anchor, layer = UNDER_HUD_LAYER)
ore_ping.appearance_flags |= KEEP_APART|RESET_ALPHA|RESET_COLOR|RESET_TRANSFORM
ore_ping.pixel_x = rand(-6, 6)
ore_ping.pixel_y = rand(-6, 6)
+2 -2
View File
@@ -127,7 +127,7 @@
if(!underlays.len)
underlays += image(firstaid_item.icon, firstaid_item.icon_state)
var/matrix/M = matrix()
var/image/ha_image = image('icons/obj/device.dmi', "health")
var/image/ha_image = image('icons/obj/item/device/healthanalyzer.dmi', "health")
M.Translate(5, 0)
ha_image.transform = M
underlays += ha_image
@@ -376,7 +376,7 @@
to_chat(user, SPAN_NOTICE("You add the health sensor to [src]."))
name = "first-aid/robot arm/health analyzer assembly"
var/matrix/M = matrix()
var/image/ha_image = image('icons/obj/device.dmi', "health")
var/image/ha_image = image('icons/obj/item/device/healthanalyzer.dmi', "health")
M.Translate(5, 0)
ha_image.transform = M
underlays += ha_image
@@ -3,6 +3,7 @@
//
/obj/item/device/robotanalyzer
name = "cyborg analyzer"
icon = 'icons/obj/item/device/robotanalyzer.dmi'
icon_state = "robotanalyzer"
item_state = "analyzer"
desc = "A hand-held scanner able to diagnose robotic injuries."
@@ -109,6 +110,7 @@
/obj/item/device/robotanalyzer/augment
name = "retractable cyborg analyzer"
desc = "An scanner implanted directly into the hand, popping through the finger. This scanner can diagnose robotic injuries."
icon = 'icons/obj/item/device/robotanalyzer.dmi'
icon_state = "robotanalyzer"
item_state = "analyzer"
slot_flags = null
@@ -3,7 +3,7 @@
/obj/item/matter_decompiler
name = "matter decompiler"
desc = "Eating trash, bits of glass, or other debris will replenish your stores."
icon = 'icons/obj/device.dmi'
icon = 'icons/obj/item/gripper.dmi'
icon_state = "decompiler"
var/is_decompiling = FALSE
@@ -3,7 +3,7 @@
/obj/item/gripper
name = "magnetic gripper"
desc = "A simple grasping tool specialized in construction and engineering work."
icon = 'icons/obj/device.dmi'
icon = 'icons/obj/item/gripper.dmi'
icon_state = "gripper"
item_flags = ITEM_FLAG_NO_BLUDGEON
@@ -3,7 +3,7 @@
desc = "A phoron-enhanced induction charger hooked up to its attached stationbound's internal cell."
desc_extended = "Harnessing the energy potential found in phoron structures, NanoTrasen engineers have created a portable device capable of highly efficient wireless charging. The expense and limit of energy output of using this method of charging prevents it from being used on a large scale, being far outclassed by Phoron-Supermatter charging systems."
desc_info = "Click on an adjacent object that contains or is a power cell to attempt to find and charge it. After a successful charge, the inductive charger recharge in a few minutes. The amount transfered can be adjusted by alt clicking it."
icon = 'icons/obj/item/tools/inductive_charger.dmi'
icon = 'icons/obj/item/inductive_charger.dmi'
icon_state = "inductive_charger"
item_state = "inductive_charger"
item_flags = ITEM_FLAG_HELD_MAP_TEXT
@@ -2,7 +2,7 @@
/obj/item/borg/combat/shield
name = "personal shielding"
desc = "A powerful experimental module that turns aside or absorbs incoming attacks at the cost of charge."
icon = 'icons/obj/device.dmi'
icon = 'icons/obj/item/device/chameleon.dmi'
icon_state = "shield1" //placeholder for now // four fucking years alberyk. FOUR
var/shield_level = 0.5 //Percentage of damage absorbed by the shield.
@@ -6,6 +6,8 @@
desc = "Small device which allows rapid deployment and removal of inflatables."
icon = 'icons/obj/item/inflatables.dmi'
icon_state = "inf_deployer"
item_state = "RPED" //inhands
contained_sprite = TRUE
w_class = WEIGHT_CLASS_NORMAL
var/deploying = FALSE
var/max_walls = 10
@@ -3,12 +3,9 @@
lexical_name = "tablet"
desc = "A personal data assistant. The latest in portable microcomputer solutions from Thinktronic Systems LTD."
icon = 'icons/obj/pda.dmi'
item_icons = list(
slot_l_hand_str = 'icons/mob/items/device/lefthand_device.dmi',
slot_r_hand_str = 'icons/mob/items/device/righthand_device.dmi',
)
icon_state = "pda"
item_state = "electronic"
contained_sprite = TRUE
icon_state_screensaver = "off"
icon_state_unpowered = "pda"
var/icon_add // this is the "bar" part in "pda-bar"
+1
View File
@@ -281,5 +281,6 @@
/obj/item/device/toner
name = "toner cartridge"
desc = "A high-definition toner for colour photocopying and printer machines. Good thing it's a business expense."
icon = 'icons/obj/item/device/toner.dmi'
icon_state = "tonercartridge"
var/toner_amount = 30
-1
View File
@@ -320,7 +320,6 @@ var/global/photo_count = 0
desc = "A slightly antiquated camera with a large flash bulb. Still popular with Tajara all over Adhomai."
icon_state = "taj_camera_on"
item_state = "taj_camera"
contained_sprite = TRUE
slot_flags = SLOT_MASK
black_white = TRUE
icon_on = "taj_camera_on"
+1 -1
View File
@@ -11,7 +11,7 @@
which were once staples of Tajaran offices - have slowly become more uncommon. That \
said, rural areas and less urban parts of the planet still rely heavily on these machines."
icon_state = "typewriter"
icon = 'icons/obj/device.dmi'
icon = 'icons/obj/bureaucracy.dmi'
force = 25
throwforce = 5
w_class = WEIGHT_CLASS_NORMAL
+1 -1
View File
@@ -77,6 +77,6 @@
/obj/item/tracker_electronics
name = "tracker electronics"
icon = 'icons/obj/device.dmi'
icon = 'icons/obj/module.dmi'
icon_state = "door_electronics"
w_class = WEIGHT_CLASS_SMALL
@@ -2,7 +2,7 @@
name = "welding kit"
desc = "A heavy-duty, portable welding fluid carrier."
slot_flags = SLOT_BACK
icon = 'icons/obj/item/tools/welderpack.dmi'
icon = 'icons/obj/item/reagent_containers/weldpack.dmi'
icon_state = "welderpack"
item_state = "welderpack"
contained_sprite = TRUE
+1 -1
View File
@@ -250,8 +250,8 @@
/obj/item/device/destTagger
name = "destination tagger"
desc = "Used to set the destination of properly wrapped packages."
icon = 'icons/obj/item/device/dest_tagger.dmi'
icon_state = "dest_tagger"
item_state = "dest_tagger"
var/currTag = 0
matter = list(DEFAULT_WALL_MATERIAL = 250, MATERIAL_GLASS = 140)
w_class = WEIGHT_CLASS_SMALL
@@ -1,85 +0,0 @@
//chemistry stuff here so that it can be easily viewed/modified
/obj/item/reagent_containers/glass/solution_tray
name = "solution tray"
desc = "A small, open-topped glass container for delicate research samples. It sports a re-useable strip for labelling with a pen."
icon = 'icons/obj/device.dmi'
icon_state = "solution_tray"
matter = list(MATERIAL_GLASS = 5)
w_class = WEIGHT_CLASS_SMALL
amount_per_transfer_from_this = 1
possible_transfer_amounts = list(1, 2)
volume = 2
atom_flags = ATOM_FLAG_OPEN_CONTAINER
/obj/item/reagent_containers/glass/solution_tray/attackby(obj/item/attacking_item, mob/user, params)
if(attacking_item.ispen())
var/new_label = sanitizeSafe( tgui_input_text(user, "What should the new label be?", "Label solution tray", max_length = MAX_NAME_LEN), MAX_NAME_LEN )
if(new_label)
name = "solution tray ([new_label])"
to_chat(user, SPAN_NOTICE("You write on the label of the solution tray."))
else
return ..()
/obj/item/storage/box/solution_trays
name = "solution tray box"
icon_state = "solution_trays"
/obj/item/storage/box/solution_trays/fill()
..()
new /obj/item/reagent_containers/glass/solution_tray( src )
new /obj/item/reagent_containers/glass/solution_tray( src )
new /obj/item/reagent_containers/glass/solution_tray( src )
new /obj/item/reagent_containers/glass/solution_tray( src )
new /obj/item/reagent_containers/glass/solution_tray( src )
new /obj/item/reagent_containers/glass/solution_tray( src )
new /obj/item/reagent_containers/glass/solution_tray( src )
/obj/item/reagent_containers/glass/beaker/tungsten
name = "beaker 'tungsten'"
/obj/item/reagent_containers/glass/beaker/tungsten/Initialize()
. = ..()
reagents.add_reagent(/singleton/reagent/tungsten,50)
update_icon()
/obj/item/reagent_containers/glass/beaker/oxygen
name = "beaker 'oxygen'"
/obj/item/reagent_containers/glass/beaker/oxygen/Initialize()
. = ..()
reagents.add_reagent(/singleton/reagent/acetone,50)
update_icon()
/obj/item/reagent_containers/glass/beaker/sodium
name = "beaker 'sodium'"
/obj/item/reagent_containers/glass/beaker/sodium/Initialize()
. = ..()
reagents.add_reagent(/singleton/reagent/sodium,50)
update_icon()
/obj/item/reagent_containers/glass/beaker/lithium
name = "beaker 'lithium'"
/obj/item/reagent_containers/glass/beaker/lithium/Initialize()
. = ..()
reagents.add_reagent(/singleton/reagent/lithium,50)
update_icon()
/obj/item/reagent_containers/glass/beaker/water
name = "beaker 'water'"
/obj/item/reagent_containers/glass/beaker/water/Initialize()
. = ..()
reagents.add_reagent(/singleton/reagent/water,50)
update_icon()
/obj/item/reagent_containers/glass/beaker/fuel
name = "beaker 'fuel'"
/obj/item/reagent_containers/glass/beaker/fuel/Initialize()
. = ..()
reagents.add_reagent(/singleton/reagent/fuel,50)
update_icon()
@@ -2,21 +2,6 @@
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
// Miscellaneous xenoarchaeology tools
/obj/item/device/gps
name = "relay positioning device"
desc = "Triangulates the approximate co-ordinates using a nearby satellite network."
icon = 'icons/obj/device.dmi'
icon_state = "locator"
item_state = "locator"
w_class = WEIGHT_CLASS_SMALL
/obj/item/device/gps/attack_self(var/mob/user as mob)
if(!emped)
ui_interact(user)
var/turf/T = get_turf(src)
to_chat(user, SPAN_NOTICE("[icon2html(src, user)] [src] flashes <i>[T.x].[rand(0,9)]:[T.y].[rand(0,9)]:[T.z].[rand(0,9)]</i>."))
/obj/item/device/measuring_tape
name = "measuring tape"
desc = "A coiled metallic tape used to check dimensions and lengths."
@@ -5,7 +5,6 @@
icon = 'icons/obj/xenoarchaeology.dmi'
icon_state = "xenoarch_scanner"
item_state = "xenoarch_scanner"
contained_sprite = TRUE
w_class = WEIGHT_CLASS_SMALL
slot_flags = SLOT_BELT
var/nearest_artifact_id = "unknown"
@@ -9,7 +9,6 @@
icon = 'icons/obj/xenoarchaeology.dmi'
icon_state = "depth_scanner"
item_state = "depth_scanner"
contained_sprite = TRUE
w_class = WEIGHT_CLASS_SMALL
slot_flags = SLOT_BELT
var/list/positive_locations = list()
@@ -5,7 +5,7 @@
/obj/item/device/beacon_locator
name = "locater device"
desc = "Used to scan and locate signals on a particular frequency according ."
icon = 'icons/obj/device.dmi'
icon = 'icons/obj/item/pinpointer.dmi'
icon_state = "pinoff" //pinonfar, pinonmedium, pinonclose, pinondirect, pinonnull
item_state = "electronic"
var/frequency = PUB_FREQ
+2 -1
View File
@@ -3,8 +3,9 @@ GLOBAL_LIST_EMPTY(gps_list)
/obj/item/device/gps
name = "global positioning system"
desc = "Helping lost spacemen find their way through the planets since 2016."
icon = 'icons/obj/telescience.dmi'
icon = 'icons/obj/item/device/gps.dmi'
icon_state = "gps-com"
item_state = "radio"
w_class = WEIGHT_CLASS_SMALL
slot_flags = SLOT_BELT
origin_tech = list(TECH_DATA = 2, TECH_ENGINEERING = 2)
+1
View File
@@ -91,6 +91,7 @@
icon = 'icons/obj/radio.dmi'
icon_state = "beacon"
item_state = "signaler"
origin_tech = list(TECH_BLUESPACE = 3)
/obj/item/device/telepad_beacon/attack_self(mob/user)