Documentation Topics
Article

Customizing Joysticks

After you’ve added a virtual joystick and captured its ID, you can further customize its look and behaviour using additional functions. Joysticks are made up of the following components:

  • The nub: The moveable area that the player drags with his/her thumb.
  • The outline: The outer container representing the area limits of the nub's movement.
  • The notches: The 8 cardinal points around the joystick.
  • The label: A label to display on the nub.

For example, you can set a label sprite on the joystick like this:

PRVirconJoySetLabel(joyId, sPRVircon_Joy1_Lbl4Arrows, 0, 0, 1, 45);

The above code adds a Style 1 "4 Arrows" label to the joystick identified by joyId at a 45 degree angle. You could, of course, use your own custom sprite instead.

More coming soon.