Add a costume to a sprite
add_costumeAdd a new costume to any sprite in a Scratch project, using either a built-in shape or an uploaded image file.
Instructions
Adds another costume to an existing sprite, from a built-in shape or an image file.
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": {
"target": "<target>"
},
"name": "add_costume"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file | No | Path to an svg, png or jpg | |
| name | No | Costume name when loading from a file | |
| target | Yes | Sprite name | |
| costume | No | Built-in costume name |