SpriteAnimator.PlayFromFrameWithCrossFade(string, int, float, bool) Method
Definition
Namespace: Brine2D.Animation
Plays an animation by name beginning at a specific frame index, with a cross-fade over fadeDuration seconds from the currently playing clip.
C#
public void PlayFromFrameWithCrossFade(string animationName, int startFrame, float fadeDuration, bool restart=false);
Parameters
animationName System.String
startFrame System.Int32
fadeDuration System.Single
restart System.Boolean
Exceptions
System.ArgumentOutOfRangeException
Thrown if fadeDuration is not positive.