mcp-unity: Skill for Claude Code

.claude/skills/mcp-unity-dev/SKILL.md

mcp-unity-dev is a skill for Claude Code from pakkio/mcp-unity. It costs 123 tokens per session (2,242 once invoked), scanned A, original, MIT.

Development instructions for mcp-unity, the package that exposes Unity Editor capabilities to MCP tools.

In plain words
What is it for?
Use them when editing the package, adding Unity files, rebuilding the server, updating the Unity package, or verifying changes.
Why use it?
They document important setup details, Unity package update steps, build checks, and pitfalls when changing C# or TypeScript code.

Skill for Claude Code

Written for Claude Code: installed under .claude/.

This is pakkio/mcp-unity's own configuration. It tells Claude Code how to work on mcp-unity itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything mcp-unity configures →

Reuse

Borrowing it

Nothing to install: this file belongs to pakkio/mcp-unity. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/pakkio/mcp-unity/main/.claude/skills/mcp-unity-dev/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/pakkio/mcp-unity

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for mcp-unity-dev

README.md
[![agentmods](https://agentmods.dev/badge/skills/pakkio/mcp-unity/mcp-unity-dev/github.svg)](https://agentmods.dev/skills/pakkio/mcp-unity/mcp-unity-dev)
Your own site
<a href="https://agentmods.dev/skills/pakkio/mcp-unity/mcp-unity-dev"><img src="https://agentmods.dev/badge/skills/pakkio/mcp-unity/mcp-unity-dev/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for mcp-unity-dev

Your own site · 80×15
<a href="https://agentmods.dev/skills/pakkio/mcp-unity/mcp-unity-dev"><img src="https://agentmods.dev/badge/skills/pakkio/mcp-unity/mcp-unity-dev.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 123 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,242 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00123 $0.02242
Opus 5.5 $0.00049 $0.00897
Sonnet 5.5 $0.00025 $0.00448
Haiku 4.5 $0.00012 $0.00224

Measured 2mo ago against content hash 48a304425733, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

mcp-unity-dev scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/skills/mcp-unity-dev/SKILL.md · 52 lines

How it starts

The opening of the file, as written. The whole thing — 52 lines — stays where its author put it; the contents beside it link to each section on GitHub.

mcp-unity development notes

Hard-won knowledge from actually using and extending mcp-unity in this repo. Read the section relevant to your task before you start, not after you hit the bug.

If you're modifying the mcp-unity package itself

The Unity project that actually runs this code (My project (1)) pulls it as a git package, not a local reference — editing files in this repo does nothing to the running Unity Editor until you:

  1. Edit the C# (Editor/Tools/*.cs, McpUnityServer.cs) and/or TypeScript (Server~/src/tools/*.ts, index.ts)
  2. New .cs files need a .meta file — Unity treats git packages as immutable and silently drops any asset without one (no error, the type just doesn't exist, giving a confusing CS0246 in an unrelated file). Generate a GUID (powershell -Command "[guid]::NewGuid().ToString('N')") and write the meta in the same format as a sibling file.
  3. cd Server~ && npm run build to catch TypeScript errors
  4. Commit (no AI co-author line — this user's preference), push to origin/main
  5. In Unity: Package Manager → In Project → MCP Unity → Update (or remove/re-add if no Update button). This triggers a domain reload.
  6. Verify via get_console_logs — check the PackageCache folder hash in any log line matches your new commit SHA, and confirm no compile errors before using the new tool.

Tool registration is two-sided and easy to half-do: a new tool needs a Unity McpToolBase subclass registered in McpUnityServer.cs RegisterTools(), and a Node registerXTool() in Server~/src/tools/*.ts registered in index.ts. Forgetting either side gives a confusing "tool not found" or silently does nothing.

Tool gotchas (don't rediscover these empirically)

  • reparent_gameobject does not reorder the Hierarchy. It changes parent only; Unity's SetParent is a no-op for sibling index when the parent is unchanged, and even a genuine temp-parent bounce doesn't reliably reorder. Use set_sibling_index instead (absolute siblingIndex, or insertAfterInstanceId/insertBeforeInstanceId relative to a sibling).
  • duplicate_gameobject on a nested child under a scaled/rotated parent used to corrupt the clone's transform. Fixed by instantiating with the parent specified directly (Instantiate(original, parent)) instead of parentless-then-reparent. If you ever see a duplicate land at a wildly wrong position/rotation/scale, this is the failure mode to suspect.
  • Component fields that reference other scene objects (a Transform, Rigidbody, or another Component) go through update_component's componentData using {"instanceId": N} or {"objectPath": "Parent/Child"} — not {"path": ...}/{"guid": ...}, which are asset-only (AssetDatabase). If the target field type doesn't match the resolved object directly (e.g. field is Rigidbody but you passed the GameObject's ID), it falls back to GetComponent automatically. List<T>/array fields accept a JSON array of the same per-element shapes.
  • Collider-derived components (including WheelCollider) are read via SerializedObject, not reflection. They used to be fully skipped ("_skipped": "Detailed property serialization skipped for safety") because some of their reflected C# properties are native-backed getters that can crash the Editor. get_gameobject/get_gameobject resource now dump these via the same SerializedObject/SerializedProperty API update_component already trusts for writes, so radius, isTrigger, suspensionSpring, etc. read back correctly. Native-plugin components (Pathfinding/FMOD namespaces) are still fully skipped — that skip is unrelated and still necessary.
  • set_play_mode_status action:"play"/"stop" used to frequently return "Connection failed" or time out. Root cause: entering/exiting Play mode synchronously fires ExitingEditMode, which unconditionally closes the WebSocket (StopServer) — this could race the in-flight response, and separately, the Node bridge used to reject all pending requests on any transient WebSocket error event (not just a terminal disconnect), which fired on the same reset. Both are fixed: Unity defers the actual mode transition to the next editor tick (via EditorApplication.delayCall) so the response is queued to send first, and Node no longer rejects pending requests on a bare connection error — only on a genuinely terminal disconnect. The action should now resolve normally without a manual sleep-and-poll workaround.
  • Unity discards all runtime changes to existing scene objects when you exit Play mode (auto-revert to the edit-time saved state). If you need to inspect what happened during a Play session, query while still in Play mode — don't stop first.
  • GameObject lookup by instanceId/objectPath now goes through one shared resolver (Editor/Utils/GameObjectResolver.cs) used by every tool. It searches all loaded scenes and includes inactive objects, and a bare name that matches more than one object returns an ambiguous_reference_error listing every candidate instead of silently picking one. Previously, whether an inactive object or an object in a non-active loaded scene could be found at all depended on which specific tool you called (four independent, disagreeing implementations existed) — that's no longer the case.
  • Prefer batch_execute for any run of >2-3 related tool calls — it's dramatically faster than sequential calls and each op gets its own success/failure in the summary.

Read the full file on GitHub · 52 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2mo ago First seen · 52 lines · 123 tokens per session scan A 48a304425733

Subscribe to this mod's changes

mcp-unity-dev is a skill published in the GitHub repository pakkio/mcp-unity (0 stars, last pushed 2mo ago), licensed MIT. It adds 123 tokens to every session and 2,242 once invoked, about $0.0005 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

mcp-unity-dev compared with skills from other repositories

mcp-unity-dev next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
mcp-unity-devpakkio/mcp-unitySkill02mo agoMITA123Claude Code
playtest-reportDonchitos/Claude-Code-Game-StudiosSkill36k19d agoMITA20Claude Code
godot-signals-groupsgamedev-skills/awesome-gamedev-agent-skillsSkill6.9k10d agoApache-2.0A95Claude Code
scenario-unreal-gameplayscenario-labs/skillsSkill3.2kyesterdayMITA121Claude Code
motionOpenDCAI/GameFactory-3ASkill1.0k8d agoApache-2.0A0Claude Code, Codex
unity-addressablesBesty0728/Unity-SkillsSkill1.9kyesterdayMITA25Claude Code, Codex
unity-manual-componentBesty0728/Unity-SkillsSkill1.9kyesterdayMITA36Claude Code, Codex