How I can drag GUI elment?

I tried to use mouse events, but as far as I understood, they overlap each other…

I found PointerDragBehavior, but I do not know how to make it work with rectangle…
Is it possible to do something similar, but with a rectangle?

Thank you in advance!!!

You need to disable isPointerBlocker, so scene receives pointer events. If you also want to drag over other GUI controls, I would suggest to disable isPointerBlocker, while dragging, on all those GUI controls.

Here is a PG example:

4 Likes