tool_find_references
Find all jump/call references to a label or screen across a Ren'Py project to support refactoring, dead-code detection, and missing-target checks.
Instructions
Find all jump/call references to a label or screen across the project.
Parses jump and call statements to build a reference map. Useful for refactoring (find all callers before renaming), detecting dead code (labels never jumped/called), and catching missing targets (jump to a label that doesn't exist).
Args: project_path: Absolute path to the Ren'Py project root directory. name: The label or screen name to search for (e.g. "arrow_round").
Returns: dict with {name, defined, definition, is_screen, callers, caller_count}.
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": {
"project_path": "<project_path>",
"name": "<name>"
},
"name": "tool_find_references"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | ||
| project_path | Yes |