Virtual On Screen Joystick: Sticking to the edge, a better way?


I have created a virtual joystick that works well until it reaches it’s maximum distance at which point it “Sticks” to the edge.

Is there a better way to accomplish this? I have added an example below of it sticking, I’d like to to “flow” down/up when the mouse/touch is pulling outside of its boundary.

The joy stick part is a the Draggable behavior.


How I am keeping it within the boundary:


1 Like

Exactly what I was looking for weeks. Thanks man!