Table of Contents

Method SetFrame

Namespace
MonoGame.Aseprite
Assembly
MonoGame.Aseprite.dll

SetFrame(int)

Sets the current frame of animation for this AnimatedSprite.

public void SetFrame(int frameIndex)

Parameters

frameIndex int

The index of the frame to set. Value must be greater than zero and less than the total count of frames. You can use FrameCount to determine the total number of frames.

Exceptions

ArgumentOutOfRangeException

Thrown if the frameIndex value provided is less than zero or is greater than or equal to the total number of frames in this AnimatedSprite.