This is a script that extracts the darkest, lightest, and middlest colors from pngs and writes them up as a SleeveColor for use copy-pasting into FS sleeves.
json argparse PIL pathlib numpy
You may need to pip install json
etc for some of these
- Download script
- Make a folder named
input
in the same folder as the script, and put all of the FS folders into this folder. The input has to be a series of folders, each withshirt.json
andshirt.png
in there, withshirt.json
having front, back, left, and right models in the FS format and theshirt.png
must have a normal game format front-facing shirt in the top left corner if you want to use theuseGamePixels
option. Basically, it will work with shirts converted from JA and will sort of work with shirts that were not generated that way. - Navigate to location of script
- Run
python sleeve_colorizer.py
in command line. Optionally,--showColorway True
to make it dump acolorway.png
with the colors next to each image. Also optionally,--useGamePixels True
to make it use instead exactly the three pixels I think the game uses for the colors. - The
shirt.json
will be edited for each folder in theinput
folder