Skip to content
Skillpedia
● Free and open sourceπŸ’»β˜οΈ Local / RemoteπŸ”“ No API keyProgramming

AI Game Developer (Unity MCP)

Lets your AI agent work inside the Unity Editor and in running games: create objects, edit scripts, run tests and debug.

4.6k stars on GitHubby Ivan MurzakLicense Apache-2.0Updated 18 days ago

How to install

This MCP has two ways to run: local or remote.

Pick one below. Local runs on your computer; remote runs in the cloud and needs nothing installed.

Paste in the terminal:

claude mcp add unity -- dnx com.IvanMurzak.GameDev.MCP.Server --yes

What to fill in

NameWhat it isRequired
MCP_PLUGIN_PORTClient -> Server <- Plugin connection port (default: 8080)No
MCP_PLUGIN_CLIENT_TIMEOUTPlugin -> Server connection timeout (ms) (default: 10000). Tool calls use MCP_PLUGIN_TOOL_TIMEOUT instead.No
MCP_PLUGIN_TOOL_TIMEOUTHow long one tool call may run in the plugin (ms). A tool call is sent once and never re-sent (default: 300000, or MCP_PLUGIN_CLIENT_TIMEOUT if larger)No
MCP_PLUGIN_CLIENT_TRANSPORTClient -> Server transport type: stdio or streamableHttp (default: stdio)No
MCP_AUTHAuthentication mode: none or oauth. Default depends on transport: stdio -> none (offline/local/CI), streamableHttp -> oauth when MCP_AUTH_ISSUER + MCP_PUBLIC_URL are set, otherwise none. oauth validates ES256 JWTs (via cached JWKS) issued by MCP_AUTH_ISSUER, audienced to MCP_PUBLIC_URL.No
MCP_AUTH_ISSUEROAuth authorization-server URL (e.g. https://ai-game.dev). Required when MCP_AUTH=oauth.No
MCP_PUBLIC_URLThis server's canonical public resource URL (its token audience, e.g. https://ai-game.dev/mcp). Required when MCP_AUTH=oauth; also seeds the Origin allow-list.No
MCP_BINDNetwork bind address: loopback (default), any (0.0.0.0), or a specific IP. Hosted deploys reachable by a reverse proxy set MCP_BIND=0.0.0.0.No
MCP_ALLOWED_ORIGINSComma/semicolon-separated additional allowed Origins for browser clients (in addition to loopback + the MCP_PUBLIC_URL origin). Avoids a blanket wildcard on credentialed paths.No

Ready! Now test it

Restart the app and paste one of these requests in the chat:

Create 3 cubes in a circle with radius 2.
Write a script for a simple player controller and run the tests.

What it is

Unity MCP connects AI agents to the Unity Editor, and it can also work inside a compiled game. Most Editor work goes through RQL, a small query language that reads and changes scenes, objects, assets and settings. Agents can write and run C# code, take screenshots, run tests and fix problems. You can add your own tools with a single line of C#.

What it can do

  • rql-query: read Editor data such as scenes, objects and console logs
  • rql-mutate: change Editor data or call Editor operations
  • rql-schema: describe what RQL can use
  • screenshot-isolated: render a GameObject from a chosen angle
  • script-execute: compile and run C# with Roslyn
  • tests-run: run EditMode and PlayMode tests
  • unity-tool-list: list tools and which ones the agent sees

When to use

  • β€ΊWhen you want to build scene content by describing it, such as cubes in a circle.
  • β€ΊWhen you want an agent to write game code and run the tests.
  • β€ΊWhen you want an agent to debug a problem in your project.

What you need

A Unity project with the plugin installed (the .unitypackage installer, openupm add com.ivanmurzak.unity.mcp, or the unity-mcp-cli install-plugin command, which needs Node.js), and an AI agent such as Claude Code, Cursor or Copilot.

Skills that pair well

⭐ Skillpedia MCP Β· freeYour agent finds the right skill on its ownInstall our MCP and your agent searches 15,000+ skills whenever it needs one.Install for free β†’

Frequently asked questions

Is it free and open source?

The readme says it works with the listed agents for free, and it shows a license file.

Which agents does it work with?

Claude, Codex, Cursor, GitHub Copilot, Gemini, Antigravity, OpenCode, Cline, Kilo Code and others, with no vendor lock-in.

Can it work inside a built game?

Yes. The readme says it works inside your compiled game for real-time AI debugging and player-AI interaction.

Does it run locally?

It works locally over stdio and remotely over http, set by configuration. A Docker image of the server is also published.

Why do I see only a few tools?

Only seven are shown to the agent by default. Others are hidden but still run by name. Show them with tool-set-visibility.

Can I add my own tools?

Yes. Any C# method can be turned into a tool with a single line, and extensions add Animation, Cinemachine, Terrain and more.

If it does not work

  • β€ΊIn Unity, open Window/AI Game Dev and click Auto-generate skills or Configure MCP for your agent.
  • β€ΊWith the CLI route, run unity-mcp-cli login to sign in to ai-game.dev, then open the project with unity-mcp-cli open.
  • β€ΊIf a tool seems missing, it may be hidden by default. Check unity-tool-list and show it with tool-set-visibility.

5 new skills a week. 1 minute to read.