Skip to main content
Glama

create_game_state_class_bp

Idempotent

Creates a GameState Blueprint subclass of AGameStateBase at a chosen content path without saving; returns existing matches or errors for invalid parents.

Instructions

Create a Blueprint subclass of AGameStateBase (or AGameState) at package_path/asset_name with FKismetEditorUtilities::CreateBlueprint, registered and marked dirty but NOT saved -- persist it with save_asset. Idempotent on re-run: a Blueprint already at that path whose parent derives from parent_class is returned as is with already_exists=true; one with another parent is an error and is left untouched. parent_class is read off the Blueprint. A parent_class that does not resolve or derive from AGameStateBase, or a name taken by another asset class, is an error. Refused during PIE unless force. Siblings: create_game_mode_class_bp, create_player_state_class_bp.

Returns: { asset_name, asset_path, package_class, parent_class, already_exists }

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.
asset_nameYesName for the new Blueprint asset.
package_pathNoTarget content folder; defaults to /Game/MCP.
parent_classYesParent class name; must derive from AGameStateBase.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.1.0

TDQS

A4.6/5.0
Behavior5/5

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

Goes well beyond the annotations (which only flag idempotent=true, destructive=false): it discloses that nothing is written to disk, the already_exists=true idempotent path, the error branch when a conflicting parent exists (left untouched), unresolvable/non-AGameStateBase parent errors, name-collision errors, and PIE refusal with the force escape hatch.

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?

Front-loaded with the core action, and each subsequent clause (idempotency, error cases, PIE refusal, siblings, return shape) carries distinct information. It is a dense single block rather than broken into scannable lines, which is the only structural weakness.

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 mechanics, persistence follow-up, idempotency semantics, failure modes, PIE restrictions, and the exact return fields despite there being no output schema. For a mutation tool with these annotations, nothing an agent needs to invoke it correctly is missing.

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 schema already documents all four parameters and the baseline is 3. The description still adds meaning: parent_class is read off the Blueprint and must derive from AGameStateBase, and name collisions with another asset class are an error — constraints not restated verbatim by the schema.

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 specific verb and resource — create a Blueprint subclass of AGameStateBase/AGameState — plus the target path (package_path/asset_name) and the engine call used. It explicitly distinguishes itself from siblings create_game_mode_class_bp and create_player_state_class_bp, so an agent can route without opening either 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 clear operational context: the asset is created dirty but NOT saved and must be persisted with save_asset, and it names the sibling creation tools. It stops short of spelling out when to prefer GameState over GameMode/PlayerState creation, leaving that to inference from purpose.

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