file: VirtualJoystick.aus

class: VirtualJoystick

[22:7] extends: Parent

Wraps an AussomVirtualJoystick (subclass of FXGL's abstract VirtualJoystick) so Aussom code can build a custom on-screen analog joystick. Register onGetCenter (returns a Point2D wrapper) and onGetMaxDistance (returns a double); add the background and thumb shapes via the standard JavaFX Parent API on this.obj. Example: vj = new VirtualJoystick(fxgl.getInput()); vj.onGetCenter(::center).onGetMaxDistance(::max);

Methods