Appearance order of screens

I have 2 screens in my scene. I want to send the front screen to back and back screen to front when launching. How can i do that??

Hi @mortal_phoenix,

For 2D UI elements the ordering order is from top to bottom how they are ordered in the entity hierarchy.

I think that holds true for screens as well, can you try that in editor?

1 Like

I tried but it’s still in same order

@jpaulo likely knows all about it


Played with an example project that holds three screens:

Indeed when the project launches the drawing order is from top to bottom (entity hierarchy).

But if you reorder any screen on runtime that isn’t respected anymore. One trick is to toggle on and off all screens, example code I’ve used in the browser console:

// run this twice to toggle on/off'screen').forEach(o => o.entity.enabled = !o.entity.enabled)

I wonder if there is an internal method that is used when that happens. Tried calling this but it didn’t work:


We have a ticket a out controlling the order of UI screens here

The workaround for this is to have single UI screen with element groups as the container for ‘sub screen’ UIs and there order of rendering can be controlled by the hierarchy order.