Ejemplo n.º 1
0
        internal static void SetNextPose(this XRControllerRecorder recorder, Vector3 position, Quaternion rotation, bool selectActive, bool activateActive, bool pressActive)
        {
            XRControllerRecording currentRecording = recorder.recording;

            currentRecording.InitRecording();
            currentRecording.AddRecordingFrame(0.0f, position, rotation, selectActive, activateActive, pressActive);
            currentRecording.AddRecordingFrame(1000f, position, rotation, selectActive, activateActive, pressActive);
            recorder.recording = currentRecording;
            recorder.ResetPlayback();
            recorder.isPlaying = true;
        }
 /// <summary>
 /// This function is called when the object becomes enabled and active.
 /// </summary>
 /// <seealso cref="MonoBehaviour"/>
 protected virtual void OnEnable()
 {
     m_Frames = serializedObject.FindProperty("m_Frames");
     m_ControllerRecording = (XRControllerRecording)target;
 }