Skip to main content
Glama

godot-mcp-extended

Originally based on Coding-Solo/godot-mcp by Solomon Elias (MIT). Independently developed as godot-mcp-extended since v0.2.0.

Made with Godot

                           (((((((             (((((((
                        (((((((((((           (((((((((((
                        (((((((((((((       (((((((((((((
                        (((((((((((((((((((((((((((((((((
                        (((((((((((((((((((((((((((((((((
         (((((      (((((((((((((((((((((((((((((((((((((((((      (((((
       (((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((
     ((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((
    ((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((
      (((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((
        (((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((
         (((((((((((@@@@@@@(((((((((((((((((((((((((((@@@@@@@(((((((((((
         (((((((((@@@@,,,,,@@@(((((((((((((((((((((@@@,,,,,@@@@(((((((((
         ((((((((@@@,,,,,,,,,@@(((((((@@@@@(((((((@@,,,,,,,,,@@@((((((((
         ((((((((@@@,,,,,,,,,@@(((((((@@@@@(((((((@@,,,,,,,,,@@@((((((((
         (((((((((@@@,,,,,,,@@((((((((@@@@@((((((((@@,,,,,,,@@@(((((((((
         ((((((((((((@@@@@@(((((((((((@@@@@(((((((((((@@@@@@((((((((((((
         (((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((
         (((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((
         @@@@@@@@@@@@@((((((((((((@@@@@@@@@@@@@((((((((((((@@@@@@@@@@@@@
         ((((((((( @@@(((((((((((@@(((((((((((@@(((((((((((@@@ (((((((((
         (((((((((( @@((((((((((@@@(((((((((((@@@((((((((((@@ ((((((((((
          (((((((((((@@@@@@@@@@@@@@(((((((((((@@@@@@@@@@@@@@(((((((((((
           (((((((((((((((((((((((((((((((((((((((((((((((((((((((((((
              (((((((((((((((((((((((((((((((((((((((((((((((((((((
                 (((((((((((((((((((((((((((((((((((((((((((((((
                        (((((((((((((((((((((((((((((((((


                          /$$      /$$  /$$$$$$  /$$$$$$$
                         | $$$    /$$$ /$$__  $$| $$__  $$
                         | $$$$  /$$$$| $$  \__/| $$  \ $$
                         | $$ $$/$$ $$| $$      | $$$$$$$/
                         | $$  $$$| $$| $$      | $$____/
                         | $$\  $ | $$| $$    $$| $$
                         | $$ \/  | $$|  $$$$$$/| $$
                         |__/     |__/ \______/ |__/

A Model Context Protocol (MCP) server for interacting with the Godot game engine.

Introduction

Godot MCP enables AI agents to launch the Godot editor, run projects, capture debug output, and control project execution. This direct feedback loop helps agents understand what works and what doesn't in real Godot projects, leading to better code generation and debugging assistance.

Related MCP server: Godot MCP

Features

  • Launch Godot Editor: Open the Godot editor for a specific project

  • Run Godot Projects: Execute Godot projects in debug mode

  • Capture Debug Output: Retrieve console output and error messages

  • Control Execution: Start and stop Godot projects programmatically

  • Get Godot Version: Retrieve the installed Godot version

  • List Godot Projects: Find Godot projects in a specified directory

  • Project Analysis: Get detailed information about project structure

  • Scene Management:

    • Create new scenes with specified root node types

    • Add nodes to existing scenes with customizable properties

    • Load sprites and textures into Sprite2D nodes

    • Export 3D scenes as MeshLibrary resources for GridMap

    • Save scenes with options for creating variants

  • UID Management (for Godot 4.4+):

    • Get UID for specific files

    • Update UID references by resaving resources

  • .NET Diagnostics (extended):

    • dotnet_build with structured file/line/code compiler diagnostics

    • dotnet_test test runs with structured results

  • Runtime observation & control (extended):

    • run_project_capture with [SIGNAL] markers and exit verdicts

    • Opt-in in-game hook (hook/signal_hook.gd) + hook_exec (tree|read|shot|quit|press|stats; shot returns path + base64)

  • Scene inspection & editing (new):

    • dump_scene, list_assets, get_project_settings (no Godot run needed)

    • set_node_property, remove_node, rename_node, duplicate_node, instance_scene, create_script, attach_script, connect_signal

    • check_script (fast GDScript parse), run_tests, export_check

  • Multi-host setup (extended): setup --host opencode|claude|codex|chatgpt|all

Requirements

  • Godot Engine installed on your system

  • Node.js (>=18.0.0) and npm

  • An AI agent that supports MCP

Quick Start

Claude Code

claude mcp add godot -- npx godot-mcp-extended

That's it. Restart Claude Code and your Godot MCP tools are available.

With environment variables:

claude mcp add godot -e GODOT_PATH=/path/to/godot -e DEBUG=true -- npx godot-mcp-extended

opencode

Easiest — use the built-in installer (backs up your config first):

node build/index.js setup --host opencode --godot-path /path/to/godot

Then restart opencode. Or add manually to ~/.config/opencode/opencode.json:

{
  "mcp": {
    "godot-mcp": {
      "command": ["node", "/path/to/godot-mcp-extended/build/index.js"],
      "enabled": true,
      "type": "local",
      "environment": { "GODOT_PATH": "/path/to/godot" },
      "timeout": 300000
    }
  }
}

ChatGPT desktop / Codex CLI

For Codex CLI, use the installer (appends a [mcp_servers.godot-mcp] table to ~/.codex/config.toml):

node build/index.js setup --host codex --godot-path /path/to/godot

For the ChatGPT desktop app, MCP config paths vary by version — run the installer for manual steps:

node build/index.js setup --host chatgpt --godot-path /path/to/godot

then add the printed command (node …/build/index.js with GODOT_PATH set) as a local MCP server and restart the app.

Runtime hook (opt-in)

run_project_capture observes games through [SIGNAL] log markers. For live inspection, install the optional in-game hook:

cp hook/signal_hook.gd /path/to/project/signal_hook.gd

then add to the project's project.godot:

[autoload]
SignalHook="*res://signal_hook.gd"

Restart the game via run_project; hook_exec can then run tree (subtree dump), read (read-only expression on a node, e.g. position), shot (viewport PNG), and quit (graceful exit).

Security boundary: the hook file is never installed automatically — you copy it yourself. It is dormant unless SIGNAL_HOOK=1 is in the environment (the sidecar sets it only for runs of projects containing the file). Commands are an allow-list (tree|read|shot|quit); read rejects sources containing set_, load(, OS., FileAccess, DirAccess, Engine, and friends, and the TCP server binds 127.0.0.1 only. Screenshots save inside the project under .signal/.

Add to your Cline MCP settings file (~/Library/Application Support/Code/User/globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json):

{
  "mcpServers": {
    "godot": {
      "command": "npx",
      "args": ["godot-mcp-extended"],
      "env": {
        "DEBUG": "true"
      },
      "disabled": false,
      "autoApprove": [
        "launch_editor",
        "run_project",
        "get_debug_output",
        "stop_project",
        "get_godot_version",
        "list_projects",
        "get_project_info",
        "create_scene",
        "add_node",
        "load_sprite",
        "export_mesh_library",
        "save_scene",
        "get_uid",
        "update_project_uids"
      ]
    }
  }
}

Using the Cursor UI:

  1. Go to Cursor Settings > Features > MCP

  2. Click on the + Add New MCP Server button

  3. Fill out the form:

    • Name: godot

    • Type: command

    • Command: npx godot-mcp-extended

  4. Click "Add"

  5. You may need to press the refresh button in the top right corner of the MCP server card to populate the tool list

Using Project-Specific Configuration:

Create a file at .cursor/mcp.json in your project directory:

{
  "mcpServers": {
    "godot": {
      "command": "npx",
      "args": ["godot-mcp-extended"],
      "env": {
        "DEBUG": "true"
      }
    }
  }
}

For any MCP-compatible client, use this configuration:

{
  "mcpServers": {
    "godot": {
      "command": "npx",
      "args": ["godot-mcp-extended"],
      "env": {
        "GODOT_PATH": "/path/to/godot",
        "DEBUG": "true"
      }
    }
  }
}

Environment Variables

Variable

Description

GODOT_PATH

Path to the Godot executable (overrides automatic detection)

DEBUG

Set to "true" to enable detailed server-side debug logging

git clone https://github.com/daremau/godot-mcp-extended.git
cd godot-mcp-extended
npm install
npm run build

Then point your MCP client to build/index.js instead of using npx.

Architecture

The Godot MCP server uses a bundled GDScript approach for complex operations:

  1. Direct Commands: Simple operations like launching the editor or getting project info use Godot's built-in CLI commands directly.

  2. Bundled Operations Script: Complex operations like creating scenes or adding nodes use a single, comprehensive GDScript file (godot_operations.gd) that handles all operations.

The bundled script accepts operation type and parameters as JSON, allowing for flexible and dynamic operation execution without generating temporary files for each operation.

Troubleshooting

  • Godot Not Found: Set the GODOT_PATH environment variable to your Godot executable path

  • Connection Issues: Ensure the server is running and restart your AI assistant

  • Invalid Project Path: Ensure the path points to a directory containing a project.godot file

  • Build Issues: Make sure all dependencies are installed by running npm install

  • Ensure the MCP server shows up and is enabled in Cursor settings (Settings > MCP)

  • MCP tools can only be run using the Agent chat profile (Cursor Pro or Business subscription)

  • Use "Yolo Mode" to automatically run MCP tool requests

License

This project is licensed under the MIT License - see the LICENSE file for details.

Available Tools

32 tools
add_nodeB

Add a node to an existing scene

Inputs: nodeName (required), nodeType (required), scenePath (required), projectPath (required), +2 more.

attach_scriptC

Attach an existing GDScript to a node in a scene

Inputs: nodePath (required), scenePath (required), scriptPath (required), projectPath (required).

check_scriptA

Parse a GDScript file with Godot --check-only and return structured errors

Inputs: filePath (required), projectPath (required).

connect_signalC

Connect a signal from one node to a method on another node in a scene

Inputs: scenePath (required), methodName (required), signalName (required), sourceNode (required), +2 more.

create_sceneA

Create a new Godot scene file

Inputs: scenePath (required), projectPath (required), rootNodeType.

create_scriptB

Create a new GDScript file in the project from a template or inline content

Inputs: filePath (required), projectPath (required), content, template, +1 more.

dotnet_buildB

Build the .NET solution/project of a Godot 4.x game and return structured compiler diagnostics

Inputs: projectPath (required), target, configuration, maxDiagnostics.

dotnet_testC

Run dotnet test for a Godot 4.x .NET project and return structured results

Inputs: projectPath (required), filter, configuration, maxDiagnostics.

dump_sceneA

Parse a .tscn scene file statically (no Godot run) and return its node tree with properties

Inputs: scenePath (required), projectPath (required).

duplicate_nodeC

Duplicate a node in an existing scene as a sibling

Inputs: nodePath (required), scenePath (required), projectPath (required), newName.

export_checkB

Validate export_presets.cfg and optionally run a real export (doExport=true)

Inputs: projectPath (required), preset, doExport.

export_mesh_libraryB

Export a scene as a MeshLibrary resource

Inputs: scenePath (required), outputPath (required), projectPath (required), meshItemNames.

get_debug_outputB

Get the current debug output and errors

Inputs: no named parameters.

get_godot_versionA

Get the installed Godot version

Inputs: no named parameters.

get_project_infoB

Retrieve metadata about a Godot project

Inputs: projectPath (required).

get_project_settingsB

Read project.godot and return parsed sections (application, autoload, input, etc.) capped for AI use

Inputs: projectPath (required).

get_uidB

Get the UID for a specific file in a Godot project (for Godot 4.4+)

Inputs: filePath (required), projectPath (required).

hook_execA

Send an allow-listed command (tree|read|shot|quit|press|stats) to the opt-in signal_hook in a running game. Requires an active run_project session with the hook installed.

Inputs: command (required), action, holdMs, target, +3 more.

instance_sceneC

Instance a source .tscn into another scene under a parent node

Inputs: scenePath (required), projectPath (required), sourceScene (required), parentNodePath (required), +1 more.

launch_editorC

Launch Godot editor for a specific project

Inputs: projectPath (required).

list_assetsB

List files inside a Godot project with optional extension filter and paging

Inputs: projectPath (required), limit, offset, subdir, +2 more.

list_projectsA

List Godot projects in a directory

Inputs: directory (required), recursive.

load_spriteC

Load a sprite into a Sprite2D node

Inputs: nodePath (required), scenePath (required), projectPath (required), texturePath (required).

remove_nodeB

Remove a node (and its children) from an existing scene

Inputs: nodePath (required), scenePath (required), projectPath (required).

rename_nodeC

Rename a node in an existing scene

Inputs: newName (required), nodePath (required), scenePath (required), projectPath (required).

run_projectC

Run the Godot project and capture output

Inputs: projectPath (required), scene.

run_project_captureA

Run a Godot project headless for a fixed duration, parse [SIGNAL] JSON markers from output, and return an exit verdict

Inputs: projectPath (required), scene, failOnError, durationSeconds.

run_testsB

Discover test scenes/scripts (test.tscn, test.gd, GUT) and run them headless with a summary

Inputs: projectPath (required), pattern, testTimeout.

save_sceneC

Save changes to a scene file

Inputs: scenePath (required), projectPath (required), newPath.

set_node_propertyB

Set a property on a node in an existing scene (offline, headless Godot)

Inputs: value (required), nodePath (required), property (required), scenePath (required), +1 more.

stop_projectA

Stop the currently running Godot project

Inputs: no named parameters.

update_project_uidsB

Update UID references in a Godot project by resaving resources (for Godot 4.4+)

Inputs: projectPath (required).

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    B3.2/5.0

    Scored across 32 tools

    Disambiguation4/5

    Most tools target clearly distinct resources or actions (scene editing, node ops, scripts, build, test, assets, settings). The main ambiguity is within the run/export families: run_project vs run_project_capture and export_check vs export_mesh_library require reading descriptions to choose correctly.

    Naming Consistency4/5

    29 of 32 tools follow a consistent verb_noun snake_case pattern (create_scene, add_node, run_tests, etc.). The three exceptions (dotnet_build, dotnet_test, hook_exec) use a noun_verb order, but they are internally consistent and readable.

    Tool Count3/5

    At 32 tools this is heavy, and some candidates could be consolidated (e.g. run_project and run_project_capture). However, the server is explicitly 'extended' and spans several broad Godot domains, so most tools earn their place.

    Completeness4/5

    Coverage is strong across scene lifecycle, node editing, scripting, running/debugging, build/test, assets, settings, and export. Minor gaps remain: no delete/rename scene or script tools, no disconnect_signal, and no explicit script content editing beyond creation from template.

    Maintenance

    ActivityMaintained
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      A
      quality
      D
      maintenance
      Enables AI assistants to interact with the Godot game engine by launching the editor, running projects, capturing debug output, managing scenes and nodes, and controlling project execution through a standardized interface.
      18
      180 npm
      11
      MIT
    • A
      license
      B
      quality
      Not graded
      maintenance
      Enables AI assistants to interact with the Godot game engine by launching the editor, running projects, capturing debug output, managing scenes and nodes, and controlling project execution through a standardized interface.
      14
      180 npm
      1
      -
    • A
      license
      B
      quality
      C
      maintenance
      Enables AI assistants to interact with the Godot game engine, including launching the editor, running projects, capturing debug output, and managing scenes.
      84
      56 PyPI
      1
      MIT