예제 #1
0
        public Vector2 LerpedLocalScale(float time)
        {
            if (previous == null)
            {
                return(localScale);
            }
            float t = (this.time.time - time) / this.time.deltaTime;

            if (t < 0 || t > 1)
            {
                UnityEngine.Debug.Log("t " + t);
            }
            return(Vector2.Lerp(((Transform)previous).localScale, localScale, t));
        }
예제 #2
0
        public Vector2 LerpedPosition(float time)
        {
            if (previous == null)
            {
                return(position);
            }
            float t = (this.time.time - time) / this.time.deltaTime;

            if (t < 0 || t > 1)
            {
                UnityEngine.Debug.Log("t " + t);
            }
            return(Vector2.Lerp(((Transform)previous).position, position, t));
        }