mirror of
https://github.com/Citadel-Station-13/Citadel-Station-13-RP.git
synced 2025-12-09 15:28:26 +00:00
* Time to become our TGUI God. * Visually sprucing the copyrights. These shouldn't be ignored :) * babababa * https://github.com/tgstation/tgstation/pull/50422 * dooootdooot * Holy fuck Updates the tools folder Updates our build tooling Updates TGUI MASSIVELY I'm going to go scream in a hole now * ?? * Was it this dum thing? * orrrr * It's this isn't it * Did it manually * hubah * TGUI Changelog * oops * What if I use the original? * Lets try this again * Shit commenting out for now * asdasd * Fuck it use the old one and remember to replace later * Updates yarn.lock * Lets try something horrid * Nope it HATES THAT * fucc * The great eslinting * HOLY SHIT * Final? * ? * asd tgstation/tgstation/pull/59914 tgstation/tgstation/pull/66317 * Improved Asset handling. * Oops * Subsystem stuff * Recompiles the Changelong again. * Finally Fixed Communicators * Compiled Changelogs... AGAIN
64 lines
2.3 KiB
Plaintext
64 lines
2.3 KiB
Plaintext
// Representative icons for each research design
|
|
/datum/asset/spritesheet/research_designs
|
|
name = "design"
|
|
|
|
/datum/asset/spritesheet/research_designs/create_spritesheets()
|
|
for (var/path in subtypesof(/datum/design))
|
|
var/datum/design/D = path
|
|
|
|
var/icon_file
|
|
var/icon_state
|
|
var/icon/I
|
|
|
|
if(initial(D.research_icon) && initial(D.research_icon_state)) //If the design has an icon replacement skip the rest
|
|
icon_file = initial(D.research_icon)
|
|
icon_state = initial(D.research_icon_state)
|
|
if(!(icon_state in icon_states(icon_file)))
|
|
warning("design [D] with icon '[icon_file]' missing state '[icon_state]'")
|
|
continue
|
|
I = icon(icon_file, icon_state, SOUTH)
|
|
|
|
else
|
|
// construct the icon and slap it into the resource cache
|
|
var/atom/item = initial(D.build_path)
|
|
if (!ispath(item, /atom))
|
|
// biogenerator outputs to beakers by default
|
|
if (initial(D.build_type) & BIOGENERATOR)
|
|
item = /obj/item/reagent_containers/glass/beaker/large
|
|
else
|
|
continue // shouldn't happen, but just in case
|
|
|
|
// circuit boards become their resulting machines or computers
|
|
if (ispath(item, /obj/item/circuitboard))
|
|
var/obj/item/circuitboard/C = item
|
|
var/machine = initial(C.build_path)
|
|
if (machine)
|
|
item = machine
|
|
|
|
// Check for GAGS support where necessary
|
|
var/greyscale_config = initial(item.greyscale_config)
|
|
var/greyscale_colors = initial(item.greyscale_colors)
|
|
if (greyscale_config && greyscale_colors)
|
|
icon_file = SSgreyscale.GetColoredIconByType(greyscale_config, greyscale_colors)
|
|
else
|
|
icon_file = initial(item.icon)
|
|
|
|
icon_state = initial(item.icon_state)
|
|
if(!(icon_state in icon_states(icon_file)))
|
|
warning("design [D] with icon '[icon_file]' missing state '[icon_state]'")
|
|
continue
|
|
I = icon(icon_file, icon_state, SOUTH)
|
|
|
|
// computers (and snowflakes) get their screen and keyboard sprites
|
|
if (ispath(item, /obj/machinery/computer) || ispath(item, /obj/machinery/power/solar_control))
|
|
var/obj/machinery/computer/C = item
|
|
var/screen = initial(C.icon_screen)
|
|
var/keyboard = initial(C.icon_keyboard)
|
|
var/all_states = icon_states(icon_file)
|
|
if (screen && (screen in all_states))
|
|
I.Blend(icon(icon_file, screen, SOUTH), ICON_OVERLAY)
|
|
if (keyboard && (keyboard in all_states))
|
|
I.Blend(icon(icon_file, keyboard, SOUTH), ICON_OVERLAY)
|
|
|
|
Insert(initial(D.id), I)
|