Closed andymitchellx closed 9 months ago
Thank you for your attention to the project and this proposal.
I've added support for multiple animation in the same texture sheet. But I think skipping zero duration frames isn't something this simple system should care of. I can't REMOVE AT
frame during baking if it has zero duration, because frames is just continuously changing UV just by increasing frame index by 1 each duration expired. If I will remove frame from baking I will just lose last one frame in sequence.
Sorry for this long. If you have some working changes and you think it can be added to the project then feel free to make PR.
Thanks for NSprite.
I have a sprite sheet with multiple animations. I was wondering if you'd consider skipping "0 second length" frames in SpriteUVAnumationSystem. So, "walk" could be frames 0-3 and "idle" could be frames 4-7.
Here's one proposal to check the nextFrameDuration. I would add an escape clause to the loop in case someone accidentally create an AnimationSet where all frames are set to 0.
A better way might be to change SpriteAnimatedRendererAuthoring to not load them into the animationSet. That would avoid checking each frame.