/// <summary>
        /// 计算位置信息
        /// </summary>
        void CalculatePos()
        {
            float   percent   = Mathf.InverseLerp(startTime, targetTime, Time.realTimeSinceStartUp);
            Vector2 originPos = currentPos.GetValue();
            Vector2 target    = Vector2.Lerp(fromPos, targetPos.GetValue(), percent);

            posControl.SetPos(target);
            currentPos.SetValue(target);
        }
Beispiel #2
0
 private void OnArriveTarget(IE_ArriveTarget obj)
 {
     currentAnim.SetValue("stand");
 }