Esempio n. 1
0
 // Vector2 Tween Constructor
 public HiraTween(Action <Vector2> setter,
                  Vector2 a,
                  Vector2 b,
                  float time,
                  HiraTweenterpolationType tweenType = HiraTweenterpolationType.Linear,
                  HiraTweenEaseType easeType         = HiraTweenEaseType.EaseIn,
                  Action onCompletion = null)
 {
     Time         = time;
     OnIteration  = t => setter(Vector2.LerpUnclamped(a, b, t));
     OnCompletion = onCompletion;
     TweenType    = tweenType;
     EaseType     = easeType;
 }