- Explore MCP Servers
- McpToolForUnity
Mcptoolforunity
What is Mcptoolforunity
McpToolForUnity is a Unity package that allows developers to create callable static methods from editors like Cursor and windsurf by using the McpTool attribute.
Use cases
Use cases include creating utility functions that can be called directly from the Unity editor, simplifying repetitive tasks, and improving the efficiency of game development processes.
How to use
To use McpToolForUnity, install the package from the provided Git URL, configure the Cursor settings, and add the McpTool attribute to your static methods. After making changes, re-enable the MCP server to refresh the tool list.
Key features
Key features include the ability to easily expose static methods to editors, customizable parameter descriptions via attributes, and straightforward installation and configuration.
Where to use
McpToolForUnity is primarily used in game development within the Unity engine, particularly for enhancing editor functionality and streamlining development workflows.
Clients Supporting MCP
The following are the main client software that supports the Model Context Protocol. Click the link to visit the official website for more information.
Overview
What is Mcptoolforunity
McpToolForUnity is a Unity package that allows developers to create callable static methods from editors like Cursor and windsurf by using the McpTool attribute.
Use cases
Use cases include creating utility functions that can be called directly from the Unity editor, simplifying repetitive tasks, and improving the efficiency of game development processes.
How to use
To use McpToolForUnity, install the package from the provided Git URL, configure the Cursor settings, and add the McpTool attribute to your static methods. After making changes, re-enable the MCP server to refresh the tool list.
Key features
Key features include the ability to easily expose static methods to editors, customizable parameter descriptions via attributes, and straightforward installation and configuration.
Where to use
McpToolForUnity is primarily used in game development within the Unity engine, particularly for enhancing editor functionality and streamlining development workflows.
Clients Supporting MCP
The following are the main client software that supports the Model Context Protocol. Click the link to visit the official website for more information.
Content
Introduction to McpToolForUnity
Features
Simply add the [McpTool] attribute to static methods to make them callable from editors like Cursor/windsurf.
[McpTool("Add two numbers")]
static int Add([McpTool("The first one")] int a, [McpTool("The second one")] int b)
{
// Attribute for parameters are not necessary
return a + b;
}
Installation
1. Unity Package
Add the package from the git URL: https://github.com/EEEEEEEEthan/McpToolForUnity.git
This will create a McpCommand directory at the same level as Assets.
2. Open Unity Preferences
restart Unity if you have modified port
3. Configure Cursor
paste command to Cursor settings
4. Attribute Everything
Add the [McpTool] attribute to the static methods you want to call.
[McpTool("Add two numbers")]
static int Add([McpTool("The first one")] int a, [McpTool("The second one")] int b)
{
// Attribute for parameters are not necessary
return a + b;
}
you need re-enable cursor MCP server to refresh tool list
5. Test Agent
Dev Tools Supporting MCP
The following are the main code editors that support the Model Context Protocol. Click the link to visit the official website for more information.










