SpriteForge Editor

v0.1.1
tech.spriteforge/editor Checked 3 days ago Published 12 days ago

Free pixel and tileset editor, no account: hand-edit sprites, animations and Wang tilesets in chat

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

open_editor Open a sprite in the SpriteForge editor

Opens pixel art in SpriteForge's compact pixel editor - pencil, eraser, fill, colour picker, palette, undo and animation frames - as an interactive card where the app shows them, and returns an edit link (the same editor in a browser) and a session_id. No account needed. One source at most: png_base64 (an existing PNG), art (palette + index grid), or neither for a blank width x height canvas. Max 128x128 pixels and 256 colours. The user's edits save to the edit session automatically.

ParameterTypeDescription
artobjectPixel art in SpriteForge's format: palette = hex colours, grid = rows of palette indexes (-1 = transparent). Optional frames for an animation, each { grid } on the same palette.
heightintegerBlank canvas height in pixels (default 32).
namestringSprite name, used as the download filename (letters, digits, _ and -).
palettearrayStarting palette for a blank canvas, as hex colours.
png_base64stringA PNG file, base64-encoded (a data: URL prefix is fine). Pixels under 50% alpha become transparent.
widthintegerBlank canvas width in pixels (default 32).

get_sprite Get a sprite from a SpriteForge edit session

Returns the current state of a SpriteForge edit session: a preview image, its size and palette, how many edits were saved, and a PNG URL with the exact pixels at 1x (add &frame=N for another frame). With include_pixels it also returns the palette-index grid. Read-only.

ParameterTypeDescription
session_id *stringAn edit session's id (the s= value of an edit link), or the edit link itself.
include_pixelsbooleanAlso return the palette and index grid (default false).

open_full_editor Open the full SpriteForge editor

Opens a sprite in SpriteForge's full pixel editor - layers, selection and move, line/rectangle/ellipse, mirror painting, brush sizes, animation frames with onion skin and playback, palette tools - as an interactive card where the app shows them, and returns an edit link that opens the same editor in a browser. One source at most: session_id (an edit session that's already open, or an edit link), png_base64 (an existing PNG), art (palette + index grid), or none for a blank width x height canvas. Max 128x128 pixels and 256 colours. The user's edits save to the edit session.

ParameterTypeDescription
artobjectPixel art in SpriteForge's format: palette = hex colours, grid = rows of palette indexes (-1 = transparent). Optional frames for an animation, each { grid } on the same palette.
heightintegerBlank canvas height in pixels (default 32).
namestringSprite name, used as the download filename (letters, digits, _ and -).
palettearrayStarting palette for a blank canvas, as hex colours.
png_base64stringA PNG file, base64-encoded (a data: URL prefix is fine). Pixels under 50% alpha become transparent.
session_idstringAn edit session that's already open, or an edit link containing ?s=<id>.
widthintegerBlank canvas width in pixels (default 32).

open_tileset_editor Open the SpriteForge tileset editor

Opens a tileset in SpriteForge's tileset editor as an interactive card where the app shows them, and returns an edit link that opens the same editor in a browser. For a Wang autotile set (16 tiles; tile i is drawn where the map cells at its corners are painted, NW=1 NE=2 SW=4 SE=8, so tile 15 is the solid base; sets SpriteForge derives add 4 variants of tile 15 as tiles 16-19, mixed into painted floors) the user paints a small map to see the tiles chain, draws on the map or on single tiles, and edits the base texture, which re-derives the edge tiles (tiles drawn by hand stay); a platformer set…

ParameterTypeDescription
basearrayA square seamless texture to derive a Wang set from (its 16 tiles and 4 variants of tile 15).
kindstringwang (flat floor terrain), wall (Wang walls), iso (isometric Wang) or platformer. For a new set, default wang. With session_id, wang, wall or iso switches that Wang set's preview, keeping its tiles; a…
layoutstringHow to read png_base64: sheet (4x4 or 4x5 Wang sheet, or a platformer set's 7x7), strip (16x1 or 20x1) or texture (a square base texture the Wang tiles are derived from). Default: guessed from the ima…
namestringThe set's name.
palettearrayHex colours for tiles or base.
png_base64stringA tileset PNG (a Wang set's 4x4 or 4x5 sheet or 16x1 or 20x1 strip, a platformer set's 7x7 sheet) or a square texture, base64.
session_idstringAn existing tileset edit session, or an edit link containing ?s=<id>. Give kind with it to change a Wang set's preview; the other fields are for a new set.
sizeintegerTile size for a blank set (default 32).
tilesarrayThe set's tiles in mask order (16 for Wang kinds, or 20 with tile 15's 4 variants after them; 49 for platformer), palette indexes, -1 transparent.

load_art Load an edit session into the editor card

Loads an edit session's sprite into the SpriteForge editor card. Only the card calls it.

ParameterTypeDescription
session_id *string

save_art Save the editor card's sprite

Saves the user's edits from the SpriteForge editor card to its edit session. Only the card calls it.

ParameterTypeDescription
art *objectPixel art in SpriteForge's format: palette = hex colours, grid = rows of palette indexes (-1 = transparent). Optional frames for an animation, each { grid } on the same palette.
session_id *string