-
Notifications
You must be signed in to change notification settings - Fork 24
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
Convert internal sprite data format to binary #143
Labels
Milestone
Comments
Could use your advice here, @nurpax :) |
Option 2 seems better, if the rest of your code can handle 24x21 vs 12x21 array sizes. The choice kind of depends on how your code is structured, but it does kind of feel like say looping over pixels would iterate over whole integer elements (one int == one pixel). |
Agreed that should you add say 8 bit colors with a color palette, then option 2 would support that better. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The current sprite data uses 0,1,2,3 to represent the sprite colors transparent, single color, mc1 and mc2. This is a typical sprite in multicolor:
This causes all kinds of hacks, e.g. that multicolor changes only every second value and ignores the rest (so that only 12 values instead of 24 are read).
Instead, the file format should properly represent the bit values, like
0 = 00
1 = 01
2 = 10
3 = 11
I see two options to go for:
The sprite array would remain at 24x21 size, but two numbers would make up for either one multicolor or two singlecolor values.
The sprite array would become half the size at 12x21.
Another advantage could be that if there's every going to be a version of Spritemate that supports other systems and color ranges, this format would work better.
Which one is the better approach?
The text was updated successfully, but these errors were encountered: