๐ŸŽฎ UnitySkills

May 31, 2026 ยท View on GitHub

Unity-Skills

Unity Skills License ไธญๆ–‡

REST API-based AI-driven Unity Editor Automation Engine
Let AI control Unity scenes directly through Skills

๐ŸŽ‰ We are now indexed by DeepWiki!
Got questions? Check out the AI-generated docs โ†’ Ask DeepWiki

The current official maintenance baseline is Unity 2022.3+. Some Unity 2021 compatibility logic may still remain in the codebase, but future feature work, regression testing, and adaptation will focus on 2022.3+ / Unity 6.

๐Ÿค Acknowledgments

This project is a deep refactoring and feature extension based on the excellent concept of unity-mcp.


๐Ÿš€ Core Features

  • ๐Ÿ› ๏ธ 750 REST Skills Comprehensive Toolkit: Includes 51 functional source modules plus 19 advisory design modules, with Batch operations for multi-object control.
  • โšก Revolutionary Efficiency Boost (v2.0.0+): Schema caching + exponential backoff polling + BATCH-FIRST guidance โ†’ Token consumption โ†“ 96%, simple tasks 4-6 calls โ†’ 1 call (โ†“ 75-83%).
  • ๐Ÿ” Three-Tier Permission Modes (v1.9.0+): Approval / Auto / Bypass with dual approval channels (Dialog / Panel), aligned with Claude Code permission modes; zero-impact upgrade for existing users.
  • ๐Ÿค– 4 Major IDEs Native Support: Claude Code / Antigravity / Codex / Cursor โ€” one-click install and use.
  • ๐Ÿ›ก๏ธ Transactional Atomicity: Failed operations auto-rollback, leaving scenes clean and safe.
  • ๐ŸŒ Multi-Instance Simultaneous Control: Automatic port discovery and global registry for controlling multiple Unity projects at once.
  • ๐Ÿ”— Ultra-Stable Long Connections: Configurable request timeout (default 15 minutes), automatic recovery after Domain Reload, with retry hints during script compilation/asset updates.
  • ๐Ÿ›ก๏ธ Anti-Hallucination Guardrails: Each Skill module includes DO NOT lists and routing rules to prevent calls to nonexistent commands or parameter errors.

๐Ÿ” Operating Modes (v1.9.0+)

UnitySkills ships with a true server-side permission system aligned with Claude Code permission modes. All mode switching happens in the Unity panel (Window > UnitySkills > Server) โ€” chat trigger words are no longer supported.

ModeDefaultBehaviorUse Case
Approvalโ€”AI must request โ†’ user approves โ†’ execute (returns MODE_RESTRICTED + grant token)Manual control, sensitive projects
AutoNew installsAI runs FullAuto skills directly; server only blocks auto-detected high-risk ops (NeverInSemi)Day-to-day development
BypassExisting installs (upgrade)All skills run unrestricted; only ConfirmationToken gate remains for high-risk opsAutomation, CI, fast iteration

Two approval channels under Approval mode:

  • Dialog (default) โ€” AI explains intent + grant token, user agrees in chat, AI replays the token via POST /permission/grant
  • Panel (opt-in) โ€” grant token only takes effect after user clicks [Approve] in the Unity panel; AI-issued grants without panel approval return GRANT_PENDING_APPROVAL

Zero-impact upgrade for existing users: the plugin detects legacy UnitySkills_* EditorPrefs keys and keeps Bypass as the default, preserving the previous Full-Auto behavior with no action required. New installations default to Auto โ€” FullAuto skills run directly, only NeverInSemi (Delete / MayEnterPlayMode / MayTriggerReload / high-risk) operations are blocked. Switch to Approval in the Server tab if you need per-skill manual gating.

โŒ Chat trigger words (e.g. "full auto" / "semi-auto") are no longer recognized. Switch modes in Window > UnitySkills > Server.

๐Ÿ“œ Audit log: Library/UnitySkillsAudit.jsonl (per-project, jsonl, auto-rolls at 1MB, keeps 3 files) records every grant / revoke / restricted hit / call. Open Window > UnitySkills > Audit Log to browse, filter, delete individual entries (โœ•), or wipe everything (๐Ÿ—‘ Clear All) โ€” deletions themselves are appended as audit_deleted / audit_cleared events so the log stays auditable.

๐Ÿ—‘ The Skill Installer card shows a per-scope uninstall button that auto-adapts: disabled when nothing's installed, a single button labeled with its scope when only one is installed, and a dropdown (Uninstall โ–พ) listing Project / Global when both are installed.

19 advisory design modules (architecture, performance, design patterns, testability, package-specific source rules, etc.) are available in all modes and loaded on demand.


๐Ÿ—๏ธ Quick Install Supported IDE/Terminals

This project has been deeply optimized for the following environments to ensure a continuous and stable development experience (tools not listed below are not necessarily unsupported โ€” they just lack a quick installer; use Custom Installation to the corresponding directory):

AI TerminalSupport StatusSpecial Features
Antigravityโœ… SupportedOpen Agent Skills standard via .agents/skills/ (workspace) and ~/.gemini/antigravity/skills/ (global).
Claude Codeโœ… SupportedIntelligent Skill intent recognition, supports complex multi-step automation.
Codexโœ… SupportedSupports $skill explicit invocation and implicit intent recognition. Shares .agents/skills/ with Antigravity in workspace mode.
Cursorโœ… SupportedAuto-discovers .cursor/skills/ and .agents/skills/; supports /skill-name explicit invocation; visible in Settings โ†’ Rules.

๐Ÿ Quick Start

Overview: Install Unity Plugin โ†’ Start UnitySkills Server โ†’ AI Uses Skills

ไธ€้”ฎๅฎ‰่ฃ…ๆผ”็คบ

1. Install Unity Plugin

Add via Unity Package Manager using Git URL:

Stable Version (main):

https://github.com/Besty0728/Unity-Skills.git?path=/SkillsForUnity

Beta Version (beta):

https://github.com/Besty0728/Unity-Skills.git?path=/SkillsForUnity#beta

Specific Version (e.g., v1.6.0):

https://github.com/Besty0728/Unity-Skills.git?path=/SkillsForUnity#v1.6.0

๐Ÿ“ฆ All version packages are available on the Releases page

2. Start Server

In Unity, click menu: Window > UnitySkills > Start Server

โณ script_*, debug_force_recompile, debug_set_defines, some asset reimports, and package changes may trigger compilation or Domain Reload. Temporary REST unavailability during that window is expected; wait a moment and retry.

3. One-Click AI Skills Configuration

  1. Open Window > UnitySkills > Skill Installer.
  2. Select the corresponding terminal icon (Claude / Antigravity / Codex / Cursor).
  3. Click "Install" to complete the environment configuration without manual code copying.

The installer copies the unity-skills~/ template directory from the package to the target location.

Installer output files (generated in target directory):

  • SKILL.md
  • skills/
  • references/
  • scripts/unity_skills.py
  • scripts/agent_config.json (contains Agent identifier)

Codex Note: Antigravity and Codex share .agents/skills/ in workspace mode โ€” installing once for either makes the skill available to both. Codex auto-discovers skills in .agents/skills/; no AGENTS.md declaration needed.

๐Ÿ“˜ For complete installation and usage instructions, see: Setup Guide | ๅฎ‰่ฃ…ๆŒ‡ๅ—

4. Manual Skills Installation (Optional)

If one-click installation is not supported or preferred, follow this standard procedure for manual deployment (applicable to all tools supporting Skills):

โœ… Standard Installation Method A

  1. Custom Installation: In the installation interface, select the "Custom Path" option to install Skills to any directory you specify (e.g., Assets/MyTools/AI) for easier project management.

โœ… Standard Installation Method B

  1. Locate Skills Source Directory: The SkillsForUnity/unity-skills~/ directory in the UPM package is the distributable Skills template (root directory contains SKILL.md).
  2. Find the Tool's Skills Root Directory: Different tools have different paths; refer to the tool's documentation first.
  3. Copy Completely: Copy the entire contents of unity-skills~/ to the tool's Skills root directory (rename to unity-skills/).
  4. Create agent_config.json: Create an agent_config.json file in the unity-skills/scripts/ directory:
    {"agentId": "your-agent-name", "installedAt": "2026-02-11T00:00:00Z"}
    
    Replace your-agent-name with the name of your AI tool (e.g., claude-code, antigravity, codex, cursor).
  5. Directory Structure Requirements: After copying, maintain the structure as follows (example):
    • unity-skills/SKILL.md
    • unity-skills/skills/
    • unity-skills/references/
    • unity-skills/scripts/unity_skills.py
    • unity-skills/scripts/agent_config.json
  6. Restart the Tool: Let the tool reload the Skills list.
  7. Verify Loading: Trigger the Skills list/command in the tool (or execute a simple skill call) to confirm availability.

