export_layers
Export each pixel-containing layer of one frame as a canvas-sized PNG with layer opacity and blend mode applied, safe filenames, hidden-layer control, and overwrite protection.
Instructions
Write one canvas-sized PNG per layer of one frame; the sprite is not changed.
Every layer that holds pixels is exported, layers inside groups too; groups themselves get no file. Each layer is shown alone with its opacity and blend mode. Files are named after the layer path ("arms/left" -> arms_left.png) with characters Windows does not allow replaced by _, reserved names such as CON prefixed with _, and _2, _3... added to repeated names. Hidden layers (or layers in hidden groups) are skipped and listed unless include_hidden is true. Existing files are refused unless overwrite is true. Not available in batch.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"path": "<path>",
"output_dir": "<output_dir>"
},
"name": "export_layers"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | Sprite file. Relative paths resolve against the server root. | |
| frame | No | 1-based frame to export | |
| overwrite | No | Replace files that already exist | |
| output_dir | Yes | Folder for the PNG files; created when missing | |
| include_hidden | No | Export hidden layers too |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||