The VG Resource

Full Version: Automatic Icon Generator for Sprite Sheets
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
First time posting here in the forums, so sorry in advance if this is the wrong place to put this! But I just wrote a simple Python script that will go through a folder of spritesheets and create 148px x 125px icons based off of the top-left sprite in each one. It's definitely not foolproof and hasn't been super rigorously tested with differently-sized sprites, but it worked pretty well for some small pixel character sprites I was ripping. So just thought I'd share in case it's helpful to anyone else!

[attachment=15645]
(.txt file, needs to be changed to .py extension)

Some other notes: It works based off of transparency and relies on there being at least one full row/column of 100% transparency on each side of the sprite. It also probably won't work well with any sprite sheet that has borders or other objects that might block it from scanning for the first sprite (like headings or titles).