script_attach
Attach a script to a node in the scene tree, replacing any existing script. Provide the node path and script path.
Instructions
Attach a script to a node in the scene tree.
Replaces any existing script on the node. Undoable.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | Scene path of the node (e.g. "/Main/Player"). | |
| session_id | No | Optional Godot session to target. Empty = active session. | |
| script_path | Yes | res:// path of the .gd (e.g. "res://scripts/player.gd"). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||