Open Kecia0001 opened 2 years ago
Sorry, there is no way to set it through code, if necessary, it can be solved through reflection.
anim.SetFieldValue("_interpolator", new CustomizableInterpolator(CustomizableInterpolator.Type.Sine));
Nice way. I instead solved this by using
[SerializeField]
CustomizableInterpolator _interpolator = default;
....
....
....
if (_tween != null && _tween.animationCount > 0)
{
anim_ = (UnityExtensions.Tween.TweenTransformPosition)_tween.GetAnimation(0);
anim_.Interpolate(_interpolator[_tween.normalizedTime]);
}
Inside the LateUpdate method
It seems like I can get access to the animation by using => UnityExtensions.Tween.TweenTransformPosition anim_ = (UnityExtensions.Tween.TweenTransformPosition)_tween.GetAnimation(0);
anim_ has this function => Interpolate
but it doesn't seem to be that qìwhat I'm looking for.
I'd like to set the Interpolation to UnityExtensions.Tween.Interpolator.Sine, How can I achieve this? Thanks