How to dock interface to moving object

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

Like in question how can i dock my interface (like this photo Screenshot by Lightshot) to moving object? I asking because i see on youtube only tutorials with static objects

Edit: if someone know how to resize interface after minimalize or maximalize i would thank

:bust_in_silhouette: Reply From: Zylann

Put that interface as child of that moving object? Or set its position to be the same as the object every frame, using a script. Also make sure that interface is within the same CanvasLayer (or none if the moving object isn’t in one).

For resizing interface when window size changes, look for stretch modes in project settings. Also, make use of anchors, avoid setting static GUI sizes when possible. You may want to take a look at this doc Multiple resolutions — Godot Engine (3.1) documentation in English