How to do z-index respecting ui in both 2d and 3d?

I have a dilemma, the ui thing is really bothering me, but if I can figure it out then cocos is workable for me.

the dilemma is, what if I want to have UI text “number” to mark hotel room doors. But I can’t seem to do that because all ui is rendered always on top of everything else, and it doesn’t respect z index. instead it renders based on sibling order, which even with a parent container doesn’t change that.

How can I have 3D UI respecting z index in cocos creator? How to do z-index respecting ui in both 2d and 3d?

1.You can use sortingOrder to sort the 3D object priority of showing.
2. And use siblingOrder to sort 2D object.
3. 2D objects get higher priority than 3D objects.
You can use the above rules to fulfill your demands.