1234567891011121314151617181920212223 |
- using System.Collections;
- using System.Collections.Generic;
- using UnityEngine;
- public class AddOnCamera : MonoBehaviour
- {
- public Transform LeftController, RightController;
- public Quaternion LeftControllerRotation, RightControllerRotation;
- private void OnPreRender()
- {
- //Debug.Log("OnPreRender:=========" + LeftControllerRotation+" "+ RightControllerRotation);
- if (LeftController)
- {
- LeftController.rotation = LeftControllerRotation;
- }
- if (RightController)
- {
- RightController.rotation = RightControllerRotation;
- }
- }
- }
|