unity-mcp

1.1.0 • Public • Published

Unity MCP Server

MCP server to connect Claude with Unity projects. Built using the Model Context Protocol SDK.

Features

  • List all Unity projects
  • Get detailed project information
  • Access project structure and files

Configuration

Run this project locally

Run this project locally by cloning this repo

git clone https://github.com/your-username/unity-mcp.git
cd unity-mcp
bun install

Add this tool as an MCP server in Claude.

On MacOS: ~/Library/Application\ Support/Claude/claude_desktop_config.json
On Windows: %APPDATA%/Claude/claude_desktop_config.json

{
  "mcpServers": {
    "unity": {
      "command": "bun",
      "args": ["run", "C:\\Users\\Artga\\Code\\unity-mcp\\src\\index.ts"]
    }
  }
}

Requirements

  • Unity with projects configured
  • Bun runtime

Troubleshooting

Please open an issue if you can't get this MCP working. Here are some tips:

  1. Make sure Unity is installed and you have some projects configured
  2. Check that the unity-mcp server can access the projects-v1.json file
  3. Ensure you have proper permissions for the Unity project directories

This MCP will emit logs to stderr as specified in the MCP spec. On Mac the Claude Desktop app should emit these logs to ~/Library/Logs/Claude. On other platforms you can find logs here.

Development

Setup

# Install dependencies
bun install

# Run the project
bun run src/index.ts

# Type check
bun run typecheck

# Format code
bun run format

Debugging

Since MCP servers run over stdio, debugging can be challenging. For the best debugging experience, we strongly recommend using the MCP Inspector.

You can launch the MCP Inspector with this command:

bun run inspector

Upon launching, the Inspector will display a URL that you can access in your browser to begin debugging.

License

MIT License - see LICENSE file for details.

Package Sidebar

Install

npm i unity-mcp

Weekly Downloads

15

Version

1.1.0

License

MIT

Unpacked Size

10.7 kB

Total Files

8

Last publish

Collaborators

  • artmann