Skip to content

nikouu/Extract-Pokemon-Crystal-palette

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Extract Pokémon Crystal Palette

Looks through pret/pokecrystal to find every colour used in Pokémon Crystal.

This is a rough afternoon of work and aims to:

  1. Catch all RGB colours used in palettes inside .pal and .asm files
  2. Only analyse coloured .png files as a lot of .png files are greyscale and have palettes applied to them.

Note:

  1. While a colour might be referenced once, it could be used many more times as a palette that gets applied to many tiles
    1. For example, I think the mart is using the eight special colours from house.pal which I think gets used in other places too.
  2. These are converted from the 5 bit RGB GBC values to 8 bit RGB values.

How to use

Try it now now on GitHub Pages!

Each colour square is a colour found in Pokémon Crystal with the top left showing how many places refer to it.

Default view: Screenshot1

You can click on a colour to show where the references

Screenshot2

Data gathering

The data is gathered via the .NET code in the src folder. A quick and dirty piece of code that analyses the pokecrystal folders looking for colour references and ultimately turns the results into JSON. The following outputs are:

  1. AllColours.json is the JSON output of each colour and associated location
  2. CrystalPalette a visual, simple view of all 1599 colours

Here's the palette!

All 1599 colours, roughly ordered.

palette

Notes

  1. Uses d3.js for visualisations.
  2. There might be something I'm missing, but I'd say most colours are accounted for - but pretty fun for an afternoon!