DOTween
0.8.530
|
Methods that extend Tween objects and allow to set their parameters More...
Static Public Member Functions | |
static T | SetAutoKill< T > (this T t) |
Sets the autoKill behaviour of the tween. Has no effect if the tween has already started More... | |
static T | SetAutoKill< T > (this T t, bool autoKillOnCompletion) |
Sets the autoKill behaviour of the tween. Has no effect if the tween has already started More... | |
static T | SetId< T > (this T t, object id) |
Sets an ID for the tween, which can then be used as a filter with DOTween's static methods. More... | |
static T | SetTarget< T > (this T t, object target) |
Sets the target for the tween, which can then be used as a filter with DOTween's static methods. More... | |
static T | SetLoops< T > (this T t, int loops) |
Sets the looping options for the tween. Has no effect if the tween has already started More... | |
static T | SetLoops< T > (this T t, int loops, LoopType loopType) |
Sets the looping options for the tween. Has no effect if the tween has already started More... | |
static T | SetRecyclable< T > (this T t) |
Allows the tween to be recycled after being killed. More... | |
static T | SetRecyclable< T > (this T t, bool recyclable) |
Sets the recycling behaviour for the tween. More... | |
static T | SetUpdate< T > (this T t, bool isIndependentUpdate) |
Sets the update type to UpdateType.Default and lets you choose if it should be independent from Unity's Time.timeScale More... | |
static T | SetUpdate< T > (this T t, UpdateType updateType, bool isIndependentUpdate=false) |
Sets the type of update (default or independent) for the tween More... | |
static T | OnStart< T > (this T t, TweenCallback action) |
Sets the onStart callback for the tween. Called the first time the tween is set in a playing state, after any eventual delay More... | |
static T | OnPlay< T > (this T t, TweenCallback action) |
Sets the onPlay callback for the tween. Called when the tween is set in a playing state, after any eventual delay. Also called each time the tween resumes playing from a paused state More... | |
static T | OnRewind< T > (this T t, TweenCallback action) |
Sets the onRewind callback for the tween. Called when the tween is rewinded, either by calling More... | |
static T | OnUpdate< T > (this T t, TweenCallback action) |
Sets the onUpdate callback for the tween. Called each time the tween updates More... | |
static T | OnStepComplete< T > (this T t, TweenCallback action) |
Sets the onStepComplete callback for the tween. Called the moment the tween completes one loop cycle, even when going backwards More... | |
static T | OnComplete< T > (this T t, TweenCallback action) |
Sets the onComplete callback for the tween. Called the moment the tween reaches its final forward position, loops included More... | |
static T | OnKill< T > (this T t, TweenCallback action) |
Sets the onKill callback for the tween. Called the moment the tween is killed More... | |
static T | SetAs< T > (this T t, Tween asTween) |
Sets the parameters of the tween (id, ease, loops, delay, timeScale, callbacks, etc) as the parameters of the given one. Doesn't copy specific SetOptions settings: those will need to be applied manually each time. More... | |
static T | SetAs< T > (this T t, TweenParms tweenParms) |
Sets the parameters of the tween (id, ease, loops, delay, timeScale, callbacks, etc) as the parameters of the given TweenParms. More... | |
static Sequence | Append (this Sequence s, Tween t) |
Adds the given tween to the end of the Sequence. Has no effect if the Sequence has already started More... | |
static Sequence | Prepend (this Sequence s, Tween t) |
Adds the given tween to the beginning of the Sequence, pushing forward the other nested content. Has no effect if the Sequence has already started More... | |
static Sequence | Insert (this Sequence s, float atPosition, Tween t) |
Inserts the given tween at the given time position in the Sequence, automatically adding an interval if needed. Has no effect if the Sequence has already started More... | |
static Sequence | AppendInterval (this Sequence s, float interval) |
Adds the given interval to the end of the Sequence. Has no effect if the Sequence has already started More... | |
static Sequence | PrependInterval (this Sequence s, float interval) |
Adds the given interval to the beginning of the Sequence, pushing forward the other nested content. Has no effect if the Sequence has already started More... | |
static Sequence | AppendCallback (this Sequence s, TweenCallback callback) |
Adds the given callback to the end of the Sequence. Has no effect if the Sequence has already started More... | |
static Sequence | PrependCallback (this Sequence s, TweenCallback callback) |
Adds the given callback to the beginning of the Sequence, pushing forward the other nested content. Has no effect if the Sequence has already started More... | |
static Sequence | InsertCallback (this Sequence s, float atPosition, TweenCallback callback) |
Inserts the given callback at the given time position in the Sequence, automatically adding an interval if needed. Has no effect if the Sequence has already started More... | |
static T | From< T > (this T t) |
Changes a TO tween into a FROM tween: sets the current target's position as the tween's endValue then immediately sends the target to the previously set endValue. More... | |
static T | From< T > (this T t, bool isRelative) |
Changes a TO tween into a FROM tween: sets the current target's position as the tween's endValue then immediately sends the target to the previously set endValue. More... | |
static T | SetDelay< T > (this T t, float delay) |
Sets a delayed startup for the tween. More... | |
static T | SetRelative< T > (this T t) |
Sets the tween as relative (the endValue will be calculated as More... | |
static T | SetRelative< T > (this T t, bool isRelative) |
If isRelative is TRUE sets the tween as relative (the endValue will be calculated as More... | |
static T | SetSpeedBased< T > (this T t) |
If isSpeedBased is TRUE sets the tween as speed based (the duration will represent the number of units the tween moves x second). More... | |
static T | SetSpeedBased< T > (this T t, bool isSpeedBased) |
If isSpeedBased is TRUE sets the tween as speed based (the duration will represent the number of units the tween moves x second). More... | |
static T | SetEase< T > (this T t, Ease ease) |
Sets the ease of the tween. More... | |
static T | SetEase< T > (this T t, Ease ease, float overshoot) |
Sets the ease of the tween. More... | |
static T | SetEase< T > (this T t, Ease ease, float amplitude, float period) |
Sets the ease of the tween. More... | |
static T | SetEase< T > (this T t, AnimationCurve animCurve) |
Sets the ease of the tween using an AnimationCurve. More... | |
static T | SetEase< T > (this T t, EaseFunction customEase) |
Sets the ease of the tween using a custom ease function. More... | |
static Tweener | SetOptions (this TweenerCore< float, float, FloatOptions > t, bool snapping) |
Options for float tweens More... | |
static Tweener | SetOptions (this TweenerCore< Vector2, Vector2, VectorOptions > t, bool snapping) |
Options for Vector2 tweens More... | |
static Tweener | SetOptions (this TweenerCore< Vector2, Vector2, VectorOptions > t, AxisConstraint axisConstraint, bool snapping=false) |
Options for Vector2 tweens More... | |
static Tweener | SetOptions (this TweenerCore< Vector3, Vector3, VectorOptions > t, bool snapping) |
Options for Vector3 tweens More... | |
static Tweener | SetOptions (this TweenerCore< Vector3, Vector3, VectorOptions > t, AxisConstraint axisConstraint, bool snapping=false) |
Options for Vector3 tweens More... | |
static Tweener | SetOptions (this TweenerCore< Vector4, Vector4, VectorOptions > t, bool snapping) |
Options for Vector4 tweens More... | |
static Tweener | SetOptions (this TweenerCore< Vector4, Vector4, VectorOptions > t, AxisConstraint axisConstraint, bool snapping=false) |
Options for Vector4 tweens More... | |
static Tweener | SetOptions (this TweenerCore< Quaternion, Vector3, QuaternionOptions > t, bool useShortest360Route=true) |
Options for Quaternion tweens More... | |
static Tweener | SetOptions (this TweenerCore< Color, Color, ColorOptions > t, bool alphaOnly) |
Options for Color tweens More... | |
static Tweener | SetOptions (this TweenerCore< Rect, Rect, RectOptions > t, bool snapping) |
Options for Vector4 tweens More... | |
static Tweener | SetOptions (this TweenerCore< string, string, StringOptions > t, bool scramble) |
Options for Vector4 tweens More... | |
static Tweener | SetOptions (this TweenerCore< Vector3, Vector3[], Vector3ArrayOptions > t, bool snapping) |
Options for Vector3Array tweens More... | |
static Tweener | SetOptions (this TweenerCore< Vector3, Vector3[], Vector3ArrayOptions > t, AxisConstraint axisConstraint, bool snapping=false) |
Options for Vector3Array tweens More... | |
Methods that extend Tween objects and allow to set their parameters
|
static |
Changes a TO tween into a FROM tween: sets the current target's position as the tween's endValue then immediately sends the target to the previously set endValue.
T | : | Tweener |
|
static |
Changes a TO tween into a FROM tween: sets the current target's position as the tween's endValue then immediately sends the target to the previously set endValue.
isRelative | If TRUE the FROM value will be calculated as relative to the current one |
T | : | Tweener |
|
static |
Sets the onComplete callback for the tween. Called the moment the tween reaches its final forward position, loops included
T | : | Tween |
|
static |
Sets the onKill callback for the tween. Called the moment the tween is killed
T | : | Tween |
|
static |
Sets the onPlay callback for the tween. Called when the tween is set in a playing state, after any eventual delay. Also called each time the tween resumes playing from a paused state
T | : | Tween |
|
static |
Sets the onRewind callback for the tween. Called when the tween is rewinded, either by calling
Rewind
or by reaching the start position while playing backwards. Rewinding a tween that is already rewinded will not fire this callback
T | : | Tween |
|
static |
Sets the onStart callback for the tween. Called the first time the tween is set in a playing state, after any eventual delay
T | : | Tween |
|
static |
Sets the onStepComplete callback for the tween. Called the moment the tween completes one loop cycle, even when going backwards
T | : | Tween |
|
static |
Sets the onUpdate callback for the tween. Called each time the tween updates
T | : | Tween |
|
static |
Sets the parameters of the tween (id, ease, loops, delay, timeScale, callbacks, etc) as the parameters of the given one. Doesn't copy specific SetOptions settings: those will need to be applied manually each time.
Has no effect if the tween has already started.
NOTE: the tween's target
will not be changed
asTween | Tween from which to copy the parameters |
T | : | Tween |
|
static |
Sets the parameters of the tween (id, ease, loops, delay, timeScale, callbacks, etc) as the parameters of the given TweenParms.
Has no effect if the tween has already started.
tweenParms | TweenParms from which to copy the parameters |
T | : | Tween |
|
static |
Sets the autoKill behaviour of the tween. Has no effect if the tween has already started
T | : | Tween |
|
static |
Sets the autoKill behaviour of the tween. Has no effect if the tween has already started
autoKillOnCompletion | If TRUE the tween will be automatically killed when complete |
T | : | Tween |
|
static |
Sets a delayed startup for the tween.
Has no effect on Sequences or if the tween has already started
T | : | Tween |
|
static |
Sets the ease of the tween.
Has no effect on Sequences
T | : | Tween |
|
static |
Sets the ease of the tween.
Has no effect on Sequences
overshoot | Eventual overshoot to use with Back ease (default is 1.70158) |
T | : | Tween |
|
static |
Sets the ease of the tween.
Has no effect on Sequences
amplitude | Eventual amplitude to use with Elastic easeType (default is 1.70158) |
period | Eventual period to use with Elastic easeType (default is 0) |
T | : | Tween |
|
static |
Sets the ease of the tween using an AnimationCurve.
Has no effect on Sequences
T | : | Tween |
|
static |
Sets the ease of the tween using a custom ease function.
Has no effect on Sequences
T | : | Tween |
|
static |
Sets an ID for the tween, which can then be used as a filter with DOTween's static methods.
id | The ID to assign to this tween. Can be an int, a string, an object or anything else. |
T | : | Tween |
|
static |
Sets the looping options for the tween. Has no effect if the tween has already started
loops | Number of cycles to play (-1 for infinite - will be converted to 1 in case the tween is nested in a Sequence) |
T | : | Tween |
|
static |
Sets the looping options for the tween. Has no effect if the tween has already started
loops | Number of cycles to play (-1 for infinite - will be converted to 1 in case the tween is nested in a Sequence) |
loopType | Loop behaviour type (default: LoopType.Restart) |
T | : | Tween |
|
static |
Options for float tweens
snapping | If TRUE the tween will smoothly snap all values to integers |
|
static |
Options for Vector2 tweens
snapping | If TRUE the tween will smoothly snap all values to integers |
|
static |
Options for Vector2 tweens
axisConstraint | Selecting an axis will tween the vector only on that axis, leaving the others untouched |
snapping | If TRUE the tween will smoothly snap all values to integers |
|
static |
Options for Vector3 tweens
snapping | If TRUE the tween will smoothly snap all values to integers |
|
static |
Options for Vector3 tweens
axisConstraint | Selecting an axis will tween the vector only on that axis, leaving the others untouched |
snapping | If TRUE the tween will smoothly snap all values to integers |
|
static |
Options for Vector4 tweens
snapping | If TRUE the tween will smoothly snap all values to integers |
|
static |
Options for Vector4 tweens
axisConstraint | Selecting an axis will tween the vector only on that axis, leaving the others untouched |
snapping | If TRUE the tween will smoothly snap all values to integers |
|
static |
Options for Quaternion tweens
useShortest360Route | If TRUE (default) the rotation will take the shortest route, and will not rotate more than 360°. If FALSE the rotation will be fully accounted. Is always FALSE if the tween is set as relative |
|
static |
Options for Color tweens
alphaOnly | If TRUE only the alpha value of the color will be tweened |
|
static |
Options for Vector4 tweens
snapping | If TRUE the tween will smoothly snap all values to integers |
|
static |
Options for Vector4 tweens
scramble | If TRUE the string will appear from a random animation of characters |
|
static |
Options for Vector3Array tweens
snapping | If TRUE the tween will smoothly snap all values to integers |
|
static |
Options for Vector3Array tweens
snapping | If TRUE the tween will smoothly snap all values to integers |
|
static |
Allows the tween to be recycled after being killed.
T | : | Tween |
|
static |
Sets the recycling behaviour for the tween.
recyclable | If TRUE the tween will be recycled after being killed, otherwise it will be destroyed. |
T | : | Tween |
|
static |
Sets the tween as relative (the endValue will be calculated as
startValue + endValue
instead than being used directly).
Has no effect on Sequences or if the tween has already started
T | : | Tween |
|
static |
If isRelative is TRUE sets the tween as relative (the endValue will be calculated as
startValue + endValue
instead than being used directly).
Has no effect on Sequences or if the tween has already started
T | : | Tween |
|
static |
If isSpeedBased is TRUE sets the tween as speed based (the duration will represent the number of units the tween moves x second).
Has no effect on Sequences, nested tweens, or if the tween has already started
T | : | Tween |
|
static |
If isSpeedBased is TRUE sets the tween as speed based (the duration will represent the number of units the tween moves x second).
Has no effect on Sequences, nested tweens, or if the tween has already started
T | : | Tween |
|
static |
Sets the target for the tween, which can then be used as a filter with DOTween's static methods.
IMPORTANT: use it with caution. If you just want to set an ID for the tween use SetId
instead.
When using shorcuts the shortcut target is already assigned as the tween's target, so using this method will overwrite it and prevent shortcut-operations like myTarget.DOPause from working correctly.
target | The target to assign to this tween. Can be an int, a string, an object or anything else. |
T | : | Tween |
|
static |
Sets the update type to UpdateType.Default and lets you choose if it should be independent from Unity's Time.timeScale
isIndependentUpdate | If TRUE the tween will ignore Unity's Time.timeScale |
T | : | Tween |
|
static |
Sets the type of update (default or independent) for the tween
updateType | The type of update (defalt: UpdateType.Default) |
isIndependentUpdate | If TRUE the tween will ignore Unity's Time.timeScale |
T | : | Tween |