Skip to main content
Inspiring
September 13, 2016
Solved

How do you add more XBOX Buttons support when the product only has support for movement?

  • September 13, 2016
  • 2 replies
  • 769 views
I got a product for making VR game. it has a character controller with a body. you can walk/run and rotate but that's about it. It is not based on OVR utilities  So can't do the if (OVR.Input etc).

Do i have to map the buttons using the Edit/Project Setttings/Input Manager?
and then to check i would do if( Input.getButton(Button.three) )  etc etc?

is that how it works?
This topic has been closed for replies.
Best answer by vrdaveb
That sounds like a good approach. OVRPlayerController is considered a template for you to modify as needeed. If you really don't want to change it, you can always wrap the protected members with public ones in the derived class.

2 replies

Inspiring
September 13, 2016
You can add checks in say the "update() function for the OVR input etc. You need to have the OVR manager in your scene usually.

I just started with the OVR unity utilities package. And then go from there. It has examples of how to deal with input etc. (jump and run etc) . If you take the functionality of say the third person controller (Ethan) and drop it into the OVR player controller then you get an animated avatar.

Its pretty easy to setup

I have a custom player controller that inherits from the OVR controller (tho I had to make a lot of the protected attributes public to share them ...is that the correct way to do it..I wish I could inherit without modifying the origin OVR script). I overload some of the functions to suit my requirements. In particular the movement and input ones.

If you are starting from a different character package it may be more difficult. I guess you can jsut add the OVR camera rig (that comes with OVR manager attached usually) Then you can start calling OVR.input


Drift VFX Visual, Virtual , Vertical Want 970GTX on Macbook for good FPS? https://forums.oculus.com/viewtopic.php?f=26&t=17349
vrdavebAnswer
Inspiring
September 13, 2016
That sounds like a good approach. OVRPlayerController is considered a template for you to modify as needeed. If you really don't want to change it, you can always wrap the protected members with public ones in the derived class.