Search Unity

Overriding steamVR rotation,transform?

Discussion in 'AR/VR (XR) Discussion' started by pan-master, Apr 21, 2018.

  1. pan-master

    pan-master

    Joined:
    Nov 11, 2013
    Posts:
    127
    I want to make FPS like steamVR controller, I would like to take rotation of HMD, and then I would like to move forward direction relative to HMD. I know its possible, but Kinda lack of ideas how to acomplish that.
    parent.transform.Translate(camera.transform.forward*1*timeDeltaTime), does not work correctly, since rotation of parent during these movments stays the same, it wont update
    I also tryed to, Transform.Rotate() which will rotate steamVR controller Left/Right, however this rotation acts strage, Visualy Camera/controlers rotates 90% correctly however it looks like parent transform does not rotate at all, and applying transform.Translate will result in movment in wrong dirrections
     
    zaozhuangwang likes this.