Skip to main content
New Participant
April 27, 2017

Unity "game"

Hi, So I'm kinda new to coding and I'm working on a project in Unity with the Oculus. I've plugged in the basic camera and character controller for the Oculus and everything works great. Although I would like to have the controller or mouse be able to look up and down at the same time as using the Oculus similarly to how they allow you to move side to side.

Thanks!
    This topic has been closed for replies.

    8 replies

    Participant
    April 27, 2017
    Did you use the prefab in the Oculus utilities? it should already have both
    New Participant
    April 27, 2017

    js2k said:

    Did you use the prefab in the Oculus utilities? it should already have both

    I am using the prefab, but I dont see the option for that anywhere :(
    Inspiring
    April 27, 2017
    I think by default vertical look is disabled since its very unpleasant when combined with head tracking. Not sure if there's a way around it
    New Participant
    April 27, 2017

    MikeF said:

    I think by default vertical look is disabled since its very unpleasant when combined with head tracking. Not sure if there's a way around it

    I guess, I gotta see it for myself. I'm gonna have a tv next to the Oculus to display the same thing in case somebody doesn't want to put it on so I need this axis of movement, I can't even seem to find it in the code for the prefab controller.
    Inspiring
    April 27, 2017
    In that case i'd recommend having two prefabs, then when mouse input is detected just disable the oculus input and enable the mouse input
    New Participant
    April 27, 2017

    MikeF said:

    In that case i'd recommend having two prefabs, then when mouse input is detected just disable the oculus input and enable the mouse input


    Hmm, interesting, how would that be done?
    Inspiring
    April 28, 2017
    Well there's quite a few ways, but the easiest in your case would be to add a mouse controller script to your camera/player prefab, then have a script attached that will detect mouse input. Once input is detected set vrSettings.enabled = false, then enable your mouse controller logic
    New Participant
    April 29, 2017

    MikeF said:

    Well there's quite a few ways, but the easiest in your case would be to add a mouse controller script to your camera/player prefab, then have a script attached that will detect mouse input. Once input is detected set vrSettings.enabled = false, then enable your mouse controller logic

    hmmm, that seems like a workable solution, could you show me how that would look? like I said I'm pretty new to coding.