Palette Animations - pk-hack/CoilSnake GitHub Wiki

EarthBound maps use 6 different sub-palettes (16 colors each) at once that all make up one main palette (96 colors). Palette animations are how the game animates colors on maps. The water in the Sea of Eden, the flickering maze in the Stonehenge base, Moonside, etc.

alt

Like tile animations, all of the palette animations are compressed somewhere in EarthBound's ROM and you will need exhal/inhal to extract vanilla animations and recompress your custom ones. Each palette animation is made up of multiple frames. Every 96 colors equates to one single frame. If your animation has 4 frames, that would make 384 colors in the entire animation sequence.

alt

This example will make it so Twoson will have an animated palette that makes its grass swap between different colors.

  1. Figure out how many frames you want your map's palette to animate through. Let's say we make it four frames like the example above.
  2. Create a png (preferably 24-bit full color) the size of 16x24 (6 x 4 = 24).
  3. Find a method to add in all the colors within the image for each pixel all in the same order as the reference map palette in the editor.
  4. Duplicate the 96 colors three times until the image is full.
  5. Edit the colors in the three sets you just pasted to how you'd like. The first set should always stay unmodified (Unless you change the colors in the map editor), otherwise the original palette will never return to what it was once the animation starts playing.
  6. When you're done with the png, you will need a tool that converts pngs into snes palette data. If you are using Super Palette Imager, you will need to divide the png into parts (separate pngs) as the program limits you to having 255 colors per image. import your pngs one at a time into Super Palette Imager, export them into separate bins in the same order, then use HxD to combine them together in one main bin file.
  7. Use inhal to compress the bin
  8. Put the bin in your project's ccscript folder, preferably a sub folder named animated_palettes.
  9. Add the animated_palette_configuration_table.ccs to your project's ccscript folder and configure it to how you'd like.
  10. Edit the map this new palette animation is meant for to use palette animation 9.