is there any downsides of putting panel in the relation of camera?

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By Yashraj Basan

Hello everybody,

I am new to godot game engine. so, from last couple weeks, i am learning game development from BornCG tutorial. in one of the tutorial (part 12) where he creating panels. he is putting panel in the relation of the game window not in the relation of camera. i am just little curious. any help is appericated. thank you.

:bust_in_silhouette: Reply From: p7f

GUI should not be child of the Camera… If you want a smooth camera movement in relation with the character, or if you implement camera shake (very very comon), you would end up moving also the GUI, and thats not usually desired effect.

The best way for all GUI imho is to add them as childs of a CanvasLayer node, so they always stay fixed in the screen, no matter what happens to the Camera, player, or whatever other node.

Thank you for responding. whenever i create panel and i put in the relation of window. i can’t see that panel in game.

Yashraj Basan | 2020-09-20 17:03

You should share here how you are setting up your scene and panels. Its hard to tell without seeing your specific setup… or perhaps you could make a small project whith the issue and share it so i can test.

p7f | 2020-09-20 17:26