skills/unity-editor/SKILL.md
Write Unity Editor scripts — custom inspectors, editor windows, property drawers, scene handles, gizmos, and menu items. Auto-triages: Quick (single editor script — one inspector, one window, one drawer) or Deep (multi-file editor tooling — level editors, custom pipelines, inspector + gizmos + window combos). MUST use for ANY Unity Editor code request — custom inspectors, editor windows, property drawers, gizmos, handles, menu items, scene tools. Triggers: "custom inspector," "editor window," "property drawer," "gizmo," "scene handles," "menu item," "editor tool," "custom editor." Do not use for runtime scripts (unity-code), UI Toolkit (unity-uitoolkit), tests (unity-test-unit), or debugging (unity-debug).
npx skillsauth add cuozg/oh-my-skills unity-editorInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Detect scope, identify extension type, implement editor script under Editor/, verify compilation.
| Signal | Scope | |--------|-------| | One editor script (inspector, window, or drawer) | Quick | | 2+ editor files, complex tooling (window + inspector + gizmos) | Deep |
State triage: "This is [scope] — [reason]."
| Type | Base Class | Attribute | Entry Point |
|------|-----------|-----------|-------------|
| Custom Inspector | Editor | [CustomEditor(typeof(X))] | OnInspectorGUI() |
| Editor Window | EditorWindow | — | [MenuItem] + GetWindow<T>() |
| Property Drawer | PropertyDrawer | [CustomPropertyDrawer(typeof(X))] | OnGUI(Rect, SerializedProperty, GUIContent) |
| Scene Handles | Editor | [CustomEditor(typeof(X))] | OnSceneGUI() |
Quick: Qualify → Discover (read target runtime class + nearby Editor/) → Implement → lsp_diagnostics → Handoff
Deep: Qualify → Discover (all target classes + existing Editor/ scripts) → Plan (list all files, types, dependency order) → Implement (shared utilities → individual editors → menus/shortcuts) → lsp_diagnostics → Handoff
| Action | Tool |
|--------|------|
| Manage tags/layers | Unity.ManageEditor (AddTag, RemoveTag, AddLayer, GetLayers) |
| Execute/find menu items | Unity.ManageMenuItem (List → Execute) |
| Check editor state/selection | Unity.ManageEditor (GetState, GetSelection, GetPrefabStage) |
| Verify compilation | Unity.ReadConsole or Unity.GetConsoleLogs |
Full MCP routing: read_skill_file("unity-standards", "references/other/unity-mcp-routing-matrix.md") → Editor Control Branch.
Editor/ folderusing UnityEditor to runtime scriptsbase.OnInspectorGUI() before custom GUI unless fully replacingserializedObject.Update() / ApplyModifiedProperties() around all SerializedProperty editsSerializedProperty over direct field access (supports Undo + Prefab overrides)EditorGUILayout for window/inspector GUI; EditorGUI for fixed-rect drawingGetWindow<T>() inside [MenuItem] static methodtarget casts in OnInspectorGUIUndo.RecordObject(target, "action") before mutations#if UNITY_EDITOR when referenced from runtime codeEditorUtility.SetDirty(target) after direct mutationslsp_diagnostics after every change| To | When |
|----|------|
| Deep | Work requires a second editor file |
| Quick | Plan reveals single-file scope |
| unity-code | Target is runtime domain |
read_skill_file("unity-standards", "references/<path>"):
code-standards/architecture-systems.md — Editor patterns, gizmos, handlescode-standards/core-conventions.md — naming, serialization, null safetyother/unity-mcp-routing-matrix.md — MCP editor control tools, guard clausestools
Generate Unity raster image assets through Unity MCP: game sprites, item art, backgrounds, UI icons, portraits, concept images, transparent cutouts, image edits, upscales, background removal, and Unity scene or Game View screenshots. Use when a Unity project needs image files imported under Assets or screenshots captured from the editor. Do not use for meshes, audio, animation, materials, gameplay code, UI Toolkit layout, or generic non-Unity image generation.
tools
Create Unity technical solution documents from user requirements, feature ideas, bug goals, specs, or codebase problems. Use when the user asks for a technical approach, architecture, implementation strategy, solution options, feasibility analysis, system design, or "how should we build/fix this" for Unity runtime, Editor, tools, assets, data, UI, WebGL, SDKs, or production pipelines.
tools
Orchestrate Unity Editor via MCP (Model Context Protocol) tools and resources. Use when working with Unity projects through MCP for Unity - creating/modifying GameObjects, editing scripts, managing scenes, running tests, or any Unity Editor automation. Provides best practices, tool schemas, and workflow patterns for effective Unity-MCP integration.
development
Convert a spec document into an implementation TODO list in the same spec folder. U se when the user says goal-todo, todo from spec, generate tasks from spec, turn this spec into todos, create implementation checklist, extract tasks, or asks to read a Docs/Specs design doc and produce what must be implemented. Includes UI/UX review and codebase investigation before writing the checklist. Do not use for implementing the tasks, creating new goal files, writing test cases, or verifying completed work.