Skip to main content
Glama

add_set_material_node

Add a Set Material node to a Blueprint event graph to swap an actor's material when a specified event, such as a hit, occurs.

Instructions

Add a "Set Material" node to a Blueprint event graph triggered by an event.

This creates the core gameplay interaction from Ch. 5: detecting a hit on an actor and swapping its material (e.g., cylinder turns red when shot).

Args: blueprint_name: Target Blueprint (e.g., "BP_CylinderTarget") component_name: Mesh component name (e.g., "StaticMeshComponent") material_path: Material asset path (e.g., "/Game/Materials/M_TargetRed") event_name: Event that triggers the material change ("ReceiveHit", "ReceiveBeginPlay") node_position: [X, Y] position in graph

KB: see knowledge_base/08_MATERIALS_AND_RENDERING.md#overview Example: add_set_material_node(blueprint_name="/Game/MCP_Test/BP_Example", component_name="ExampleComponent", material_path="/Game/MCP_Test/M_Example")

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
event_nameNoReceiveHit
material_pathYes
node_positionNo
blueprint_nameYes
component_nameYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A4/5.0
Behavior3/5

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

No annotations are provided, so the description must disclose behavior. It describes what the tool does (adds a node) and the gameplay purpose, but it does not mention side effects, prerequisites (e.g., blueprint existence), whether it wires the event to the node, or any return values. The mutation aspect is implied but not explicitly stated in terms of persistence or compilation needs.

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?

The description is well-structured with a purpose statement, an Args section, a KB reference, and an example. It is not overly verbose and front-loads the main purpose. The example is useful but could be more compact; still, it earns its place.

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?

Given the 5-parameter complexity and presence of an output schema, the description covers the essential information: what the tool does, parameters, and an example. It does not explain the return format (though output schema exists) or mention prerequisites like the blueprint needing to be loaded. These are minor gaps given the output schema and the clarity of the parameters.

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

Parameters5/5

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

Schema coverage is 0%, so the description carries full responsibility for parameter explanation. It lists all 5 parameters with clear descriptions and example values (blueprint_name, component_name, material_path, event_name, node_position). This goes well beyond the raw schema types and provides actionable guidance.

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 states a clear verb and resource: 'Add a "Set Material" node to a Blueprint event graph'. It also explains the intended gameplay effect (swapping material on hit), which distinguishes it from generic node-adding tools. This is specific and unambiguous.

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

Usage Guidelines3/5

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

The description provides context (core gameplay interaction from Ch. 5) but does not explicitly state when to use this tool versus alternatives like setup_hit_material_swap or add_hit_event. There are no exclusions or comparisons to sibling tools, so an agent must infer when this is the right choice.

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