JoystickButtonMenu

Author: Alex Hackl (AKA Silix)

Description
Unity GUI does not fully support joystick navigation which sucks

so here is two custom classes i wrote for just that reason the JoystickButton and JoystickButtonMenu

working together they provide functionality to create buttons that can be navigated by either horizontal or vertical movement and joystick button presses

please note: I am a self taught programmer so this is relatively crude and i have only tested it's functionality against my specific needs.

Usage
First Declare the menus you want then under Start initialize the menu:

the numberOfbuttons is self explanatory but be sure to use that same number as the size of both your rectangle and string array.

the rectangleArray is an array of rectangles that define the position and size of each button, be sure to keep the size the same as the number of buttons.

the stringArray is an array of labels that correspond to the rectangles and will show up as button labels.

the joystickInputAxis is of type JoyAxis which is an enum in the JoystickButtonMenu, syntax goes as such JoystickButtonMenu.JoyAxis.Horizontal

to display the buttons: to detect input:

API:

Here is an example which is the main menu for my current game: