Page 1 of 1

[0.18.24] Every individual layer within an icon casts a shadow

Posted: Tue May 12, 2020 9:53 pm
by kirazy
I'm making a mod that allows for user-customizable color definitions, and so of necessity I can't bake icons down to one color sprite.

I have the following issue, when I have sprites that have multiple layers, each layer is casting a shadow, and the shadow is cast on the layer below it, which looks weird for some entities and less so for others, but for example:

Image
Calling attention to the way that the shell on the construction robot item on the belt seems to stand point more than it should, and the way the arrows on the miniloader also pop out.

I have the entities used to make the icon on the right for comparison.

I also made this example that shows just the base layer used for the sprites, compared to the icon with all the layers:
Image

This may not be the best entity to convey the issue, since the shell is casting a shadow more or less where it should be, but in the animation above you should notice that the shadow becomes more dark, more intense when all the layers are turned on.

Re: [0.18.24] Every individual layer within an icon casts a shadow

Posted: Wed May 13, 2020 6:07 am
by posila
I think we will have to bake layered icons on startup eventually, but for time being I am moving this to won't fix so people don't account with the fix coming in some distant future and try to avoid using layered icons when possible.

Re: [0.18.24] Every individual layer within an icon casts a shadow

Posted: Wed May 13, 2020 6:22 am
by kirazy
Gotcha. I look forward to the eventual baking. :D

Re: [0.18.24] Every individual layer within an icon casts a shadow

Posted: Sun Jul 28, 2024 9:00 pm
by ArchEzekiel
This still exists in [1.1.109], and I'm making this addition for documentations' sake. I ran into the same issue when using pictures for my items, and the issue goes away when disabling "item shadows" in the graphics settings. Good luck on Factorio: SA development devs!

When using pictures
pictures.PNG
pictures.PNG (102.4 KiB) Viewed 1049 times
When using icons
icons.PNG
icons.PNG (108.07 KiB) Viewed 1049 times
When the setting mentioned is off, and basically how I would expect it to look
graphics_off.PNG
graphics_off.PNG (131.3 KiB) Viewed 1049 times

Re: [0.18.24] Every individual layer within an icon casts a shadow

Posted: Thu Jul 31, 2025 1:23 pm
by Quezler
Just ran into this 5 years down the line, i must say that it is rather annoying that you cannot opt-out specific items to do the shadow yourself or any other way to bypass it other than generating the layered sprites yourself outside of the game, each layer casting a shadow is rather problematic.

Re: [0.18.24] Every individual layer within an icon casts a shadow

Posted: Thu Jul 31, 2025 2:11 pm
by Osmo
Running into this issue myself with my own icons, and also noting that it happens with base game barrel icons, especially visible at the top, where there is a cutout in the shadow near the thing sticking out of the lid and it looks like it "casts an inverse shadow"
изображение.png
изображение.png (230.94 KiB) Viewed 154 times

Re: [0.18.24] Every individual layer within an icon casts a shadow

Posted: Fri Aug 01, 2025 1:42 pm
by Quezler
does look like there is _some_ support internally, items that render as part of blueprint (book) icons get a pass on being shadowed, as well as draw_as_light on the picture variations but that last one is pretty useless since it stops the sprite itself from rendering, and draw_as_glow still has the excess shadow), hmm.