GDMCP
by theLegend35
README.md
**Godot + MCP + in-editor AI** by **Dhruv Vinesh**
Let Cursor, Claude, and other AI agents control your Godot 4 editor — **or chat from inside Godot** with your own API keys (Claude, OpenAI, Gemini, OpenRouter, …).
```
Option A: Cursor / Claude Desktop --stdio MCP--> Node server --WebSocket--> Godot
Option B: Type in GDMCP Chat tab --HTTPS------> Claude / OpenAI / Gemini --> same tools
```
## Requirements
- Godot **4.2+** (GDScript)
- Node.js **20+** (only if using Cursor/Claude MCP bridge)
- Optional: API keys from Anthropic, OpenAI, Google, or an OpenAI-compatible host
## Install
### 1. Enable the Godot addon
Copy `addons/gdmcp` into your game (or open this repo in Godot).
**Project → Project Settings → Plugins → GDMCP → Enable**
### 2. Chat from Godot (API keys)
1. Open the **GDMCP** bottom panel → **Settings**
2. Pick a provider (Claude / OpenAI / Gemini / OpenAI-compatible)
3. Paste your API key → **Save settings**
4. Go to **Chat**, ask it to inspect or edit the project
Keys are stored in **Editor Settings** (your machine), not in the game repo.
### 3. Optional: Cursor MCP bridge
```bash
cd GDMCP
npm run prepare:mcp
```
Point Cursor MCP at `mcp-server/dist/index.js` (see `examples/cursor-mcp.json`).
## Providers
| Provider | Notes |
|---|---|
| Anthropic (Claude) | Messages API + tools |
| OpenAI | Chat Completions + tools |
| Google Gemini | generateContent + function calling |
| OpenAI-compatible | OpenRouter, Groq, Ollama, etc. Set base URL |
## Tools
Same tool surface for Chat and MCP: scene tree, nodes, files, play/stop, and more. Scene mutations are undoable (`Ctrl+Z`).
## Config
**Editor Settings (AI)** — configured in the GDMCP Settings tab
**Project settings (bridge)** — `gdmcp/network/port` (default `6505`), `gdmcp/network/autostart`
The WebSocket MCP bridge binds to **localhost only**.
## Safety
GDMCP can modify scenes and files. API keys never leave your editor except to the provider you chose. Only use keys you control.
## Author
**Dhruv Vinesh**
## License
MIT — see [LICENSE](LICENSE)
This server cannot be deployed
Maintenance
ActivitySlowing
ResponsivenessNo issues