Skip to main content
Glama

add_state_enter_condition

Attach an enter-condition node to a state's EnterConditions in a UStateTree, resolving the condition struct by name via reflection.

Instructions

Attach an enter-condition node (by struct name, resolved via reflection) to a state's EnterConditions on a UStateTree.

Returns: { tree_path, state_name, condition_struct, enter_condition_count, added, saved }

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tree_pathYesAsset path to the UStateTree
state_nameYesName of the state to add the enter condition to
condition_structYesCondition struct name or /Script path; must derive from StateTreeConditionBase (e.g. "StateTreeRandomCondition")

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv1.2.0
    • changedInput schema / required
      Previous value: -[
      -  "tree_path",
      -  "condition_struct"
      -]New value: +[
      +  "tree_path",
      +  "state_name",
      +  "condition_struct"
      +]
  2. First observedv1.1.0

TDQS

B3.4/5.0
Behavior3/5

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

Annotations already disclose readOnlyHint=false, destructiveHint=false, and idempotentHint=false, so the safety profile is covered. The description adds a modest behavioral detail ('resolved via reflection') and the return field 'saved', which hints at persistence, but it does not state auth requirements, reversibility, or rate limits.

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

Conciseness5/5

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

Two sentences with zero waste: the purpose is front-loaded and the return shape is appended compactly. Every element earns its place and nothing is repeated unnecessarily.

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

Completeness4/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 usefully supplies the return payload shape (tree_path, state_name, condition_struct, enter_condition_count, added, saved) and the schema fully covers the three inputs. It is missing prerequisites and does not clarify whether the asset is saved automatically or via the 'saved' flag, so it is strong but not complete.

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

Parameters3/5

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

Schema description coverage is 100%, so all three parameters are already documented in the input schema. The description only adds a small clarification that condition_struct is resolved via reflection, but otherwise adds no syntax or format detail beyond what the schema provides, so the baseline 3 is appropriate.

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

Purpose4/5

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

The description uses a specific verb ('Attach') and a precise resource ('enter-condition node to a state's EnterConditions on a UStateTree'), making the operation clear. It implicitly distinguishes itself from related tools like add_transition_condition or add_state_task by naming the exact node type, but it never explicitly names a sibling or scoping boundary.

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

Usage Guidelines2/5

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

No when-to-use guidance is provided. The description does not say when this should be used instead of add_transition_condition or other state-tree mutation tools, nor does it state prerequisites such as needing the state to already exist or the asset to be loaded.

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