Godot MCP

Godot MCP

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.

Category
访问服务器

README

Godot MCP Server

A Model Context Protocol (MCP) server that enables AI assistants to interact with the Godot game engine. Control the editor, run projects, manage scenes, and capture debug output through a standardized interface.

Features

  • Debug Support: Capture output, connect to remote debugger, get real-time logs
  • Seamless Integration between Godot Editor Write code in godot editor, run, and debug with AI assistance. No longer need of running in blind or without editors.
  • Project Management: Launch editor, run projects, list and inspect Godot projects
  • Scene Manipulation: Create scenes, add nodes, configure properties
  • Asset Loading: Load sprites, textures, and export mesh libraries
  • Cross-Platform: Windows, macOS, and Linux support

Installation

Prerequisites

Install from npm (coming soon)

npm install -g godot-mcp

Install from source

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

Configuration

For Claude Desktop

Add to your Claude Desktop configuration file:

macOS: ~/Library/Application Support/Claude/claude_desktop_config.json

Windows: %APPDATA%\Claude\claude_desktop_config.json

Linux: ~/.config/Claude/claude_desktop_config.json

{
  "mcpServers": {
    "godot": {
      "command": "node",
      "args": ["/path/to/godot-mcp/build/index.js"],
      "env": {
        "GODOT_PATH": "/path/to/your/godot/executable"
      }
    }
  }
}

For Claude Code

Claude Code supports MCP servers direct configuration.

Edit .mcp.json:

{
  "mcpServers": {
    "godot": {
      "command": "node",
      "args": ["/path/to/godot-mcp/build/index.js"],
      "env": {
        "GODOT_PATH": "/path/to/your/godot/executable",
        "DEBUG": "true"
      }
    }
  }
}

Verify the configuration:

claude mcp list

For Cursor IDE

Cursor supports MCP servers through project-specific or global configuration.

Option 1: Project-Specific (Recommended for Godot projects)

Create .cursor/mcp.json in your project root:

{
  "mcpServers": {
    "godot": {
      "command": "node",
      "args": ["/path/to/godot-mcp/build/index.js"],
      "env": {
        "GODOT_PATH": "/path/to/your/godot/executable",
        "DEBUG": "true"
      }
    }
  }
}

Option 2: Global Configuration

Create ~/.cursor/mcp.json in your home directory with the same format.

Option 3: Via Cursor Settings UI

  1. Open Cursor Settings → Features → MCP
  2. Click "+ Add New MCP Server"
  3. Fill in:
    • Name: godot
    • Command: node
    • Args: /path/to/godot-mcp/build/index.js
    • Environment: GODOT_PATH=/path/to/your/godot/executable

Verify in the Output panel (Ctrl+Shift+U) → Select "MCP Logs"

Environment Variables

  • GODOT_PATH: Path to Godot executable (optional if Godot is in PATH or standard location)
  • DEBUG: Set to "true" to enable detailed logging

Platform-Specific Godot Paths

Windows:

C:\Program Files\Godot\Godot.exe

macOS:

/Applications/Godot.app/Contents/MacOS/Godot 

(do not include .app, just the executable path without ending of .app)

Linux:

/usr/bin/godot
/usr/local/bin/godot
/snap/bin/godot

Available Tools

The MCP server provides the following tools that AI assistants can use:

Project Management

  • launch_editor - Launch Godot editor for a specific project
  • run_project - Run a Godot project and capture output
  • stop_project - Stop the currently running project
  • list_projects - Find Godot projects in a directory
  • get_project_info - Get metadata about a Godot project
  • get_godot_version - Get the installed Godot version

Scene Management

  • create_scene - Create a new scene file with a specified root node type
  • add_node - Add a node to an existing scene with optional properties
  • load_sprite - Load a sprite texture into a Sprite2D node
  • save_scene - Save changes to a scene file
  • export_mesh_library - Export a scene as a MeshLibrary resource for GridMap

Debug & Output

  • get_debug_output - Get debug output and errors from a running project
  • connect_remote_debugger - Connect to Godot editor's remote debugger (ports 6006/6007)
  • get_remote_debug_output - Get output from the remote debugger connection
  • disconnect_remote_debugger - Disconnect from the remote debugger
  • capture_screenshot - Capture a screenshot from the running game viewport

UID Management (Godot 4.4+)

  • get_uid - Get the UID for a specific file
  • update_project_uids - Resave resources to update UID references

Development

Build

npm run build

Watch Mode

npm run watch

Testing with MCP Inspector

npm run inspector

This launches the MCP inspector for interactive testing of all tools.

Note

Screenshot capture is still experimental and may not work in all environments.

Troubleshooting

Godot Not Found

If the server can't find Godot, set the GODOT_PATH environment variable in your MCP configuration:

{
  "env": {
    "GODOT_PATH": "/full/path/to/godot"
  }
}

Scene File Not Created

If scenes aren't being created:

  1. Check directory permissions
  2. Verify the project path contains project.godot
  3. Enable debug mode to see detailed logs

Remote Debugger Connection Issues

  • Ensure Godot editor is running with remote debugging enabled
  • Default ports: 6007 (editor sync), 6006 (script debugger)
  • Check firewall settings aren't blocking the connection

Related Projects

Acknowledgements

Inspired by Coding Solo's godot-mcp. https://github.com/Coding-Solo/godot-mcp

Support

For issues and questions:

  • File an issue on GitHub

References

Configuration guides referenced from:

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选