If you are making a game targetting Cardboard or Daydream platform. You might need to dump the GvrEditorEmulator prefab came with GoogleVR package into the scene and pair a camera with it.
Let's say this is how you setup your scene :
- You have to child the camera within a GameObject parent.
- The parent have a shape.
- The camera should be at the "head" of the parent which deviates away from the center of the parent.
- You have GvrEditorEmulator paired with that camera and enabled.
The good thing is that you can pan around to view 360 degrees by tapping Alt + mouse moving around
.
However, it appears that the camera is sinking downward.
The GvrEditorEmulator script will always try to default the local position (position relative to the parent) of the camera to Vector3.Zero which is (0, 0, 0).
To prevent that :
// line 90
m_camera.transform.localPosition = neck;
// line 103
m_camera.transform.localPosition = Vector3.Zero;
Open up GvrEditorEmulator script with your favourite IDE and comment out the lines at 90 and 103.
That should prevent the camera from sinking downward from the intended y position.
Top comments (0)