[MIRROR] Add support for GAGS to design asset list generation (#7086)

* add support for GAGS to design asset list generation (#60366)

* Add support for GAGS to design asset list generation

Co-authored-by: Bobbahbrown <bobbahbrown@gmail.com>
This commit is contained in:
SkyratBot
2021-07-26 15:45:06 +01:00
committed by GitHub
co-authored by Bobbahbrown
parent 205cfb2252
commit 393bf1425c
+8 -2
View File
@@ -377,9 +377,15 @@
if (machine)
item = machine
icon_file = initial(item.icon)
icon_state = initial(item.icon_state)
// 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