๐Ÿ”Ž Common Tool Directory Reference

The following are verified default directories (if the tool has a custom path configured, use that instead):

  • Claude Code: ~/.claude/skills/
  • Antigravity: ~/.gemini/antigravity/skills/ (global) or .agents/skills/ (workspace)
  • OpenAI Codex: ~/.agents/skills/ (global) or .agents/skills/ (workspace, shared with Antigravity)
  • Cursor: ~/.cursor/skills/ (global) or .cursor/skills/ (workspace); also auto-discovers .agents/skills/

๐Ÿงฉ Other Tools Supporting Skills

If you're using other tools that support Skills, install according to the Skills root directory specified in that tool's documentation. As long as the standard installation specification is met (root directory contains SKILL.md and maintains skills/, references/, and scripts/ structure), it will be correctly recognized.


๐Ÿ“ฆ Skills Category Overview (750)

CategoryCountCore Functions
YooAsset40Hot-update bundle builds/Collector full CRUD/BuildReport asset and dependency analysis/PlayMode runtime validation/Reporter-Debugger-AssetArtScanner tools
Workflow23Persistent history/Task snapshots/Session-level undo/Rollback/Bookmarks/Batch query-preview-execute jobs
Cinemachine342.x/3.x dual version auto-install/MixingCamera/ClearShot/TargetGroup/Spline
Netcode33Netcode for GameObjects setup/prefabs/lifecycle/host-server-client workflows
UI26Canvas/Button/Text/InputField/Dropdown/ScrollView/Layout/Alignment/Image and selectable utilities
UI Toolkit25UXML/USS file management/UIDocument/PanelSettings full property read-write/Template generation/Structure inspection/Batch create
ShaderGraph23Shader Graph create/inspect/blackboard edit/constrained node editing
ProBuilder22ProBuilder shape creation/face-edge operations/UV tools/pivot edits/batch creation/mesh combination
XR22XR rig setup/interactors/interactables/teleportation/continuous move/UI/haptics/interaction layers
Material21Batch material property modification/HDR/PBR/Emission/Keywords/Render queue
PostProcess20SRP post-processing effect management
GameObject18Create/Find/Transform sync/Batch operations/Hierarchy management/Rename/Duplicate
Perception18Scene summary/health checks/stack detection/context export/dependency analysis/hotspots/diff/tag-layer stats/performance hints
Volume18VolumeProfile/Volume/VolumeComponent creation and parameter editing
Validation10Project validation/Empty folder cleanup/Reference detection/Mesh collider/Shader errors
URP14URP asset/renderer/renderer feature inspection and edits
Decal14URP Decal Projector create/inspect/configure/delete workflows
DOTween21DOTweenAnimation editor-time setup and tuning
Editor12Play mode/Selection/Undo-Redo/Context retrieval/Menu execution
Physics12Raycast/SphereCast/BoxCast/Physics materials/Layer collision matrix
Script12C# script create/Read/Replace/List/Info/Rename/Move/Analyze
Timeline12Track create/Delete/Clip management/Playback control/Binding/Duration
Asset11Asset import/Delete/Move/Copy/Search/Folders/Batch operations/Refresh
AssetImport11Texture/Model/Audio/Sprite import settings/Label management/Reimport
Camera11Scene View control/Game Camera create/Properties/Screenshot/Orthographic toggle/List
Graphics11GraphicsSettings/QualitySettings/SRP asset operations
Package11Package management/Install/Remove/Search/Versions/Dependencies/Cinemachine/Splines
Prefab11Create/Instantiate/Override apply & revert/Batch instantiate/Variants/Find instances/Asset property editing
Shader11Shader create/URP templates/Compile check/Keywords/Variant analysis/Global keywords
Test13Test run/Run by name/Categories/Template create/Summary statistics
Animator10Animation controller/Parameters/State machine/Transitions/Assign/Play
Audio10Audio import settings/AudioSource/AudioClip/AudioMixer/Batch
Cleaner10Unused assets/Duplicate files/Empty folders/Missing script fix/Dependency tree
Component10Add/Remove/Property config/Batch operations/Copy/Enable-Disable
Console10Log capture/Clear/Export/Statistics/Pause control/Collapse/Clear on play
Debug10Error logs/Compile check/Stack trace/Assemblies/Define symbols/Memory info
Event10UnityEvent listener management/Batch add/Copy/State control/List
Light10Light create/Type config/Intensity-Color/Batch toggle/Probe groups/Reflection probes/Lightmaps
Model10Model import settings/Mesh info/Material mapping/Animation/Skeleton/Batch
NavMesh10Bake/Path calculation/Agent/Obstacle/Sampling/Area cost
Optimization10Texture compression/Mesh compression/Audio compression/Scene analysis/Static flags/LOD/Duplicate materials/Overdraw
Profiler10FPS/Memory/Texture/Mesh/Material/Audio/Rendering stats/Object count/AssetBundle
Scene10Multi-scene load/Unload/Activate/Screenshot/Context/Dependency analysis/Report export
ScriptableObject10Create/Read-Write/Batch set/Delete/Find/JSON import-export
Smart10Scene SQL query/Spatial query/Auto layout/Snap to ground/Grid snap/Randomize/Replace
Terrain10Terrain create/Heightmap/Perlin noise/Smooth/Flatten/Texture painting
Texture10Texture import settings/Platform settings/Sprite/Type/Size search/Batch
Project9Render pipeline/Build settings/Package management/Layer/Tag/PlayerSettings/Quality
Sample8Basic examples: Create/Delete/Transform/Scene info
Diagnose1Aggregated Editor health snapshot (console/compile/workflow/server/jobs)

