Skip to main content
Glama

add_anim_state_machine

Idempotent

Add a named state machine node to an Animation Blueprint's top-level AnimGraph, mark it modified, and save without compiling; duplicate names return the existing node unchanged.

Instructions

Add a state machine node named machine_name to the top-level AnimGraph of an Animation Blueprint, then mark the blueprint structurally modified and save it without compiling (compile_anim_blueprint gives runtime effect). Idempotent by name: an existing machine is returned unchanged (already_existed true). The node starts with only its entry and is not connected to the Output Pose: wire it with connect_anim_graph_pins, fill it with add_anim_state, add_anim_conduit and add_anim_transition, or build it in one call with build_animation_state_machine. Refused while PIE runs unless force=true; a failed save is an error, the change kept in memory.

Returns: { anim_blueprint_path: string, machine_name: string, node_class: string, state_machine_graph: string, state_machine_created: bool, already_existed: bool, saved: bool, state_machine_count: int, save_error?: string }

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
forceNoOptional. This command is REFUSED while a Play-in-Editor session is running: it either compiles a Blueprint (the reinstancer can retain a world, and CheckForWorldGCLeaks is Fatal -- it KILLS the editor) or writes to disk (Editor.AllowSavingAssetsDuringPIE=0 makes the engine refuse the write, so it would report success without writing a byte). Stop PIE and retry instead; force=true runs it anyway, at your own risk.
machine_nameYesName for the new state machine
blueprint_nameNoAlias of `anim_blueprint_path` (same value, same meaning). Accepted because sibling tools spell this parameter differently; prefer `anim_blueprint_path`.
anim_blueprint_pathNoPath to the UAnimBlueprint asset

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.1.0

TDQS

A4.8/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Beyond the annotations (idempotentHint=true, destructiveHint=false, readOnlyHint=false) it discloses genuinely new behavior: idempotency is by name and returns already_existed=true, the new node starts unconnected to Output Pose, the save happens without compiling, and a failed save is an error with the change kept in memory. It even explains the PIE refusal mechanism.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Dense but front-loaded, leading with the core action before branching into workflow, PIE constraints, and the return shape. Every sentence carries information, though it reads as a single long block rather than clearly separated sections.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a mutation tool with no output schema, the description supplies the return shape, the save/idempotency semantics, the PIE refusal rule, and the follow-up wiring steps. An agent has everything needed to invoke and interpret it correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline is 3, but the description adds meaning beyond the schema: machine_name drives name-based idempotency, and force=true overrides the PIE refusal at the caller's risk. It does not cover the blueprint_name alias, but the schema already documents that.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description gives a specific verb and resource ('Add a state machine node named machine_name to the top-level AnimGraph of an Animation Blueprint') plus the side effects (mark structurally modified, save without compiling). It explicitly distinguishes itself from the sibling build_animation_state_machine, which does the whole build in one call.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It states when to use the tool and names the concrete alternatives and follow-up steps: wire with connect_anim_graph_pins, fill with add_anim_state/add_anim_conduit/add_anim_transition, or use build_animation_state_machine instead. It also gives the exclusion condition for force=true (refused during PIE).

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools