Help with using ZIndex in SurfaceGuis

I’ve made a surface gui in the StarterCharacter that is meant to be used to display a weapon. I’ve chosen to use a surface gui for this so that it can be manipulated in 3d space (similar to weapons in minecraft), and I’ve been having a problem with this.

Here’s my problem, other surface guis are being rendered on top of the one in the StarterCharacter despite being further away.
Here’s a video demonstrating what I mean:


The smiley face is part of the StarterCharacter and it’s having bad interactions with the walls, ceiling, and floor, which are other surface guis.

The smiley face has a ZIndex of 100 while the other surface guis have a ZIndex ranging from 1-3. I’ve also been playing around with ZIndexBehavior; however, both the sibling and global settings don’t seem to fix the problem.

With all this said, how do I make the smiley face be rendered last and always on top of the other surface guis? Does the ZIndex only work with other children of same surface gui? If so, how do I work around this?

1 Like

You should turn on the AlwaysOnTop property if you want the SurfaceGui to be able to see through everything