FREE TRIAL

|

☀
☾
interface

IAnimationWithEvents

A common interface to implement for all animation structs which wish to receive a range of animation events beyond the baseline Update(float percentDone) event.

Methods

Begin

Called before the first call to Update(Single) for each iteration.

Complete

Called after End() of the final iteration, which may be triggered automatically or explicitly via Complete(AnimationHandle).

End

Called after the last call to Update(Single) for each iteration.

OnCanceled

Called when the AnimationHandle tied to this animation is canceled via Cancel(AnimationHandle).

OnPaused

Called when the AnimationHandle tied to this animation is paused via Pause(AnimationHandle).

OnResumed

Called when the AnimationHandle tied to this animation is resumed via Resume(AnimationHandle).

Update

Called once per frame while the animation is running and provides a percentDone, [0, 1] where 1 == 100%, for the current animation iteration.

Extension Methods

Loop

Queue an animation to loop iterations times for durationInSeconds per iteration, where iterations == -1 indicates "until canceled", starting at the end of the current frame.

Run

Queue an animation to run for durationInSeconds starting at the end of the current frame.

See Also

IAnimation
IAnimationWithEventsExtensions
☀
☾
In This Article
Legal EmailContact Github
Copyright © 2022 Supernova Technologies, LLC