Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Non-contiguous Animation Clip/Playback #191

Open
odecay opened this issue Aug 1, 2022 · 2 comments
Open

Non-contiguous Animation Clip/Playback #191

odecay opened this issue Aug 1, 2022 · 2 comments

Comments

@odecay
Copy link
Collaborator

odecay commented Aug 1, 2022

Does it make sense to implement clips/animations which play a non-contiguous array of frame indexes? I had a usecase for it before when I was adding a waiting state and it didn't really match any of the available animation frames, but I'm not sure if that would be a good design. It would let us piece together frames from a spritesheet to make "ad-hoc" animations of the correct length, or skip frames in the middle of an animation if we needed to.

Unsure overall if this is a good idea or if there are better ways to attain more flexibility in animation playback/definitions via code/resources.

Originally posted by @odecay in #190 (comment)

@zicklag
Copy link
Member

zicklag commented Aug 1, 2022

It could make sense. It would essentially be an array of ranges, which might not be bad.

Some of the exact details of the syntax become less important with an editor, too, so if it was a useful feature and we could make a good interface for it, it seems like it might be good to include.

Another possibility is to just use an array of frames, which would be ultimate flexibility with a lot more typing for otherwise simple cases.

@odecay
Copy link
Collaborator Author

odecay commented Aug 1, 2022

Array of frames could work as well 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants