Introduction¶
When using agents in DSH to assist Unity development, the common practice is to connect to the Unity-side MCP server (AI Game Developer / com.ivanmurzak.unity.mcp). If the official MCP client remains connected, the JSON Schema of Unity tools will occupy context long-term. If you manually modify @deepseek-ai/dsh-mcp-client in the npx cache, DSH upgrades may wipe out your patches. The following introduces the community plugin dsh-unity-mcp-bridge (maintainer xiake-1), which connects Unity MCP to DSH in a “dormant by default, activate on demand” manner, and comes with installation check skills and command catalogs. It belongs to the “Workflow” category plugin on SkillHub.
What is this¶
dsh-unity-mcp-bridge is a standalone DSH npm plugin package (current version 0.3.3, MIT license) that bridges between DSH and Unity MCP. Unity capabilities do not activate on their own: they will only connect and register mcp__unity__* tools after the user executes /unity-mcp-tools. Sessions that don’t touch Unity will only have 2 additional hook tools (documented as ~224 tokens).
Plugin directory page: SkillHub — xiake-1/dsh-unity-mcp-bridge
Source code: github.com/xiake-1/dsh-unity-mcp-bridge
Core Features¶
Compared to @deepseek-ai/dsh-mcp-client distributed with DSH, this plugin emphasizes three incremental capabilities in the README, and retains the resyncAfterTools behavior that makes the on-demand workflow feasible:
-
Vendored implementation
The bridging logic is in this package’slib/index.js, without relying on manual modifications to the npx cache; DSH upgrades will not silently overwrite your modifications. The implementation is derived from@deepseek-ai/dsh-mcp-clientv0.1.5-rc.2, and the changes are documented in the file header and LICENSE. -
Bundled command catalog skill
skills/SKILL.mdserves as the index, andskills/reference/*.mdlists Unity commands by category (Chinese documentation states a total of 73 commands). After activation, it is registered as a runtime skill; the model first reads the index, then reads individual category files when needed, avoiding flooding the context at once. -
Wrap-up helper tool
unity_tools_restore
Disables Unity tools except for tool management ones, and can disconnect, reverting the tool set to the minimal resident set. -
resyncAfterTools
After the configured tools (typicallytool-set-enabled-state) return from a call, the bridge re-fetchestools/liston its own and replaces the registry, instead of waiting for the server’snotifications/tools/list_changed(DSH long sessions may not receive this notification).
Additionally, it provides two companion slash skills that are visible to the model by default (can be disabled via registerHelperSkills: false):
| Skill | Purpose |
|---|---|
/unity-mcp-install |
Checks and installs unity-mcp-cli; locates the Unity project in the workspace via ProjectSettings/ProjectVersion.txt; executes unity-mcp-cli install-plugin <project> --with-server as needed; CLI / plugin / Server versions need to be in lockstep (documentation example: CLI 1.2.0 ↔ com.ivanmurzak.unity.mcp@1.2.0 ↔ server 9.2.11). |
/unity-mcp-check |
Aligns the ports on both Unity and DSH sides to 20000; sets the AI agent to Kilo Code; initializes the tool set to only enable tool-set-enabled-state; probes connectivity and verifies the bridge with unity_mcp_activate. |
Feature descriptions and the token/latency comparison between “tool calls vs direct file reading” can be found in FEATURES-AND-COMPARISON.md (in Chinese) in the repository.
Installation and Activation¶
The DSH peer dependency declares a lower bound of >=0.1.5-rc.2 (not pinned); the README states host compatibility has been verified on 0.1.5-rc.2, 0.1.7-rc.2, and 0.2.0-rc.2.
<profile> refers to the DSH profile running the MCP bridge: web corresponds to dsh web, desktop corresponds to the DeepSeek Harness desktop app.
- Install the plugin (commands from the official README, choose one):
dsh plugin --profile <profile> add git+https://github.com/xiake-1/dsh-unity-mcp-bridge.git
Or from a local checkout directory:
dsh plugin --profile <profile> add file:<path-to-this-checkout>
- Insert an entry in
%DSH_HOME%/profiles/<profile>/cordis.patch.ymlso the profile points to this package instead of the stock client (Chinese documentation suggests uniformly using the/mcpendpoint on port 20000):
- insert:
- id: unity-mcp
name: 'dsh-unity-mcp-bridge'
config:
serverName: unity
transport: streamable-http
url: http://localhost:20000/mcp
resyncAfterTools:
- tool-set-enabled-state
resyncIntervalMs: 0
- Restart
dsh webor the desktop application. The command catalog skill andunity_tools_restorewill load with the plugin; companion installation/check skills are available whenregisterHelperSkills: true(default).
Note: Do not use the stock @deepseek-ai/dsh-mcp-client simultaneously with this plugin to connect to the same serverName, otherwise both modules will fight over the same set of public tool names.
Uninstall example:
dsh plugin --profile <profile> remove dsh-unity-mcp-bridge
And delete the corresponding unity-mcp line from cordis.patch.yml.
Typical Usage¶
For the complete Unity-side environment, refer to the ai-game.dev Unity documentation. On the DSH side, it’s recommended to follow the “on-demand workflow”:
- For the first time or when the environment is uncertain, first run
/unity-mcp-install, then run/unity-mcp-check, to align ports, Kilo Code, and the minimal tool set. - When the Agent needs to operate Unity, the user executes
/unity-mcp-tools(this skill is not visible to the model by default, and is the only entry point for activation). - Call
unity_mcp_activateto connect to Unity and register themcp__unity__*tools. - Refer to the bundled command catalog, and use
mcp__unity__tool-set-enabled-stateto enable the commands needed for the current task (the full Schema of each enabled command will enter every subsequent model request, so only enable what’s necessary). - In the next step, call the specific
mcp__unity__<command_name>. - At the end of the task, call
unity_tools_restore(optionallykeepto retain individual commands), returning to dormant state.
Common configuration options (full list in README Configuration):
| Field | Default | Description |
|---|---|---|
autoStart |
false |
Stay dormant; set to true to connect on startup |
resyncAfterTools |
[] |
On-demand workflow should include tool-set-enabled-state |
toolCallTimeoutMs |
60000 |
Single tool call timeout |
registerCatalogSkill |
true |
Whether to register the command catalog skill |
registerHelperSkills |
true |
Whether to register /unity-mcp-install and /unity-mcp-check |
Use Cases and Notes¶
Who it’s for: Developers who are already using or planning to use DSH + Unity MCP (com.ivanmurzak.unity.mcp) for editor automation, want to control context size, and are willing to complete installation and port alignment via slash skills.
Permissions and security: The plugin runs with the current DSH process. Before installation, please read the repository source code and the MIT license, and confirm that the URL, transport, and network exposure scope in cordis.patch.yml comply with your environment.
Ecosystem notes: DeepSeek Harness adopts an “everything is a plugin” extension approach; SkillHub is a community plugin directory site, with no official affiliation with DeepSeek / High-Flyer. The star rating of this plugin on the directory page is 0, which does not mean the functionality is unusable. Before use, refer to the GitHub README and version 0.3.3.
Conclusion¶
dsh-unity-mcp-bridge connects Unity MCP to DSH in a dormant state by default, expands tools on demand through /unity-mcp-tools, collapses context with resyncAfterTools and unity_tools_restore, and uses a vendored implementation to avoid losing patches during upgrades. When needed, it can be installed from SkillHub or GitHub, then align the Unity and DSH sides using /unity-mcp-install and /unity-mcp-check.
- Directory page: https://www.skillhub.cn/plugins/xiake-1/dsh-unity-mcp-bridge
- GitHub: https://github.com/xiake-1/dsh-unity-mcp-bridge