Download

Virtual pad problem.

How do i disallow virtual pad location from moving around (whole widget, not thumbsticks inside), they are snapping to new touch location in some area, and i want whole pad to stay put in same spot (excluding thumbstics ofc.)

I could recreate its functionality in UMG, but i went for those virtual pads for simplicity of code. If i can force them to stay in same position (relative to screen),
For eg. I can make throttle slider by masking horizontal axis of pad and allowing only vertical, etc. Those pads have nice functions, and produce elegant blueprints when used.

There is a “Prevent Recenter” checkbox in the Touch Interface. Make a duplicate of DefaultVirtualJoysticks (found in Engine/MobileResources/HUD) and rename it something like NoRecenterVirtualJoysticks. Double-click it to edit it and check the “Prevent Recenter”. You may also change the locations, sizes, and images of the sticks if you want. In the Engine->Input panel in the Project Settings, change the “Default Touch Interface” to your new NoRecenterVirtualJoysticks asset.