niua-godot-mcp
NIUA Godot MCP
你的AI能在你的机器上构建真正的Godot游戏。
安装一次。聊天。Godot打开,场景出现,游戏运行。全本地。
60秒安装
选项A——粘贴到你的AI中(最简单)
复制到Claude Code、Cursor、Codex或任何有shell访问权限的代理中:
Install NIUA Godot MCP for me.
Follow: https://raw.githubusercontent.com/OhaoTech/niua-godot-mcp/main/docs/godot-mcp/INSTALL-BY-AGENT.md
Ask before writing any config. Then call get_godot_version.当它提示时重启AI客户端。完成。
选项B——自己动手
需要: Node 20+ · Godot 4.7 · Claude / Cursor / Codex / 等。
git clone https://github.com/OhaoTech/niua-godot-mcp.git
cd niua-godot-mcp
mkdir -p ~/Godot/NIUAProjectsClaude Code:
claude mcp add niua-godot -s user \
--env GODOT_MCP_ALLOWED_PROJECT_ROOTS="$HOME/Godot/NIUAProjects" \
-- node "$(pwd)/src/godot-mcp/cli.js"Codex / Claude Desktop / Cursor:
# preview
node src/godot-mcp/cli.js setup --client codex --project-root "$HOME/Godot/NIUAProjects"
# write (use --client claude or --client generic for others)
node src/godot-mcp/cli.js setup --client codex --project-root "$HOME/Godot/NIUAProjects" --write重启你的AI工具。
Related MCP server: Gear
第一个游戏
询问你的AI:
Create a Godot project at ~/Godot/NIUAProjects/first-game.
Build a 3D scene with a ground, a cube, a camera, and a light.
Save it, set it as main, then call run_playtest_evidence and tell me the evidence claims.你应该会看到Godot打开并出现一个真实的游戏窗口。代理会获得一个紧凑的验证包(运行+观察+截图协议),而不是手动构建的工具循环。
如果出问题
问题 | 修复 |
| 安装Godot 4.7,或者在MCP配置中设置 |
| 将项目放在 |
| 询问AI:'open the project with open_project' |
工具缺失 | 安装后重启AI客户端 |
Godot卡在对话框 | 在Godot中按Esc;要求AI在运行前保存场景 |
健康检查:
cd niua-godot-mcp && node src/godot-mcp/doctor.js更多帮助:故障排除
可选
# Claude Code
mkdir -p ~/.claude/skills && cp -r skills/niua-godot ~/.claude/skills/
# Codex / agents
mkdir -p ~/.agents/skills && cp -r skills/niua-godot ~/.agents/skills/AI打开项目一次后:
node examples/sdk-quickstart.mjs ~/Godot/NIUAProjects/first-gameimport { connect } from "niua-godot-mcp/sdk";
const godot = connect({ expectedProjectRoot: "/path/to/project" });
// no tokens to configure默认是core(约52个工具)——足以制作真实游戏。
full——所有稳定工具compact——13个路由器后的完整表面
node src/godot-mcp/cli.js setup --client codex --project-root "$HOME/Godot/NIUAProjects" --profile full --write实验性工具(多人游戏、导航、导出等)保持隐藏,除非你设置NIUA_MCP_EXPERIMENTAL=on。目录:tools.md
npm test
npm run godot:mcp:docs许可证
PolyForm Small Business 1.0.0 ——对个人和约100人以下/约100万美元收入的组织免费。更大的组织请联系:team@ohao.tech
This server cannot be deployed
Maintenance
Related MCP Connectors
An MCP server that gives your AI access to the source code and docs of all public github repos
A registry of AI agent tools — MCP servers, APIs, CLIs, SDKs — kept current by automated ingestion.
Nifty's MCP server — exposes tasks, projects, messages, and files as tools for AI agents.
Generate game-ready 3D models, textures, and audio from natural language, over MCP.
Related MCP Servers
- AlicenseAqualityDmaintenanceAn MCP server that gives AI assistants direct control over Godot 4 game development projects. It enables launching the editor, running projects, creating and editing scenes, writing GDScript, and inspecting assets through natural language commands.4415 npm4MIT
- AlicenseAqualityDmaintenanceAn MCP server that enables AI assistants to directly run, inspect, modify, and debug Godot game development projects through 110+ tools covering scenes, scripts, resources, runtime debugging, and asset management.3321 npm2MIT
- AlicenseNot gradedqualityCmaintenanceA security-first MCP server and Godot editor addon enabling AI agents to observe and control Godot games through bounded, permission-gated tools for debugging, input automation, and project editing.MIT
- AlicenseAqualityBmaintenanceAn MCP server that lets AI coding agents work on Godot 4 projects, including reading and editing scenes, writing and validating GDScript, running the game, and capturing screenshots.2550 npmMIT