đź•ą Indexed Colour Workflow

I've started to chase down a workflow for asset creation [for the EH500] and it's turned out to be more of a faff than I expected. Probably because I've been messing about with the Amiga lately and, er, completely forgot how the future works.

My ideal would be to use Aseprite to create the individual sprites/tiles and animations. Then use Texture Packer to generate the packed texture pages; one for each tilemap buffer, and one for the sprites.

It should, in theory, also be possible to script this, so I could run a shell-script to build a "Cartridge" – a zip file, containing all the files the game needs, in a specific layout – that I can distribute separately from the EH500. (Separate distribution's not a requirement, but it'd be nice to have. The Pico8 carts are great.)

It doesn't look like this'll work quite as I imagined.

Despite being able to output PNG8 files, Texture Packer works with 32bit-per-pixel colour internally. As you do. This means the output t-page has a re-arranged palette, that may or may not have the same number of colours in it. Joy.

I tried the open-source version, and it has similar problems.

This isn't the end of the world. I can remap the output t-page and revert it back to a fixed palette, but it's a handraulic step. Or, I can write my own sprite packer. (Tempting... Maybe... But not right now.)

I was also assuming that I could keep strict, 16 colour images in memory, but SDL_image promotes everything to 32bpp, and SDL_Surface assumes 8bpp [so 256 colours]. I could load the Aseprite format directly, but it's pointless additional copying of data for something I can enforce in other ways.

Anyway, that was slightly disappointing, but basically understandable. It's not the 90s anymore. Although I'd argue there's still a need for a texture packer that respects indexed palettes end-to-end. Either way, I do now have a process that I can live with.

And more importantly, progress on the EH500 has been great! I have the framework loading tilemaps and sprites from a debug “cart”, setting palettes correctly, and exposed in a way that I can later turn into “registers” for game code.

A fun diversion for a few days. :)

sprites.jpg