Skip to content

Getting Started

Ivan Murzak edited this page Dec 29, 2025 · 5 revisions

Getting Started

Now that you have installed the plugin, let's connect your AI agent to Unity.

1. Verify Unity Plugin is Running

Open your Unity Project. You should see a new menu item: Window -> AI Game Developer (Unity-MCP).

Open this window. It acts as the dashboard for the MCP link.

  • Status: Should show "Listening" or "Connected".
  • Port: Default is 8080.

2. Connect Your AI Client

Claude Desktop

  1. Ensure Unity is open.
  2. Open Claude Desktop.
  3. Look for the 🔌 (plug) icon or MCP settings.
  4. If configured correctly (see Installation), Claude should see Unity-MCP tools.

Cursor / Windsurf

  1. Open the IDE settings.
  2. Navigate to "MCP" or "Models".
  3. Ensure the Unity-MCP server is added.
  4. If added, the indicator should be green.

3. Your First Command

In your AI chat (Claude/Cursor), type:

"Create a red cube at position (0, 0, 0) and name it 'MyFirstCube'."

What happens?

  1. The AI analyzes your request.
  2. It calls the GameObject.Create and Assets.Material.Create (or modifying material) tools exposed by Unity.
  3. You should see a red cube appear instantly in your Unity Scene!

4. Try These Prompts

Once connected, try these more complex requests:

Level Design:

"Create a 5x5 grid of cylinders with random heights to simulate a city skyline."

Physics:

"Add Rigidbody components to all cylinders and create a plane below them."

Debugging:

"Read the console logs and tell me if there are any errors."

Scripting:

"Create a script 'Rotator.cs' that rotates an object and attach it to the 'MyFirstCube'."


Troubleshooting

  • AI says "I don't have tools": Restart the AI Client after Unity is open.
  • Connection Refused: Check if the Port (8080) is used by another app. Change it in the AI Game Developer window.
  • "Server Disconnected": The Unity Plugin must be in Play Mode or Edit Mode (not compiling).

Clone this wiki locally