Skip to main content
Glama

add_cast_node

Add a cast node to convert a generic object reference into a specific class, unlocking access to that Blueprint's unique variables and functions.

Instructions

Add a Cast To [ClassName] node.

Casting is used to convert a generic object/actor reference to a specific type, allowing access to that Blueprint's unique variables and functions.

Args: blueprint_name: Blueprint name target_class: Class to cast to (e.g., "BP_MyCharacter", "ACharacter") node_position: Optional [X, Y] graph position

Returns: Dict with 'node_id'; pins: 'Object' input, 'then'/'Cast Failed' outputs, 'As [ClassName]' output for the cast result

KB: see knowledge_base/02_BLUEPRINT_COMMUNICATION.md#overview Example: add_cast_node(blueprint_name="/Game/MCP_Test/BP_Example", target_class="Actor")

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
target_classYes
node_positionNo
blueprint_nameYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A4.2/5.0
Behavior4/5

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

With no annotations provided, the description carries the behavioral burden. It discloses that this adds a node, returns a dict with node_id, and details the expected pins ('Object' input, 'then'/'Cast Failed' outputs, 'As [ClassName]' output). It does not discuss failure behavior or prerequisites like blueprint existence, but the core behavioral disclosure is solid.

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?

The description is well-structured with a front-loaded purpose, Args, Returns, KB reference, and example. Each section earns its place and the content is compact given the information it conveys.

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 simple 3-parameter node-creation tool, this description covers action, rationale, all arguments, return shape, and a usage example. The output schema also exists to further specify return values, and the KB reference adds useful context. Minor missing preconditions are not critical here.

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?

The input schema has 0% description coverage, but the description compensates by documenting all three parameters: blueprint_name, target_class with concrete examples, and optional node_position with format guidance. The example further clarifies the expected asset-path format.

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 clearly states the action: 'Add a Cast To [ClassName] node', and explains the purpose of casting, so an agent knows exactly what the tool does. It doesn't explicitly differentiate from the sibling 'add_blueprint_cast_node', but the conceptual explanation reduces ambiguity.

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

Usage Guidelines4/5

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

The description explains when casting is appropriate: to convert a generic object/actor reference to a specific type so you can access that Blueprint's unique variables and functions. It gives solid usage context but does not name explicit alternatives or exclusion criteria.

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