โš ๏ธ Most modules support *_batch batch operations. When operating on multiple objects, prioritize batch Skills for better performance.

๐Ÿง  unity-skills/skills/ also includes 19 advisory design modules for architecture, script design, performance, maintainability, Inspector guidance, and package-specific source rules.


๐Ÿ“‚ Project Structure

.
โ”œโ”€โ”€ SkillsForUnity/                 # Unity Editor Plugin (UPM Package)
โ”‚   โ”œโ”€โ”€ package.json                # com.besty.unity-skills
โ”‚   โ”œโ”€โ”€ unity-skills~/              # Cross-platform AI Skill Template (tilde-hidden, bundled with package)
โ”‚   โ”‚   โ”œโ”€โ”€ SKILL.md                # Main Skill Definitions (AI-readable)
โ”‚   โ”‚   โ”œโ”€โ”€ scripts/
โ”‚   โ”‚   โ”‚   โ””โ”€โ”€ unity_skills.py     # Python Client Library
โ”‚   โ”‚   โ”œโ”€โ”€ skills/                 # 68 module docs (49 REST/module docs + 19 advisory docs)
โ”‚   โ”‚   โ””โ”€โ”€ references/             # Unity Development References
โ”‚   โ””โ”€โ”€ Editor/Skills/              # Core Skill Logic (51 *Skills.cs files, 750 Skills)
โ”‚       โ”œโ”€โ”€ SkillsHttpServer.cs     # HTTP Server Core (Producer-Consumer)
โ”‚       โ”œโ”€โ”€ SkillRouter.cs          # Request Routing & Reflection-based Skill Discovery
โ”‚       โ”œโ”€โ”€ WorkflowManager.cs      # Persistent Workflow (Task/Session/Snapshot)
โ”‚       โ”œโ”€โ”€ RegistryService.cs      # Global Registry (Multi-instance Discovery)
โ”‚       โ”œโ”€โ”€ GameObjectFinder.cs     # Unified GO Finder (name/instanceId/path)
โ”‚       โ”œโ”€โ”€ BatchExecutor.cs        # Generic Batch Processing Framework
โ”‚       โ”œโ”€โ”€ GameObjectSkills.cs     # GameObject Operations (18 skills)
โ”‚       โ”œโ”€โ”€ MaterialSkills.cs       # Material Operations (21 skills)
โ”‚       โ”œโ”€โ”€ CinemachineSkills.cs    # Cinemachine 2.x/3.x (34 skills)
โ”‚       โ”œโ”€โ”€ WorkflowSkills.cs       # Workflow Undo/Rollback (23 skills)
โ”‚       โ”œโ”€โ”€ PerceptionSkills.cs     # Scene Understanding (18 skills)
โ”‚       โ””โ”€โ”€ ...                     # 750 Skills source code
โ”œโ”€โ”€ docs/
โ”‚   โ””โ”€โ”€ SETUP_GUIDE.md              # Complete Setup & Usage Guide
โ”œโ”€โ”€ CHANGELOG.md                    # Version Update Log
โ””โ”€โ”€ LICENSE                         # MIT License

โญStar History

Star History Chart

๐Ÿ“„ License

This project is licensed under the MIT License.