get_function_body
Extract a named function's complete body from .pwn/.inc files, returning only the code with optional doc comments. Avoids reading the entire file for faster, targeted access.
Instructions
Extract the complete body of a function by name from a .pwn/.inc file. Much more efficient than reading the entire file. Returns only the function code with optional doc comments.
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>",
"functionName": "<functionName>"
},
"name": "get_function_body"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | Path to the .pwn/.inc file | |
| includeDoc | No | Include doc comments above the function | |
| functionName | Yes | Name of the function to extract |