build_control_variable
Build a Control Variables event command for insertion, applying arithmetic operations to variables or ranges using constants, variables, random ranges, or game data.
Instructions
Build a Control Variables (122) event command for insertion via insert_event_commands. Applies operation (set/add/sub/mul/div/mod) to a variable (or the inclusive variableId..endId range) using an operand: constant, another variable, a random range, or game_data (item/actor/party/… readouts). Read-only: returns { command }.
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": {
"variableId": "<variableId>",
"operand": "<operand>"
},
"name": "build_control_variable"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| endId | No | Inclusive range end (default = variableId, a single variable) | |
| indent | No | Indentation level (default 0) | |
| operand | Yes | The right-hand operand of the Control Variables command | |
| operation | No | Arithmetic applied to the target (default set) | |
| variableId | Yes | The target variable id (range start) |