4 comments
@capital it's the famicom format, one of the advantage for 2-bit is that you can draw the layers independently when needed. @capital For example in Oquonie, I have the outline and fill for player assets as chr tiles, if I want to make the fill color of the character blink, I can draw only the second half of the chr tile for just repainting the fill, or both at once. |
The code to process .chr files is very messy. Mostly because I was fumbling trying to compute how many pixels I needed to jump for plotting a color and how many bites I needed to jump for reading data.
Kinda makes me wish uxn packed pixels using a simple "4-pixels per byte" scheme instead of a "two-channels per tile" format. Both pack the same information in the same space (2-bits per pixel), but 4-pixels per byte is easier to process, imo.