Пример #1
0
        //onComplete
        public static FastTween TweenScale(this Transform target, float endValue, float duration, Action onComplete)
        {
            var tween     = Pop(target, TransformExtensionTween.TweenType.Scale, onComplete);
            var newVector = new Vector3(endValue, endValue, endValue);

            return(FastTweener.Vector3(target.localScale, newVector, duration, tween.UpdateVector3Action, tween.OnCompleteAction));
        }
Пример #2
0
        //ease ignoreTimescale onComplete
        public static FastTween TweenScale(this Transform target, float endValue, float duration, Ease ease = Ease.Default, bool ignoreTimescale = false, Action onComplete = null)
        {
            var tween     = Pop(target, TransformExtensionTween.TweenType.Scale, onComplete);
            var newVector = new Vector3(endValue, endValue, endValue);

            return(FastTweener.Vector3(target.localScale, newVector, duration, tween.UpdateVector3Action, ease, ignoreTimescale, tween.OnCompleteAction));
        }
Пример #3
0
        //ignoreTimescale onComplete
        public static FastTween TweenScale(this Transform target, Vector3 endValue, float duration, bool ignoreTimescale, Action onComplete = null)
        {
            var tween = Pop(target, TransformExtensionTween.TweenType.Scale, onComplete);

            return(FastTweener.Vector3(target.localScale, endValue, duration, tween.UpdateVector3Action, ignoreTimescale, tween.OnCompleteAction));
        }
Пример #4
0
        //onComplete
        public static FastTween TweenLocalMove(this Transform target, Vector3 endValue, float duration, Action onComplete)
        {
            var tween = Pop(target, TransformExtensionTween.TweenType.LocalMove, onComplete);

            return(FastTweener.Vector3(target.localPosition, endValue, duration, tween.UpdateVector3Action, tween.OnCompleteAction));
        }
Пример #5
0
        //onComplete
        public static FastTween TweenMove(this Rigidbody target, Vector3 endValue, float duration, Action onComplete)
        {
            var tween = Pop(target, RigidbodyExtensionTween.TweenType.Move, onComplete);

            return(FastTweener.Vector3(target.position, endValue, duration, tween.UpdateVector3Action, tween.OnCompleteAction));
        }
Пример #6
0
        //ease ignoreTimescale onComplete
        public static FastTween TweenMove(this Rigidbody target, Vector3 endValue, float duration, Ease ease = Ease.Default, bool ignoreTimescale = false, Action onComplete = null)
        {
            var tween = Pop(target, RigidbodyExtensionTween.TweenType.Move, onComplete);

            return(FastTweener.Vector3(target.position, endValue, duration, tween.UpdateVector3Action, ease, ignoreTimescale, tween.OnCompleteAction));
        }