Add the ability to unset sprites on GUI elements
Add the ability to unset sprites on GUI elements
Currently, you can set a sprite to a supported GUI element anytime you like, you don't have to set it when creating the element. You can't however unset it after it's been set. Setting it to nil gives an error and setting it to an empty string doesn't do anything. I'd like to be able to unset the sprite without recreating the whole element, preferably by setting it to nil, but whatever works.
Re: Add the ability to unset sprites on GUI elements
As a note, writing nil to a sprite or sprite-button gives an error. Writing empty string to a sprite clears the element, but writing empty string to a sprite-button does nothing.
Miniloader — UPS-friendly 1x1 loaders
Bulk Rail Loaders — Rapid train loading and unloading
Beltlayer & Pipelayer — Route items and fluids freely underground
Bulk Rail Loaders — Rapid train loading and unloading
Beltlayer & Pipelayer — Route items and fluids freely underground
Re: Add the ability to unset sprites on GUI elements
Yes exactly. What's even worse is that when you set it to an empty string, the sprite will still be shown visually, but reading .sprite will return the empty string, which is obviously not the sprite that's displayed.