@uemcp/server 1.11.0 → 1.12.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/README.md +35 -1
  2. package/dist/index.mjs +1140 -35
  3. package/package.json +1 -1
package/README.md CHANGED
@@ -64,6 +64,7 @@ The MCP tool surface currently exposes:
64
64
  - `disconnect_pins`
65
65
  - `set_pin_default`
66
66
  - `list_available_nodes`
67
+ - `layout_graph`
67
68
  - `set_viewport_camera`
68
69
  - `focus_actors`
69
70
  - `set_view_mode`
@@ -139,6 +140,14 @@ The MCP tool surface currently exposes:
139
140
  - `add_nav_link`
140
141
  - `find_path`
141
142
  - `test_reachability`
143
+ - `create_smart_object_definition`
144
+ - `get_smart_object_definition`
145
+ - `add_smart_object_component`
146
+ - `create_mass_entity_config`
147
+ - `edit_mass_entity_config`
148
+ - `get_mass_entity_config`
149
+ - `validate_mass_entity_config`
150
+ - `diagnose_navmesh`
142
151
 
143
152
  ## Project Identity
144
153
 
@@ -346,7 +355,7 @@ This is intended to let an MCP client resolve the canonical Unreal project ident
346
355
  - `create_folder` reports `state: 'exists'` rather than failing when the folder is already there, since that is the state the caller wanted. A content folder is an Asset Registry entry until something is saved into it, so an empty one does not survive an editor restart — the response says so
347
356
  - `get_asset_metadata` answers from the Asset Registry's `FAssetData` and **never loads the package**: class, package name and path, on-disk size, and the registry tag map — which carries a Blueprint's parent class, a texture's dimensions, a DataTable's row struct. `loaded` reports whether it happens to be in memory already; `false` is normal
348
357
 
349
- ### `list_graph_nodes` / `add_graph_node` / `remove_graph_node` / `connect_pins` / `disconnect_pins` / `set_pin_default` / `list_available_nodes`
358
+ ### `list_graph_nodes` / `add_graph_node` / `remove_graph_node` / `connect_pins` / `disconnect_pins` / `set_pin_default` / `list_available_nodes` / `layout_graph`
350
359
 
351
360
  - Blueprint graph authoring. `get_blueprint_graph` reads a graph; these write to one, and they work on any `UEdGraph` — an event graph or function, an Animation Blueprint AnimGraph, a Material graph
352
361
  - **Nodes are addressed by GUID, never by index.** A graph's node array reorders on every edit and recompile, so an index read a moment ago can name a different node by the time it is written back. `nodeId` from `list_graph_nodes` is what every other tool here takes. `list_graph_nodes` is the only read here, so it is the only one that takes `loadIfNeeded`; the write tools need the asset in memory regardless
@@ -354,6 +363,8 @@ This is intended to let an MCP client resolve the canonical Unreal project ident
354
363
  - `connect_pins` asks the schema's `CanCreateConnection` before connecting, so an illegal wire comes back with **the schema's own refusal text** rather than a generic failure after the fact
355
364
  - `set_pin_default` refuses an output pin and a pin that is already connected — a connected pin takes its value from the wire, so a literal there would be stored and then ignored. The stored value is validated after the write and the previous literal restored if the schema rejects it
356
365
  - `list_available_nodes` answers from `FBlueprintActionDatabase` filtered by this graph's context, so what it lists is what the graph would actually accept rather than every node class the editor knows about
366
+ - `layout_graph` arranges a Blueprint graph so **no two nodes overlap**: exec flow is layered left to right from each event, a branch fans its successors out downward, and pure nodes sit in the column left of the node that consumes them. Comment boxes are left where they are. It is **one undo step**. Node sizes are estimated from the title and pin labels, because the rendered size belongs to a Slate widget that exists only while the graph is open in an editor tab
367
+ - `add_graph_node` with `autoLayout` moves **only the new node**: from `position` it slides down until it overlaps nothing, and with no `position` it starts just right of the existing nodes. The response reports where it landed. Relaying out the whole graph on every add would move nodes the caller already reasoned about
357
368
  - Every edit marks the Blueprint structurally modified and leaves it **dirty and uncompiled** — compose with `compile_blueprint` and `save_asset`
358
369
 
359
370
  ### `set_viewport_camera` / `focus_actors` / `set_view_mode` / `toggle_show_flags` / `high_res_screenshot`
@@ -682,6 +693,7 @@ This is intended to let an MCP client resolve the canonical Unreal project ident
682
693
  - `create_nav_area` makes a nav area Blueprint under `NavArea` (or one of the stock parents) and reports `generatedClassPath` — the class, not the asset, is what a modifier volume or a link references
683
694
  - `add_nav_modifier_volume` places an `ANavModifierVolume` and builds its cube brush through the same actor factory the place-actor panel uses. Without that brush the volume covers nothing, so a non-positive extent is refused rather than placed
684
695
  - `add_nav_link` replaces the proxy's default link with the ones the request carries. `left` and `right` are offsets from the actor, the space the level editor's own link handles move in, and the response reports them in world space so a link and the `find_path` that crosses it can be compared directly
