Pyxel MCP

v1.6.0
io.github.kitao/pyxel-mcp Checked 5 days ago Published 3 hours ago

MCP server for Pyxel, a retro game engine for Python

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

run

Run a Pyxel script headlessly for a frame budget or until a condition holds, with scheduled input and state, screen, or video capture. screen_image snapshots with inline=true also return the PNG as image content, and a single inline frame may omit its output path.

ParameterTypeDescription
frames *integer
script *string
inputs
random_seed
snapshots
stall_window_frames
timeoutinteger
until

validate

Check Python syntax and report recognizable Pyxel code patterns.

ParameterTypeDescription
script *string

pyxel_info

Report installed versions, Pyxel and Cube type stub paths, examples, and resource URIs.

lookup_api

Look up an installed Pyxel or Cube API by name, e.g. blt, Image.set, or cube.Vec3.lerp. Exact names return signatures, available documentation and class members. Partial names return up to 30 matching names.

ParameterTypeDescription
name *string

read_palette

Read the active Pyxel palette and the palette indices used by image banks.

ParameterTypeDescription
script *stringLocal .pyxres file or trusted Pyxel script path.

read_image

Read palette-index pixels from a Pyxel image-bank region and optionally render it to PNG; inline=true returns the render as image content and makes render_path optional.

ParameterTypeDescription
image *integer
script *stringLocal .pyxres file or trusted Pyxel script path.
h
inlineboolean
render_path
w
xinteger
yinteger

read_tilemap

Read Pyxel tile coordinates, usage, bounds, source bank, and optional rendered output. bbox=[x,y,w,h] selects a region in tiles. inline=true returns the render as image content and makes render_path optional.

ParameterTypeDescription
script *stringLocal .pyxres file or trusted Pyxel script path.
tilemap *integer
bbox
inlineboolean
render_path

read_audio

Render one Pyxel sound or music slot to WAV and return measurable audio data. Set inline=true to return audio content (up to 4 MiB) and omit output_path if desired. Notes describe tracker fields.

ParameterTypeDescription
script *stringLocal .pyxres file or trusted Pyxel script path.
target *
inlineboolean
output_path

diff_frames

Compare two PNG frames pixel by pixel and return their changed region and ratio.

ParameterTypeDescription
frame_a *string
frame_b *string