コード例 #1
0
        // Use this for initialization
        void Start()
        {
            Input.compass.enabled = true;

            clipPlane = new GOClipPlane(Camera.main);

            if (orbitParent)
            {
                objToRotate = transform.parent;
            }
            else
            {
                objToRotate = transform;
            }

            _rigidbody = objToRotate.gameObject.GetComponent <Rigidbody>();

            // Make the rigid body not change rotation
            if (_rigidbody != null)
            {
                _rigidbody.freezeRotation = true;
            }

            updateOrbit(true);
        }
コード例 #2
0
        public static GOClipPlane MainCameraFarClipPlane()
        {
            Camera c = Camera.main;

            GOClipPlane clipPlane = new GOClipPlane(c);

            clipPlane.UpdateNearClipPlane();

            return(clipPlane);
        }
コード例 #3
0
 void Start()
 {
     clipPlane = new GOClipPlane(Camera.main);
 }