execute_lua
Execute custom Lua scripts on a DCS server to perform operations beyond standard tool capabilities. Returns the execution result.
Instructions
Execute arbitrary Lua code on DCS server. Returns the result of the executed code. Use this for custom operations not covered by other tools.
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": {
"code": "<code>"
},
"name": "execute_lua"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| code | Yes | Lua code to execute in DCS | |
| environment | No | DCS environment to execute in (mission for in-game, gui for main menu) | mission |