Overlapping decals don’t keep the order their ZIndex sets. Which decal draws on top depends on the camera’s horizontal view direction:
When the camera faces more to the right, the decals render correctly. The decal with the higher ZIndex draws in front.
When the camera faces more to the left, the decal that should be in front always drops behind the decal under it. Its ZIndex makes no difference.
This doesn’t flicker or fade. The order flips cleanly at the point where the camera’s view direction crosses over, and it stays wrong for every angle on the “left” side.
In my case, an “OPENING SOON” banner decal sits on top of an arcade decal.
Screenshot 1 (camera facing slightly right): the banner correctly renders over the screen art.
Screenshot 2 (camera facing slightly left): the banner moves behind the screen art. Only its corner sticks out past the screen’s border.
There are a few cases where the decals get sorted despite the ZIndex, and that sort depends on the view direction, so it could explain what you’re seeing.
Would you mind checking some of these on the parent part, and see if tweaking it helps?
the part has Transparency or LocalTransparencyModifier above 0
the part uses ForceField
the part has a SurfaceAppearance or MaterialVariant with alpha transparency.
In the provided examples, both opaque decals were on transparent Plastic parts, no additional children aside from the decal.
Setting either of the two decals’ parts to transparency 0 fixes it, but then I lose my rounded corners, and shouldn’t really have to do that in the first place
It seems to happen with transparent/semi-transparent parts as a whole, rather than just decals
I see, thanks for the extra info. You mean the decals are on different parts? ZIndex sorting only works for decals that are on the same face of the same part:
So Z Index cannot be used to sort decals across an entire scene… If you set the parent part to opaque, that forces it to draw first, together with its decal(s).
I understand, but I should not have to do this, and there are many cases where this would not be ideal.
Unless this is intended behavior for decals on transparent parts? they are supposed to flip behind each other when the camera angle changes?
I believe they are sorted based on line of sight, not purely distance to the camera, so changing the view direction can change the sorting order, indeed… And if the transparent parts flip, their decals flip with them.
decals and textures unfortunately don’t actually apply to the part, it’s a hack that should’ve been replaced with something solid a (very) long time ago. one part of what’s done is an invisible clone of the part’s geometry is made. we don’t really know what the code looks like or does exactly beyond that, but it’s pretty clear it needs a rewrite
here’s two parts that meet perfectly together. one has a decal on the side. despite that, the decal bleeds through.
this is another bug that’s likely been reported to death for over a decade to no avail, like the render distance issue that breaks every game on the platform that i’m assuming management forbids them from fixing because they don’t know what they’re doing and think it’s bad for developers to have control over render distance somehow lol