Placing a Context Menu with buttons relative to a Node

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


I’m currently making a grid based tactics game similar to Fire Emblem.
When I click on a character, I want a context menu to pop up that lists several Buttons like “Move”, “Attack” etc.

I made a VBox container and added some buttons, but I don’t know how to make the context menu pop up relatively close to the clicked character.

Thanks in advance.

Instantaite the menu scene and alter its position attribute. Use the position attribute of the character to determine where to position the menu.

Diet Estus | 2018-08-11 15:22

:bust_in_silhouette: Reply From: zen3001

currently in a similar situation so can’t tell you how exactly to do this but this object seems to be usefull for it: