Get the FREE Ultimate OpenClaw Setup Guide →

Nyamu

Minimal MCP server for Unity, designed to reliably check script compilation

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
claude mcp add --transport stdio polyblank66-nyamu node path/to/nyamu-server.js \
  --env NYAMU_PORT="Optional: port for MCP server (default if not specified)" \
  --env UNITY_PATH="Path to Unity editor executable"

How to use

Nyamu is a minimal MCP server for Unity designed to let coding agents verify Unity script compilation and interact with Unity tooling through a set of specialized commands. It exposes features organized under categories such as Asset Management, Script Compilation, Shader Compilation, Testing, Editor Status, Menu Item Execution, and Unity Editor Logs. Tools like assets_refresh, scripts_compile, shaders_compile_all, tests_run_all, editor_status, and editor_log_tail give you programmatic access to trigger Unity operations, fetch results, and monitor status. To use Nyamu, start the MCP server in your environment and then connect your coding agent (for example Claude Code, Gemini CLI, or another MCP-enabled agent) to the Nyamu server using the mcp.json configuration generated in your project. The provided commands can be invoked to refresh assets, compile scripts and shaders, run tests, inspect editor state, and read editor logs, enabling automated validation of Unity projects within AI-assisted workflows.

How to install

Prerequisites:

  • Unity 2021.3.x or later (Unity version used for testing).
  • Node.js installed on the machine running the intermediate server.
  • Access to a Unity project with Nyamu installed via Unity Package Manager.

Installation steps:

  1. Install Node.js on your machine if not already installed. Download from https://nodejs.org and follow the installer.

  2. In Unity, add Nyamu to your project via the Unity Package Manager using the Git URL: https://github.com/polyblank66/Nyamu.git?path=/Nyamu.UnityPackage This installs the Nyamu Unity package and generates a nyamu.bat file that launches the MCP server when running on Windows.

  3. Locate the Nyamu generated launch script (nyamu.bat) in your project’s .nyamu directory. This file is used to start the MCP server for this Nyamu integration.

  4. Configure the MCP client in your agent’s mcp.json to point to the Nyamu server. Example (adjust paths and ports as needed): { "mcpServers": { "Nyamu": { "command": "node", "args": ["path/to/nyamu-server.js"], "timeout": 30000 } } }

  5. Start the Nyamu MCP server using your chosen method (e.g., run nyamu.bat or start the node server if using a custom setup), then connect your agent with the provided mcp.json configuration.

  6. Optional: If your workflow requires, set environment variables such as UNITY_PATH to point to your Unity editor location and NYAMU_PORT to customize the listening port for the MCP server.

Additional notes

Tips and caveats:

  • The nyamu.bat file is auto-updated when Nyamu settings change in Unity; you typically only need to configure the MCP JSON once.
  • Ensure Unity and the Nyamu package versions are compatible with your agent tools and tests.
  • If you encounter issues with tool visibility (e.g., certain tools not appearing in the MCP interface), verify that Nyamu was properly installed in the project and that the nyamu.bat script is being launched by the MCP server.
  • Common env vars to consider: UNITY_PATH (path to Unity), NYAMU_PORT (custom port), and any Unity-specific overrides for asset or compilation behavior.
  • For large projects, consider increasing the MCP response timeout to accommodate longer compilation or test runs.

Related MCP Servers

Sponsor this space

Reach thousands of developers