Exemplo n.º 1
0
 /// <summary>
 /// validation checks to make sure the target has a valid property with an accessible setter
 /// </summary>
 public override bool validateTarget(object target)
 {
     // cache the setter
     _setter = GoTweenUtils.setterForProperty <Action <Vector2> >(target, propertyName);
     return(_setter != null);
 }
Exemplo n.º 2
0
    public override void tick(float totalElapsedTime)
    {
        var easedTime = _easeFunction(totalElapsedTime, 0, 1, _ownerTween.duration);

        _target.localScale = GoTweenUtils.unclampedVector3Lerp(_startValue, _diffValue, easedTime);
    }
Exemplo n.º 3
0
 /// <summary>
 /// sets the ease type for this tween property
 /// technically, this should be an internal method
 /// </summary>
 public void setEaseType(GoEaseType easeType)
 {
     _easeFunction = GoTweenUtils.easeFunctionForType(easeType, _ownerTween);
 }
Exemplo n.º 4
0
 public override bool validateTarget(object target)
 {
     _setter = GoTweenUtils.setterForProperty <Action <float> >(target, propertyName);
     return(_setter != null);
 }
Exemplo n.º 5
0
 /// <summary>
 /// sets the ease type for this tween property
 /// technically, this should be an internal method
 /// </summary>
 public void setEaseType(EaseType easeType)
 {
     _easeFunction = GoTweenUtils.easeFunctionForType(easeType);
 }
    public override void tick(float totalElapsedTime)
    {
        float easedTime = _easeFunction(totalElapsedTime, 0, 1, _ownerTween.duration);

        _target.material.color = GoTweenUtils.unclampedColorLerp(_startValue, _diffValue, easedTime);
    }