# UMG MCP

Web Manual · UE 5.8

README 中文

Current package

Unreal Engine 5.8 · Win64 · per-editor OS-assigned local bridge port.

AI-assisted UMG workflow

## Create Unreal UMG interfaces through explicit MCP tools.

UMG MCP lets an agent read the real widget tree, modify layout and slots, apply Blueprint logic, edit materials, create UMG animation, and round-trip UI assets as structured JSON.

Install in order Fab Marketplace GitHub

### Recommended path

1. 1 Install the Fab package or clone the source into `Plugins/UmgMcp`.
2. 2 Enable the plugin in Unreal Engine 5.8 and restart the editor.
3. 3 Configure a model provider or connect an external MCP client.
4. 4 Run the smoke test and create a small UMG asset first.

## Install

### Fab edition

Use this path for the packaged marketplace install and in-editor workflow.

1. Install UMG MCP from Fab for Unreal Engine 5.8.
2. Open your project, enable `UmgMcp`, and restart.
3. Open plugin settings and choose Google OAuth, Gemini API, ZhipuAI, Custom OpenAI-compatible endpoint, or local mode.
4. Use the chat panel or connect an external MCP client.

### Source edition

Use this path for protocol work, fixes, or manual integration.

    cd D:\UE5Project\YourProject
    mkdir Plugins
    cd Plugins
    git clone https://github.com/winyunq/UnrealMotionGraphicsMCP.git UmgMcp

Open the project in UE 5.8 and let Unreal Build Tool compile the plugin.

## Connect An MCP Client

Start Unreal Editor first. Each editor publishes its unique OS-assigned endpoint, and the Python MCP server discovers the selected editor bridge.

    {
      "mcpServers": {
        "UmgMcp": {
          "command": "uv",
          "args": [
            "run",
            "--directory",
            "D:\\UE5Project\\YourProject\\Plugins\\UmgMcp\\Resources\\Python",
            "UmgMcpServer.py"
          ]
        }
      }
    }

Use an absolute path.
The directory must be `Resources/Python`.
Escape Windows paths.
Write `D:\\Path` in JSON.
Verify with tests.
Run the APITest scripts before a large task.

## Tutorials

### Model Configuration

Set up local, Google OAuth, API key, ZhipuAI, and custom OpenAI-compatible providers.

### Chat Dialogue

Use chat, develop, learning, and task modes inside the editor workflow.

### MCP Support

See the major command families for widgets, Blueprint, materials, animation, and editor actions.

## Protocol Reference

Widget MCP Protocol Blueprint / BlueCode Protocol Material MCP Protocol Animation MCP Protocol Google OAuth Setup FabServer Serial Flow

## Troubleshooting

Symptom | Action
--- | ---
`ConnectionRefusedError` or `WinError 10061` | Open Unreal Editor, enable the plugin, restart, then reconnect the MCP client.
`uv` is not recognized | Install `uv` or create a local virtual environment under `Resources/Python`.
The wrong widget was edited | Set the active UMG target or pass the full asset path such as `/Game/UI/WBP_Login.WBP_Login`.