mirror of
https://github.com/SPLURT-Station/S.P.L.U.R.T-Station-13.git
synced 2025-12-10 18:02:57 +00:00
28 lines
1.2 KiB
Plaintext
28 lines
1.2 KiB
Plaintext
|
|
// Checks plants for broken tray icons. Use Advanced Proc Call to activate.
|
|
// Maybe some day it would be used as unit test.
|
|
// -------- IT IS NOW!
|
|
/datum/unit_test/plantgrowth/Run()
|
|
var/list/states = icon_states('icons/obj/hydroponics/growing.dmi')
|
|
states |= icon_states('icons/obj/hydroponics/growing_fruits.dmi')
|
|
states |= icon_states('icons/obj/hydroponics/growing_flowers.dmi')
|
|
states |= icon_states('icons/obj/hydroponics/growing_mushrooms.dmi')
|
|
states |= icon_states('icons/obj/hydroponics/growing_vegetables.dmi')
|
|
states |= icon_states('goon/icons/obj/hydroponics.dmi')
|
|
var/list/paths = subtypesof(/obj/item/seeds) - /obj/item/seeds - typesof(/obj/item/seeds/sample) - /obj/item/seeds/lavaland
|
|
|
|
for(var/seedpath in paths)
|
|
var/obj/item/seeds/seed = new seedpath
|
|
|
|
for(var/i in 1 to seed.growthstages)
|
|
if("[seed.icon_grow][i]" in states)
|
|
continue
|
|
Fail("[seed.name] ([seed.type]) lacks the [seed.icon_grow][i] icon!")
|
|
|
|
if(!(seed.icon_dead in states))
|
|
Fail("[seed.name] ([seed.type]) lacks the [seed.icon_dead] icon!")
|
|
|
|
if(seed.icon_harvest) // mushrooms have no grown sprites, same for items with no product
|
|
if(!(seed.icon_harvest in states))
|
|
Fail("[seed.name] ([seed.type]) lacks the [seed.icon_harvest] icon!")
|