ZIndex not working when I disable ScreenGUI

I have in my game a main menu that I want to override all other UIs in the game. When I open the shop from the menu, or the settings, you can see in the video below that it overrides all other UIs perfectly fine: however, as soon as I click inventory (which hides all other UIs by disabling them), the main menu no longer overrides the other UIs. The UI in the bottom left corner of the video below instead overrides the menu.

Here’s the video sample:

(Sorry I had to go fast to keep the file size below 10MB)
I’ve tried a bunch of things, researched, but I couldn’t find where anyone else was having the same issue and I can’t seem to figure out a solution other than to scratch all my hard work…

It’s possible that the 2 UIs have the same effective ZIndex, resulting in it changing which one is displayed when the UI is reenabled.

Is the ZIndex of the frames you want to be in front set to a higher value than the ones that are meant to be behind?

That is a beautiful UI …
Maybe try pushing that main UI off screen vs disabling it.

1 Like

I’m not too sure what you are meaning by effective, but they do not have the same ZIndex. All the other UIs have ZIndexes of 0 or lower while the menu is 1 or higher.

Thanks for the compliments. I’m sure that would probably work, but that would also require a ton of work (and I mean, A LOT) that I’d like to, if possible, avoid.

Not really, simply moving the UI position. If you can’t figure it out any other way, would be better than “scratch all my hard work”. Good luck.