Download

Best way to do controller input in UI

As we’re progressing with our game, we have a finished main menu. However, as we plan to also make it available with VR (Oculus without Touch), we want to be able to use an XBOX controller to navigate the menus. We could use the Widget Interaction Component to look at buttons and use the controller to click them, but we still want to use the controller to navigate, even outside VR.

I have searched and have found a number of different solutions. But many are two to four years old. I am aware of the focus properties to enable focus, then use the stick or arrow keys to navigate, but our menus consist of a number of custom user widgets and popup menus, which more or less breaks the focus on certain widgets when navigating. On top of that, widgets also lose focus if you accidentally press the mouse button outside of the widget itself.

Our “front end” menu consists of two widgets: a main menu and an options menu. The buttons are also custom user widgets to have more control over animations and effects. The options menu has custom widgets to allow for scrolling the options list left and right. When you hover over them, they become highlighted and you can use the left and right arrow keys on the keyboard to scroll, as well as the arrow buttons.

https://youtube.com/watch?v=97pIXBomKpA

Now, we really want to use the controller to navigate. So, out of all the various solutions, which one is the most viable/optimal way of doing it?