talecrafter / AnimationImporter

Aseprite Animation Importer for Unity
613 stars 72 forks source link

error import animations #44

Closed treborsz7 closed 3 years ago

treborsz7 commented 4 years ago

in Pyxel Edit Importer line 130 you are using [i] != 100 where need use [frameIndex] != 100, this generate an index out range exception where the animations > animation frames

for (int frameIndex = 0; frameIndex < animationData.length; frameIndex++) { ImportedAnimationFrame frame = new ImportedAnimationFrame();

frame.duration = animationData.frameDuration;
if (animationData.frameDurationMultipliers[i] != 100)
{
    frame.duration *= (int)(animationData.frameDurationMultipliers[i] / 100f);
}
treborsz7 commented 4 years ago

correction, all PyxelEdit import is bad in pixel Edit the animation frame have the next form |f1|f2|f3|f4| |f5|f6|f7|f8| |f9|....... but the code is creating the frames in the next form |f9|f10|f11|f12| |f5|f6 |f7 | f8 | |f1|f2 |f3 |f4 | .... uploading the fix

talecrafter commented 3 years ago

Was fixed in abc133c0b07076d030bb59db2116c700e34c00e4.