add_script_function
Append a function to a GDScript file by providing the script path, function name, parameters, body, and optional return type. Enables programmatic script modification in Godot Engine projects.
Instructions
Append a function to GDScript.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| body | No | Function body | pass |
| path | Yes | Path to .gd script file | |
| params | No | Parameter names (e.g. ["delta: float"]) | |
| func_name | Yes | Function name | |
| after_func | No | Insert after this function | |
| return_type | No | Return type hint |