Skip to content

APICO-Modders/APICO-imagemagick

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This is a Python script that leverages the power of Imagemagick to make certain aspects of modding APICO easier.

Changelog

🐝 All images used in this tool belong to TNGineers and are used and distributed with their permission.

Permission by ellraiser

Features

  • Generates text images using the font used in the menu object titles
  • Generates spritesheets with mouseover and undiscovered versions of items out of a single item sprite
    • Can optionally add the dark outline to the source sprite

Installation

  1. Install Python 3
    • Debian/Ubuntu Liunx: sudo apt install python3 python3-dev python-venv
    • macOS: brew install python (Homebrew) or xcode-select --install
    • Windows: choco install python (Chocolatey) or Download the installer
  2. Install ImageMagick
  3. Use venv to isolate your environment
    python -m venv env
    
    # Linux and macOS
    source env/bin/activate
    
    # Windows
    .\env\bin\activate
  4. Install the dependencies
    pip install -r requirements.txt

Usage

  1. Activate your isolated environment
    # Linux and macOS
    source env/bin/activate
    
     # Windows
    .\env\bin\activate
  2. Run the script
    ./run.py -h

Generate a text image

./run.py text -string "I love apico" -color "#d89d41" -output "text.png"

Text example

Generate a spritesheet

From a sprite that already has a dark outline

./run.py spritesheet -sprite jalapeno.png -output jalapeno_sheet.png

Spritesheet example

From a sprite that doesn't have a dark outline

./run.py spritesheet -sprite book.png -output book_sheet.png -darkoutline 1

Spritesheet example with adding a dark border