Add sprite faded_percent to LuaGuiElement

Place to ask discuss and request the modding support of Factorio. Don't request mods here.
User avatar
PennyJim
Fast Inserter
Fast Inserter
Posts: 188
Joined: Wed Jan 18, 2023 3:49 am
Contact:

Add sprite faded_percent to LuaGuiElement

Post by PennyJim »

The engine uses faded (desaturated?) sprites for filter slots, there does not seem to be any way for us to do the same for our sprites or sprite-buttons.
If the engine enables/disables it instead of applying some percentage value, I don't mind if it's is_faded instead.

Even if my requests (135618, 135616) get implemented, that leaves me unable to make the 'empty' fluidbox properly showcase a filter. Maybe I could if I were to make a sprite prototype for every possible fluid, but being able to do it the same way the engine does it would be preferred.
Difference between engine (left) and mod (right)
Difference between engine (left) and mod (right)
08-11-2026, 14-57-06.png (5.9 KiB) Viewed 120 times
User avatar
Shemp
Long Handed Inserter
Long Handed Inserter
Posts: 73
Joined: Mon Jan 19, 2026 6:51 pm
Contact:

Re: Add sprite faded_percent to LuaGuiElement

Post by Shemp »

+1, I would like this for Buckets.

You can make the sprite kind of fade out by setting button.enabled = false, but this turns the background grey and doesn't play well with the "red_inventory_slot" style.
User avatar
protocol_1903
Filter Inserter
Filter Inserter
Posts: 539
Joined: Fri Sep 09, 2022 4:33 pm
Contact:

Re: Add sprite faded_percent to LuaGuiElement

Post by protocol_1903 »

This might be caused by the sprite being rendered in front of the background red in the custom variation, as opposed to behind it in the crafter UI. If so, it might be nice to have a property in EmptySpriteInfo that specifies an "overlay color" or whether to render the usual red overlay when empty. I'd be using it for a similar case of crafting-like UI, where turning the 'unfulfilled' overlay on and off would be necessary.
pY and pYblock developer, wielder of fluid networks and subtick events in arbitrary ways. I make mods. Check them out, maybe.
https://mods.factorio.com/user/protocol_1903

Buy me a coffee
User avatar
Osmo
Filter Inserter
Filter Inserter
Posts: 338
Joined: Wed Oct 23, 2024 12:08 pm
Contact:

Re: Add sprite faded_percent to LuaGuiElement

Post by Osmo »

+1, some form of transparency would be useful
Post Reply

Return to “Modding interface requests”