flixel
flixel copied to clipboard
Aseprite Atlas repeat value to follow editor convention
- Flixel version: 5.4.1
Aseprite editor behavior is as follows:
| Tag's Repeat Checkbox | Tag's Repeat Field Value | Tag Looping behavior |
|---|---|---|
|
N/A | Loops Forever |
|
1 |
Plays a single time, stopping at the final frame |
|
>1 |
Plays N times |
Currently, AseAtlas parses the loops value as:
inline function get_loops()
{
return this != null && toInt() > 0;
}
However, in the Aseprite editor, tags default to looping, represented by the Repeat field on the tag being unchecked.
Current Flixel parsed behavior:
| Tag's Repeat Checkbox | Tag's Repeat Field Value | Flixel Animation parsed loops value |
|---|---|---|
|
N/A | false |
|
1 |
true |
|
>1 |
true |
Desired Flixel parsed behavior:
| Tag's Repeat Checkbox | Tag's Repeat Field Value | Flixel Animation parsed loops value |
|---|---|---|
|
N/A | true |
|
1 |
false |
|
>1 |
true |
With this behavior, the only gap between Aseprite and Flixel is in the case where Repeat is >1, as Flixel does not have a built-in notion of playing an animation x times.