pouria79 Posted January 17, 2020 Posted January 17, 2020 Hello everyone I'm working on a simple VR shooter game using Wave SDK 3.1.4 and Unity 2019.2.3. The gameplay is rather simple: the player is in an open world scene with some enemy droids around, and he/she presses the touchpad button to shoot. The bullets which are rays, come from two guns on both sides of the player, so the player uses their head for aiming and the controller button to shoot, so the controller's orientation and direction doesn't matter (photo attached) . The problem I'm having is that the controller button doesn't work unless the player is holding it up, facing forward, but I want them to be able to shoot no matter how they're holding the controller. I was wondering if there's any way in Unity to use the controller only for button press and disregard its facing direction/orientation? I have an InputModuleManager and I've set the Raycast Mode to Fixed and Beam Length to 0.01, so we don't see the beam length at least, but the original issue exists. I'd appreciate any tips. Thanks a lot.
pouria79 Posted January 17, 2020 Author Posted January 17, 2020 Forgot to mention, I'm using the old neon blue Vive Focus headset, that only has one small controller, not the Vive focus pro one! @Cotta
pouria79 Posted January 20, 2020 Author Posted January 20, 2020 Thank you so much @Cotta. It worked. ☺️ Only thing is the controller's avatar is still showing up on the headset, along with the beam. Is there a way to make it invisible? If anyone is trying to do the same with the buttons, here is what I did : I removed the Module Manager & Controller Input. So now my scene only has a WaveVRButtons prefabs, which has the TouchPad assigned to the dominant buttons of it, and in code I have this: void Update() { bool pressed = WaveVR_Controller.Input(WaveVR_Controller.EDeviceType.Dominant).GetPressDown(WVR_InputId.WVR_InputId_Alias1_Touchpad); if (pressed) Shoot(); } That's it.
pouria79 Posted January 20, 2020 Author Posted January 20, 2020 @Cotta My bad! The controller doesn't show up anymore unless the menu button is pressed, so it's fine! Is there a way to disable the menu all together?
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now