AsepriteTag
Represents an animation tag from an Aseprite file.
Tags define named animation sequences within the sprite's frames. Each tag marks a range of frames that can be played as a loop or one-shot animation with a specific playback direction.
Tags are commonly used to organize different character animations like "idle", "walk", "jump", "attack" within a single Aseprite file.
Static Members
Creates an AsepriteTag from raw tag chunk data.
Converts the file format representation into a more convenient structure for use in the engine.
Name | Type | Description |
---|---|---|
chunk |
ase.chunks.Tag | The tag data from the Aseprite file |
Returns | Description |
---|---|
AsepriteTag | A new AsepriteTag instance |
Instance Members
The name of this animation tag. Used to identify and play specific animations (e.g., "walk", "idle").
The first frame index of this animation (0-based, inclusive).
The last frame index of this animation (0-based, inclusive).
The playback direction for this animation:
- 0: Forward (play from fromFrame to toFrame)
- 1: Reverse (play from toFrame to fromFrame)
- 2: Ping-pong (play forward then reverse)
Name | Type | Description |
---|---|---|
name |
String | * The name of this animation tag. Used to identify and play specific animations (e.g., "walk", "idle"). |
fromFrame |
Int | * The first frame index of this animation (0-based, inclusive). |
toFrame |
Int | * The last frame index of this animation (0-based, inclusive). |
direction |
Int | * The playback direction for this animation: - 0: Forward (play from fromFrame to toFrame) - 1: Reverse (play from toFrame to fromFrame) - 2: Ping-pong (play forward then reverse) |
Metadata
Name | Parameters |
---|---|
:structInit |
- |