Animation Manage
animation_manageCreate and edit AnimationPlayers, animation libraries, tracks, and AnimationTree graphs—including state-machine transitions and blend-space points—to author Godot animations from an AI assistant.
Instructions
Animation authoring (players, libraries, tracks and AnimationTree graphs).
Ops: • tree_create(parent_path, player_path, name="AnimationTree", root_type="state_machine") Create an inactive AnimationTree linked to the player. root_type: state_machine|blend_tree|blend_space_1d|blend_space_2d. • tree_get(tree_path, graph_path="") Read graph nodes/points, properties, edges, triangles and tree parameters. • tree_node_add(tree_path, name, node_type="AnimationNodeAnimation", properties=None, position=None, graph_path="") Add a native node. position: {x,y}. State machines accept AnimationRootNodes. • tree_node_remove(tree_path, name, graph_path="") Remove a node and its edges. Undo restores identities, edges and parameters. • tree_node_set(tree_path, properties, graph_path="") Set editable properties of the selected graph node, e.g. animation or fadein_time. Configure variable input counts (0 to 256) at creation. This op preserves existing input topology. • tree_connect(tree_path, input_node, input_index, output_node, graph_path="") Connect a blend-tree input port. Occupied ports/outputs and cycles are refused. • tree_disconnect(tree_path, input_node, input_index, graph_path="") Disconnect a blend-tree input port. • tree_point_add(tree_path, name, position, node_type="AnimationNodeAnimation", properties=None, at_index=-1, graph_path="") Add a named blend-space point (native limit: 64). Names cannot contain '.' or '/'. position: number for 1D, {x,y} for 2D. at_index=-1 appends. • tree_point_set(tree_path, name, position, graph_path="") Move a blend-space point. Use tree_node_set at graph_path="Space/Point" for its properties. • tree_point_remove(tree_path, name, graph_path="") Remove a point. Undo restores its resource, name, index and manual triangles. • tree_transition_add(tree_path, from_state, to_state, graph_path="", properties=None) • tree_transition_set(tree_path, from_state, to_state, graph_path="", properties=None) • tree_transition_remove(tree_path, from_state, to_state, graph_path="") State-machine transitions. Properties include xfade_time, switch_mode, advance_mode, advance_condition and advance_expression. Start/End follow native restrictions.
Blend-space node properties include min_space, max_space, snap, labels, blend_mode, sync_mode and cyclic_length. 2D triangulation is automatic; a subsequent tree_get reads generated triangles after the editor updates them. Graph paths select nested resource names, e.g. "Locomotion/Blend"; empty selects tree_root. Graph writes are undoable and preserve shared resource identity. Enable a completed tree or set parameters with node_set_property (e.g. property="parameters/Blend/blend_amount").
• player_create(parent_path, name="AnimationPlayer") Create an AnimationPlayer with empty default library. • library_add(player_path, resource_path, library_name="") Attach a saved AnimationLibrary to an AnimationPlayer or AnimationTree. Undoable. Empty library_name selects the default library. Existing names/resources are refused. • library_remove(player_path, library_name="") Detach a library; clears autoplay if it points into that library. Undoable. • library_list(player_path) List library names, resource paths and clip names. Includes autoplay for AnimationPlayer. • delete(player_path, animation_name) Delete an animation clip from the default library. Undoable. • validate(player_path, animation_name) Check all track paths resolve. Returns broken_count + per-track issues. • add_property_track(player_path, animation_name, track_path, keyframes, interpolation="linear") Add a property track. track_path: "NodeName:property". keyframes: [{time, value, transition?}, ...]. interpolation: linear|nearest|cubic. • add_method_track(player_path, animation_name, target_node_path, keyframes) Add a method track. keyframes: [{time, method, args?}, ...]. • set_autoplay(player_path, animation_name="") Set autoplay. Empty animation_name clears. • play(player_path, animation_name="") Editor preview. Not saved with scene. • stop(player_path) Stop editor preview. Not saved with scene. • list(player_path) List animations with length, loop_mode, track_count, plus libraries and autoplay. • get(player_path, animation_name) Inspect a clip's tracks and keyframes in detail. • create_simple(player_path, name, tweens, length=None, loop_mode="none", overwrite=False) High-level: build a multi-track clip from tween specs in one call. tweens: [{target, property, from, to, duration, delay?, transition?}]. • preset_fade(player_path, target_path, mode="in", duration=0.5, animation_name="", overwrite=False) One-call fade-in/out (modulate.a). • preset_slide(player_path, target_path, direction="left", mode="in", distance=None, duration=0.4, animation_name="", overwrite=False) One-call slide-in/out (position). • preset_shake(player_path, target_path, intensity=None, duration=0.3, frequency=30.0, seed=0, animation_name="", overwrite=False) One-call shake (jittered position). • preset_pulse(player_path, target_path, from_scale=1.0, to_scale=1.1, duration=0.4, animation_name="", overwrite=False) One-call pulse / hover-bounce (3-keyframe scale ping-pong).
Preset target_path: accepts either a scene-absolute path (e.g. "/Main/World/Cube",
matching every other scene tool) or a path relative to the AnimationPlayer's
root_node (e.g. "World/Cube", matching how Animation tracks store node paths).
Scene-absolute targets outside the player's root_node subtree are converted to
a ..-prefixed track path via root_node.get_path_to(target), the same shape
the relative form already accepts.
Canonical call shape: {"op": "<verb>", "params": {...}}. Flat op parameters are accepted as a compatibility alias when the client transmits them; op and session_id remain top-level.
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": {
"op": "<op>"
},
"name": "animation_manage"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| op | Yes | ||
| params | No | ||
| session_id | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||