Table of Contents

Class TweenOptions

Provides options for tween.

public class TweenOptions : AbstractAnimationOptions
Inheritance
TweenOptions
Inherited Members
Extension Methods

Constructors

TweenOptions()

Initialises a new instance of the TweenOptions class.

public TweenOptions()

Fields

DefaultEasing

public const Easing DefaultEasing = Linear

Field Value

Easing

DefaultEasingReverse

public const bool DefaultEasingReverse = false

Field Value

bool

DefaultIEasing

public static readonly IEasing DefaultIEasing

Field Value

IEasing

DefaultTime

public const float DefaultTime = 1

Field Value

float

Properties

Easing

The easing of the tween.

public IEasing Easing { get; set; }

Property Value

IEasing

LoopType

The loop type of the tween.

public LoopType LoopType { get; set; }

Property Value

LoopType

Time

The amount of time in seconds that this tween will last.

public float Time { get; set; }

Property Value

float

Methods

SetAutoStart(bool)

Sets whether this animation should auto-start or not.

public TweenOptions SetAutoStart(bool autoStart)

Parameters

autoStart bool

Returns

TweenOptions

Remarks

Auto-start will be slower than a true-start. See more at https://flowent.friedsynapse.com/tips#h.s5cucrg5qyjc

SetDelay(float)

Sets the amount of time in seconds that you want to delay when this animation is started.

public TweenOptions SetDelay(float time)

Parameters

time float

Returns

TweenOptions

SetDelayUntil(Func<bool>)

Sets the callback that holds the starting of the animation.

public TweenOptions SetDelayUntil(Func<bool> callback)

Parameters

callback Func<bool>

Returns

TweenOptions

SetEasing(AnimationCurve, bool)

Sets the easing of the tween using an animation curve.

public TweenOptions SetEasing(AnimationCurve animationCurve, bool reverse = false)

Parameters

animationCurve AnimationCurve
reverse bool

Will apply a reverse on the easing.

Returns

TweenOptions

SetEasing(Easing, bool)

Sets the easing of the tween using predefined values.

public TweenOptions SetEasing(Easing easing, bool reverse = false)

Parameters

easing Easing
reverse bool

Will apply a reverse on the easing.

Returns

TweenOptions

SetEasing(IEasing, bool)

Sets the easing of the tween.

public TweenOptions SetEasing(IEasing easing, bool reverse = false)

Parameters

easing IEasing
reverse bool

Will apply a reverse on the easing.

Returns

TweenOptions

SetEasing(Func<float, float>, bool)

Sets the easing of the tween using a FunctionEasing.

public TweenOptions SetEasing(Func<float, float> easing, bool reverse = false)

Parameters

easing Func<float, float>
reverse bool

Will apply a reverse on the easing.

Returns

TweenOptions

SetLoopCount(int?)

Sets the amount of loops you want this animation to have. If you want infinite loops pass a null value.

public TweenOptions SetLoopCount(int? loopCount)

Parameters

loopCount int?

Returns

TweenOptions

Remarks

Flows only have reset loop types.

SetLoopType(LoopType)

Sets the loop type of the tween.

public TweenOptions SetLoopType(LoopType loopType)

Parameters

loopType LoopType

Returns

TweenOptions

SetName(string)

Sets the name of the animation.

public TweenOptions SetName(string name)

Parameters

name string

Returns

TweenOptions

SetSkipFrames(int)

Sets the amount of frames you want to skip at when this animation is started.

public TweenOptions SetSkipFrames(int frames)

Parameters

frames int

Returns

TweenOptions

SetTime(float)

Sets the amount of time in seconds that this tween will last.

public TweenOptions SetTime(float time)

Parameters

time float

Returns

TweenOptions

SetTimeScale(float)

Sets the time scale for the current animation.

public TweenOptions SetTimeScale(float timeScale)

Parameters

timeScale float

Returns

TweenOptions

SetUpdateType(UpdateType)

Sets the update type for the animation.

public TweenOptions SetUpdateType(UpdateType updateType)

Parameters

updateType UpdateType

Returns

TweenOptions