Skip to main content
Glama

add_blueprint_function

Destructive

Create a new Blueprint function graph or override an inherited/interface function; it refuses name collisions and requires compiling before adding parameters.

Instructions

Create a NEW function graph on a Blueprint, or with override=true a real OVERRIDE of an inherited/interface member (delegated to implement_interface_function, so an event-shape member becomes an event override node and a value-returning one an override graph). It REFUSES rather than guessing: a name that collides with an overridable inherited function errors with a hint instead of silently creating a "_0" shadow, and an EVENT-shape member already shadowed by a local function graph errors telling you to remove that graph first. The new graph does not exist in the generated class until compile_blueprint, so compile BEFORE add_function_parameter or any node that calls it -- otherwise a build_blueprint_graph step fails with "Function not found" and rolls the whole batch back.

Returns: { blueprint_name: string, function_name: string, graph_name: string, success: bool [, kind, already_existed, node_id, already_exists, is_interface_function, note] } -- with override=true the payload is implement_interface_function's (kind='function'|'event', graph_name or node_id). success:true can come back WITHOUT the graph actually appearing, so confirm with get_blueprint_functions before wiring it.

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.
overrideNoOptional. When true, create an OVERRIDE of an inherited function ('My Blueprint > Override'): resolves the interface/parent-virtual signature and creates the override graph (function-shape) or event override node (event-shape) with the inherited signature + exact name -- NOT a new deduped function. When omitted and the name collides with an inherited overridable function, the call errors with a hint (instead of silently making a '<name>_0' shadow); pass override=false to force a brand-new function anyway.
function_nameYesName for the new function; with override=true, the EXACT name of the inherited (interface or parent-class) function to override.
blueprint_nameNoName of the blueprint
blueprint_pathNoAlias of `blueprint_name` (same value, same meaning). Accepted because sibling tools spell this parameter differently; prefer `blueprint_name`.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.1.0

TDQS

A4.4/5.0
Behavior5/5

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

Annotations cover the safety profile (destructive, non-idempotent, non-readonly), and the description adds rich context beyond that: clone-on-collision refusal with hints instead of a <name>_0 shadow, the exact error for a shadowed event member, the compile-order prerequisite that a build_blueprint_graph step will fail and roll back the batch, and the warning that success:true may not mean the graph exists. For a mutating tool this is unusually thorough.

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?

First sentence front-loads the core action and the override branch, then warnings follow. The sentence about the return payload is long but earns its place by flagging the misleading success:true. Slightly dense with parenthetical caveats, but every sentence carries actionable information.

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?

Covers creation semantics, override vs new, refusal behavior, compile ordering, editor-killing PIE hazard for force, and the false-positive success:true. With no output schema, the inline Returns block fills the gap. An agent has everything needed to call it correctly and interpret the result.

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 coverage is 100%, so the schema already documents function_name, override, force, blueprint_name, and blueprint_path. The description clarifies the override=true semantics (exact inherited name, graph vs event node) and the override=false escape hatch, matching the schema's own text, but adds little beyond what the structured fields already carry, making baseline 3 appropriate.

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?

States a precise verb and resource ('Create a NEW function graph on a Blueprint') and explicitly covers the override=true variant, mapping it to the sibling implement_interface_function. An agent can distinguish this from add_blueprint_variable, add_function_parameter, or override_interface_member without opening any schema.

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?

Gives strong conditional routing: use override=true for inherited/interface members, override=false to force a brand-new function, and mandates compile_blueprint before add_function_parameter. It does not explicitly name siblings like override_interface_member or implement_interface_function as alternative entry points for non-override cases, leaving a small gap, but the when-to-use logic is clear.

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