696
+ - Detour joins a link only when its two ends lie in the same navmesh tile or neighboring ones. A longer link still builds, connected at one end, so nothing can cross it and the build reports no error; `add_nav_link` says so in `message` when a link spans more than one tile (`TileSizeUU`, 1000 units by default)
685
697
  - All three leave the navmesh untouched until the next `build_navigation`, and say so through `rebuildRequired`
686
698
 
687
699
  ### `find_path` / `test_reachability`
@@ -691,6 +703,28 @@ This is intended to let an MCP client resolve the canonical Unreal project ident
691
703
  - `reachable` means a path that actually arrives. A partial path proves the goal is **not** reachable however far along it got, so it never counts as reachable in `find_path`
692
704
  - `test_reachability` answers a batch of pairs without returning path geometry, and fails one pair rather than the request when an actor path no longer resolves — a sweep of spawn points against objectives is worth answering for the pairs that did resolve
693
705
 
706
+ ### `create_smart_object_definition` / `get_smart_object_definition` / `add_smart_object_component`
707
+
708
+ - Backed by the SmartObjects engine plugin, which MCPBridge requires: the editor enables it with MCPBridge, and a project that disables it cannot load MCPBridge at all
709
+ - A definition is created with its slots in one call: offset and rotation relative to the owning actor, activity tags, an enabled flag and behavior definitions (instanced `USmartObjectBehaviorDefinition` subclasses configured through `params`). Activity tags must already be registered; a definition missing one is refused and nothing is left behind
710
+ - Both the create and the read report `valid` and the engine's `validationMessages`. The Smart Object subsystem refuses to register a component whose definition fails validation, most often a slot with no behavior definition and no default, so `valid: false` means nothing can ever claim it
711
+ - `add_smart_object_component` takes exactly one of `blueprintPath` (the Blueprint is recompiled) or `actorPath` (a placed actor in the editor level). An existing Smart Object component is pointed at the new definition rather than joined by a second, because an actor carrying two registers as two objects; `created` says which happened. A Blueprint that inherits one from its parent class is refused with `inherited_smart_object_component`, since that component belongs to the parent. The component registers with the subsystem when play begins
712
+
713
+ ### `create_mass_entity_config` / `edit_mass_entity_config` / `get_mass_entity_config` / `validate_mass_entity_config`
714
+
715
+ - Author a `UMassEntityConfigAsset`, the trait list a Mass agent is spawned from. `create_mass_entity_config` takes an optional `parentConfigPath`; a trait the child owns overrides the parent's trait of the same class
716
+ - `edit_mass_entity_config` applies `add`, `remove` and `set` edits in order and reports each one. Traits are named by class (`MassMovementTrait`, `MassLODCollectorTrait`, `MassVisualizationTrait`, `MassStateTreeTrait`, or a `/Script/Module.Class` path), and properties are `{ propertyPath, value }` pairs in exported-text form, the same shape `set_asset_property` takes. Only the config's own traits are edited, never a parent's. A new trait whose properties are rejected is taken back out
717
+ - `get_mass_entity_config` reads the parent and each own trait with its editable properties as exported text, trimmed by encoded size with `truncated` set
718
+ - `validate_mass_entity_config` builds the entity template in the editor world, the way the asset editor's Validate button does, and returns the engine's own error and warning lines verbatim in `messages`
719
+ - Backed by the `MassGameplay` and `MassAI` engine plugins, which MCPBridge requires: the editor enables them with MCPBridge, and a project that disables either cannot load MCPBridge at all. Validation returns `state: 'unsupported'` with a reason when the editor world has no Mass entity subsystem (`mass.RuntimeSubsystemsEnabled` off)
720
+
721
+ ### `diagnose_navmesh`
722
+
723
+ - A read-only audit of the editor level's navmesh: missing `NavMeshBoundsVolume`s, no navigation data or an empty navmesh, disconnected islands, and spawn points that are off the navmesh or cannot path to the first one. Each finding lands in `issues` with a `code`, and `healthy` is true when there are none. Nothing is rebuilt or fixed
724
+ - Islands are the connected components of the Recast polygon graph, nav links included, listed largest walkable area first with poly count, area and bounds. One-way links still join two areas, so a drop-down ledge is not reported as a stray island. `islandCount` stays the full count when `maxIslands` cuts the list
725
+ - Every `PlayerStart` is checked by default; AI spawners have no common base class, so a level's own spawn actors are named in `spawnActorPaths`. Player starts come first, and the first spawn on the navmesh is the anchor every other spawn is path-tested against with the same query `find_path` runs. Spawns on different islands are reported unreachable from the island map without a search. A spawn the anchor reaches is also path-tested back to it, and one with no way back (past a one-way link) is reported as `spawn_cannot_return`. Every spawn is checked; only the returned `spawnPoints` list is capped
726
+ - An island no spawn point stands on is reported as `island_without_spawn`: the isolated platform an AI can be placed on but never walk off. A level with no navmesh at all reports that once rather than blaming every spawn point for it
727
+
694
728
  ## MCP Resources
695
729
 
696
730
  Resources carry context a client can attach without spending a tool call and a model turn. The `registry`, `engines` and `workspace` resources are served from in-memory state or the local filesystem: **those reads never open a bridge socket and never wait on the editor**, so an unreachable or absent editor produces a structured payload rather than a timeout. The `project` resources are the exception — they are the editor-backed reads, and they report `found: false` with a `reason` instead of throwing when the editor is gone.