write_addon_file
Writes text source files (.js, .cfg, .vmat, panorama XML/CSS) into a Source 2 addon for cs2 or deadlock; use overwrite=true to replace an existing file.
Instructions
Write a text source file (.js, .cfg, .vmat, .vdata, panorama .xml/.css, ...) into an addon. Binary/compiled assets are produced by Valve's tools, not written here. Use overwrite=true to replace.
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": {
"name": "<name>",
"path": "<path>",
"content": "<content>"
},
"name": "write_addon_file"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| game | No | Game id: one of cs2, deadlock | cs2 |
| name | Yes | Addon name: lowercase [a-z0-9_], e.g. 'jump_arena' | |
| path | Yes | Path inside the addon, e.g. 'scripts/jump_arena.js' | |
| content | Yes | ||
| overwrite | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | ||
| size | Yes |