0 votes

If i put a tilemap into my scene, the UI (Autoloaded), or what ever node is added to the scene tree (via get_tree().get_root().add_child(Object)) Does not show.

How do you avoid this?

in Engine by (273 points)

you can set the Z axis to something other than 0(assuming you are on 2D)

1 Answer

+2 votes
Best answer

The proper manner would be using a CanvasLayer, and putting your entire UI inside it. That way it'll always be on camera and above everything.

About other nodes, though; the bottom-most node is always rendered first, and the top-most is always rendered last. If you put your TileMap as the top-most node of your root, or even make the root itself a TileMap, other nodes won't be covered.

by (1,120 points)
selected by
Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read Frequently asked questions and How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to [email protected] with your username.