REXPaint Plugins and Tools: Extend Your ASCII WorkflowREXPaint is a powerful, lightweight editor designed for creating grid-based pixel art and ASCII/ANSI-style graphics, commonly used in roguelike games, terminal-style interfaces, and retro-inspired projects. While the core application is already feature-rich—offering layers, palettes, tile brushes, and export options—its ecosystem of plugins, scripts, and companion tools can significantly extend its capabilities and streamline ASCII workflows. This article walks through useful plugins and tools (official and community-made), integration patterns, workflows for game development, and tips to customize REXPaint to fit your pipeline.
Why extend REXPaint?
REXPaint focuses on being a fast, focused editor for tile and text-based art. Extending it makes sense when you want to:
- Automate repetitive tasks (batch exports, tile atlasing).
- Integrate artwork into game engines or asset pipelines.
- Add specialized export formats (spritesheets, JSON, XML).
- Convert between character sets, codepages, or color formats.
- Share and reuse palettes, brushes, and templates.
Extensions let you keep REXPaint as the visual creation hub while handling conversion, metadata, and integration elsewhere.
Popular REXPaint plugins, scripts, and companion tools
Below are notable tools and plugins that REXPaint users commonly use. Some are official utilities; most are community-created. Check each tool’s repository or documentation for installation details and compatibility.
1) rexpaint-js / rexpaint.py — parsers and converters
- What they do: Read and write .xp (REXPaint) files, convert to image formats or JSON metadata.
- Use cases: Automated export pipelines, web previews, server-side rendering of tiles.
- Notes: Implementations exist in multiple languages (JavaScript, Python, C#). Choose based on your toolchain.
2) rexutils / xp-tools — command-line utilities
- What they do: Batch export .xp files to PNG/spritesheets, strip layers, or convert palettes.
- Use cases: CI/CD asset builds for games, automated atlas generation.
- Notes: Useful for headless environments where REXPaint GUI isn’t available.
3) REXPaint shaders / palette tools
- What they do: Apply palette transformations, simulate terminal color limitations (e.g., 16-color, 256-color), or convert truecolor art into CLI-friendly palettes.
- Use cases: Ensure art looks correct in target environments (terminals, consoles) or produce alternative palette variants.
- Notes: Can be implemented as scripts or image-processing tools; some game engines include palette-mapping utilities.
4) Spritesheet packers and tilemap exporters
- What they do: Take exported PNGs from REXPaint and pack them into spritesheets with accompanying JSON/TMX metadata for engines like Unity, Godot, Tiled.
- Use cases: Importing REXPaint art into game engines with correct cell sizes and animations.
- Notes: Tools such as TexturePacker, Aseprite exporters, or custom scripts are commonly used.
5) In-editor macros and templates
- What they do: Reusable brushes, template files, or layer presets to speed repetitive design (e.g., UI frames, item icons).
- Use cases: Standardizing iconography across a project, rapid prototyping.
- Notes: Store templates as .xp files in a shared directory.
Integrating REXPaint with game engines
A typical pipeline to bring REXPaint art into a game:
- Create tiles and animations in REXPaint, using layers for frames and metadata.
- Export each layer/frame to PNG (or use a script to export all frames).
- Use a spritesheet packer or custom script to assemble frames into an atlas and generate metadata (frame indices, pivot points).
- Import the atlas and metadata into your engine (Unity, Godot, Phaser) and set up tilemaps, animated sprites, or UI elements.
Practical tips:
- Keep consistent tile sizes and grid alignment; REXPaint’s grid makes this easy.
- Name layers/frames with a convention that your exporter can parse (e.g., “player_walk_0”, “player_walk_1”).
- Embed collision/interaction metadata in separate layers or in sidecar JSON files generated by an export script.
Workflow examples
Example A — Indie Roguelike (Godot)
- Create tiles in REXPaint at 16×16.
- Export frames via rexpaint.py to a folder structure: sprites/player/, sprites/enemies/.
- Run a script to generate a single spritesheet + a Godot-friendly JSON with atlas regions.
- Use Godot’s AtlasTexture + AnimatedSprite to play animations.
Example B — Web-based ASCII game
- Use rexpaint-js to convert .xp to JSON containing characters, foreground/background colors.
- Render directly on an HTML5 canvas or DOM, mapping characters to fonts or spritesheets.
- Use palette tools to downsample colors to ⁄256-color terminal palettes.
Creating your own plugins and scripts
REXPaint doesn’t have a built-in plugin API, but its .xp file format is well-documented and many community libraries make it straightforward to write custom tools.
Steps:
- Choose a language that fits your pipeline (Python and JavaScript are common).
- Use an existing .xp parser library or implement a minimal reader to extract layer data, tiles, and palette.
- Implement your feature: batch export, metadata embedding, animation assembler, or palette converter.
- Package as a CLI tool for easy integration in build scripts.
Example minimal Python flow (conceptual):
- load .xp → iterate layers → export tiles → write spritesheet + JSON
Tips for maintaining a plugin-friendly asset pipeline
- Version-control source .xp files (they’re binary but small); keep generated assets out of source control.
- Keep a naming convention and directory layout for easy automated discovery.
- Include a manifest or README per asset pack that describes tile size, palette, and intended use.
- Build small, focused tools rather than monolithic scripts; compose them in a CI pipeline.
Community and resources
- Check community repositories on GitHub/GitLab for language-specific .xp parsers and export scripts.
- Share palettes, brushes, and templates in a team drive or project repo to standardize visuals.
- Look for forum threads and tutorials in roguelike development communities for practical examples.
Common pitfalls and how to avoid them
- Palette mismatch: test exported art in the target environment’s color limitations early.
- Misaligned tiles: ensure export scripts preserve exact grid coordinates and tile sizes.
- Layer confusion: use clear layer naming conventions and separate visual layers from metadata layers.
Final notes
Extending REXPaint with plugins and external tools turns a great pixel/ASCII editor into a full asset-production engine tailored to your project. Focus on automating repetitive tasks, enforcing consistent naming and sizing, and producing engine-friendly metadata. With a few scripts and a clear pipeline, REXPaint can be the central hub of a fast, flexible ASCII art workflow.