| name | game-assets |
| description | Make 2D game art with local ComfyUI txt2img plus a Pillow post-process script: backgrounds, seamless tiles, 9-slice UI, key art, single sprites, then slice/pack/quantize/alpha-key/downscale and set Godot import flags. Use when the owner asks for sprites, tilesets, pixel art, backgrounds or UI art for a game.
|
| version | 1.0.0 |
| author | Remedy |
| tags | ["game","assets","sprites","pixel-art","tileset","comfyui","pillow"] |
| requires | ["pillow"] |
| tools | ["comfyui","skill_run","bash_exec","file_read","file_write","list_dir","vision_decode","skill_activate"] |
| triggers | ["\\b(sprite ?sheets?|tile ?sets?|tile ?map art|game assets?|pixel ?art|background art|ui sprites?|9-?slice|seamless tiles?)\\b"] |
Game assets (ComfyUI + Pillow post-process)
Local txt2img via the comfyui tool (activate the comfyui skill if the
server is not up), then scripts/sheet_tools.py to turn raw generations
into engine-ready PNGs, then import settings in Godot.
Honest scope — say this to the owner before generating
txt2img is good for: backgrounds and parallax layers, seamless tiles
(with "tileable" prompting + a post-check), UI panels/buttons that will be
9-sliced, key art / title screens, icons, and single static sprites.
txt2img is poor for multi-frame animation sheets with a consistent
character: frames drift in proportions, palette and style, and the
result looks worse than rectangles. Do not promise a run cycle. Offer
instead, in this order:
- One generated idle frame + hand edits for 2–4 extra frames (you edit
pixels with Pillow; the owner or an artist refines).
- Placeholder rectangles/capsules with a colour per state until an
artist; the gameplay does not wait.
- Programmatic animation:
Tween squash/stretch, rotation, flip,
shader flash, AnimatedSprite2D of a single frame with offsets — it
reads as motion at game speed.
If the owner still wants generated frames, generate one frame, then use
it as a reference for manual edits; never stitch unrelated generations.
Workflow
- Spec first: target resolution (e.g. 640×360 at 3×), sprite size
(16/32/48 px), palette size (16/32 colours), transparency method, and
the file name per
game-dev-studio asset conventions. Write it down.
- Generate with
comfyui action=generate: prompts from
references/prompts-*.md; sizes 512–1024 square (ask VRAM first); set
seed to vary, keep the seed that works. Generate 2–4 candidates, show
the markdown images, let the owner pick. For pixel art generate large,
then downscale; do not ask the model for "16×16".
- Post-process with
skill_run on scripts/sheet_tools.py (Pillow
only, no network, refuses paths outside the current tree unless
--allow-outside):
python scripts/sheet_tools.py alpha-key in.png out.png --color auto --tolerance 40
python scripts/sheet_tools.py downscale in.png out.png --factor 8 # nearest
python scripts/sheet_tools.py quantize in.png out.png --colors 32
python scripts/sheet_tools.py slice sheet.png frames/ --cols 8 --rows 1 --prefix hero_run
python scripts/sheet_tools.py pack frames/ sheet.png --cols 8 --pad 1