Unity MCP Template
A template project demonstrating interaction between a TypeScript-based MCP server and a Unity client.
Unity MCP Template
This is a simple example project demonstrating interaction between a TypeScript-based MCP server and Unity. You can build and configure your own tools to expand and develop further.
Create more tools your own!
Quick Start
unity-mcp-sample is a Unity example project. To minimize version-related issues and ensure compatibility with legacy versions, it does not use packages like NewtonsoftJSON. Additionally, the EditorWindow is implemented using IMGUI. The MCP can be managed through the UnityMCP-ShowWindow at the top.
Build MCP Server
within the unity-mcp-server
npm install
npm run build
Add MCP in Claude Desktop
Open Claude Desktop Settings, and Developer-Edit Config
{
"mcpServers": {
"unity-mcp": {
"command": "node",
"args":["F:/unity-mcp-template/unity-mcp-server/dist/index.js"]
}
}
}
Create your own tools!
Both input data structure should be same.
Unity
Refer to CreateObjectTools and create the tool you want.
Typescript
Refer to createObject and create the tool you want.
TODO List
- Enable Unity to send result messages to MCP
- Discussion here
Change TCP structure (currently implemented with client-server reversed due to a bug in the TypeScript SDK)Unity (Current : TCP Server, TODO : TCP Client)MCP (Current : TCP Client, TODO : TCP Server)
Related Servers
Image Tools MCP
Retrieve image dimensions and compress images from URLs or local files using Tinify and Figma APIs.
Quick Chart MCP Server
A server for creating charts and visualizations using the Quick Chart API.
Cursor Chat History MCP
Provides local access to Cursor chat history for AI analysis and insights, with no external services or API keys required.
Model Context Protocol servers
A collection of reference implementations for the Model Context Protocol (MCP), demonstrating secure and controlled access to tools and data sources for Large Language Models (LLMs).
MCP Stdio Server
An MCP server using stdio transport, offering file system access, a calculator, and a code review tool. Requires Node.js.
ITerm MCP Server
An MCP server for iTerm2, enabling AI assistants to interact with the terminal.
Jinni
A tool to provide Large Language Models with project context by intelligently filtering and concatenating relevant files.
Search Tools MCP Server
An MCP server that enhances code analysis with advanced search and dependency mapping capabilities.
Grafana Loki
A server for querying Loki logs from Grafana.
mcpcodeserver
Instead of direct calling MCP tools, mcpcode server transforms MCP tool calls into TypeScript programs, enabling smarter, lower-latency orchestration by LLMs.