예제 #1
0
        public void AbortSmoothRotation()
        {
            GOEEntityRotation rotate = this.GetComponent <GOEEntityRotation>();

            if (rotate != null)
            {
                rotate.Abort();
            }
        }
예제 #2
0
        public void InterruptRotation(Quaternion target)
        {
            GOEEntityRotation rotate = this.GetComponent <GOEEntityRotation>();

            if (rotate != null)
            {
                rotate.InterruptRotation();
            }
            this.Rotation = target;
        }
예제 #3
0
        public void StartSmoothRotation(Quaternion target, float rotationSpeed = -1)
        {
            GOEEntityRotation rotate = this.GetComponent <GOEEntityRotation>();

            if (rotate == null)
            {
                rotate = this.AddComponent <GOEEntityRotation>();
            }
            rotate.IsRotationSpeedUniform = isRotationSpeedUniform;

            if (rotationSpeed < 0)
            {
                rotationSpeed = this.rotationSpeed;
            }
            rotate.StartRotation(target, rotationSpeed);
        }