oculus rift store assets
This commit is contained in:
parent
79ab0effec
commit
1ba1676d0e
3 changed files with 448 additions and 1051 deletions
|
@ -12,7 +12,7 @@ MonoBehaviour:
|
|||
m_Script: {fileID: 11500000, guid: b3d881e962d099f4a8eb492ef7e9a8c0, type: 3}
|
||||
m_Name: OculusPlatformSettings
|
||||
m_EditorClassIdentifier:
|
||||
ovrAppID:
|
||||
ovrAppID: 3471470396225158
|
||||
ovrMobileAppID: 3156518597752790
|
||||
ovrUseStandalonePlatform: 0
|
||||
ovrEnableARM64Support: 0
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -11,6 +11,7 @@ public class Rig : MonoBehaviour
|
|||
public Main main;
|
||||
public GameObject disconnected;
|
||||
public Transform head, hangingRod;
|
||||
public Camera recordCam;
|
||||
|
||||
[Header("Variables")]
|
||||
public OVRInput.Controller remote;
|
||||
|
@ -22,7 +23,7 @@ public class Rig : MonoBehaviour
|
|||
Vector3 headOffset;
|
||||
public Vector3 boxShake, boxOffset;
|
||||
|
||||
public bool ready;
|
||||
public bool ready, alignRecordCam;
|
||||
|
||||
void Start()
|
||||
{
|
||||
|
@ -33,6 +34,8 @@ public class Rig : MonoBehaviour
|
|||
headOffset.y = design.headOffset.y;
|
||||
headOffset.z = design.headOffset.z;
|
||||
ready = false;
|
||||
|
||||
recordCam.gameObject.SetActive(Application.isEditor);
|
||||
}
|
||||
|
||||
void Update()
|
||||
|
@ -89,6 +92,16 @@ public class Rig : MonoBehaviour
|
|||
head.position += boxOffset;
|
||||
|
||||
|
||||
// Record Cam
|
||||
Vector3 twoDir = new Vector3(head.position.x, 0, head.position.z).normalized;
|
||||
Vector3 recPos = (Quaternion.LookRotation(twoDir) * new Vector3(0.5f, 0.25f, 0.5f).normalized * 40);
|
||||
if (alignRecordCam)
|
||||
{
|
||||
recordCam.transform.position = recPos;
|
||||
recordCam.transform.rotation = Quaternion.LookRotation(-recPos);
|
||||
}
|
||||
|
||||
|
||||
// controllerRot = OVRInput.GetLocalControllerRotation(remote) * Quaternion.Euler(-30, 0, 0);
|
||||
Vector3 headsetPos = InputTracking.GetLocalPosition(XRNode.Head);
|
||||
|
||||
|
|
Reference in a new issue