본문으로 건너뛰기
cccskills
무료GitHub에 공개

uw-unity-editor-tools

Generate custom editor tooling including Custom Inspectors, PropertyDrawers, EditorWindows, Gizmos, and Handles. Use when building designer-facing tools, spatial visualization, batch operations, or custom component UIs. Triggers on requests like "create a custom inspector", "add gizmos", "build an editor window", "make this component designer-friendly", "add a debug visualization", "create a level editor tool", "add a property drawer", "make a batch rename tool", or any editor tooling work. Always uses SerializedProperty and Undo for safety.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

설치 방법 보기

포함된 파일(4)

  • SKILL.md6.1 KB
  • references/custom-inspector.md3.2 KB
  • references/editor-window.md4.1 KB
  • references/property-drawer.md3.6 KB

SKILL.md(원문)

설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.

Unity Editor Tools

Generate editor tooling that follows Unity best practices.

Before You Start

  1. Read docs/ProjectConfig.yaml for:
    • unity_version — UI Toolkit editor UI requires 2022.2+ (all Unity 6+ projects qualify).
    • ui_system — if "UIToolkit" or "Mixed", prefer UI Toolkit for editor UIs too (consistent approach).
    • mcp.unity_mcp — if true, call refresh_unity after creating files.
  2. Check if the feature has an Editor/ asmdef — if not, create one. The Editor asmdef must reference the Runtime asmdef and have Editor as its only Include Platform.
  3. Read docs/NAMING_CONVENTIONS.md for editor script naming.

Core Rules (Non-Negotiable)

// ALWAYS: Use SerializedProperty for inspector fields
SerializedProperty _healthProp;
void OnEnable() => _healthProp = serializedObject.FindProperty("_health");

// NEVER: Direct field access (breaks multi-edit, prefabs, undo)
((MyComponent)target)._health = EditorGUILayout.FloatField(((MyComponent)target)._health);
// ALWAYS: Record undo before modifications
Undo.RecordObject(target, "Changed patrol point");
myComponent.patrolPoints[i] = newPos;

// NEVER: Modify without undo
myComponent.patrolPoints[i] = newPos;
// ALWAYS: Mark dirty after changes in tools
EditorUtility.SetDirty(target);

// ALWAYS: Apply modified properties in inspectors
serializedObject.ApplyModifiedProperties();

Tool Selection

NeedToolReference
Custom component UI in InspectorCustom Inspectorreferences/custom-inspector.md
Reusable field decoration ([MinMax], [ReadOnly])PropertyDrawerreferences/property-drawer.md
Standalone tool panelEditorWindowreferences/editor-window.md
Always-on spatial visualizationOnDrawGizmos / OnDrawGizmosSelectedInline below
Interactive scene handles (draggable)Handles APIInline below

Gizmos (Quick Reference)

// In a MonoBehaviour — no Editor assembly needed
private void OnDrawGizmosSelected()
{
    Gizmos.color = new Color(0f, 1f, 0f, 0.3f);
    Gizmos.DrawWireSphere(transform.position, _radius);
}

Handles (Quick Reference)

// In an Editor script — requires Editor assembly
[CustomEditor(typeof(PatrolPath))]
public class PatrolPathEditor : Editor
{
    private void OnSceneGUI()
    {
        var path = (PatrolPath)target;
        for (int i = 0; i < path.Points.Count; i++)
        {
            EditorGUI.BeginChangeCheck();
            Vector3 newPos = Handles.PositionHandle(path.Points[i], Quaternion.identity);
            if (EditorGUI.EndChangeCheck())
            {
                Undo.RecordObject(path, "Move patrol point");
                path.Points[i] = newPos;
                EditorUtility.SetDirty(path);
            }
        }
    }
}

Editor Script Placement

Assets/_Project/Features/{Feature}/
├── Runtime/
│   ├── {Feature}.asmdef          <- Runtime assembly
│   └── MyComponent.cs
└── Editor/
    ├── {Feature}.Editor.asmdef   <- References Runtime assembly
    ├── MyComponentInspector.cs
    └── MyComponentGizmos.cs

The Editor asmdef must:

  • Reference the Runtime asmdef
  • Have Editor in its Include Platforms (only)
  • Never be referenced by Runtime assemblies

Build Validation

Add pre-build validators to catch issues before shipping. Place in an Editor assembly.

using UnityEditor;
using UnityEditor.Build;
using UnityEditor.Build.Reporting;

public class PreBuildValidator : IPreprocessBuildWithReport
{
    public int callbackOrder => 0;

    public void OnPreprocessBuild(BuildReport report)
    {
        // Run unit tests — fail build if any test fails
        // Validate all scenes in Build Settings exist
        // Check for missing script references on prefabs
    }
}

Common validations: unit test pass/fail, scene list completeness, missing component references on prefabs, unresolved addressable entries.

After Setup

  • Debug visualization: Use uw-unity-debugging Gizmos for debug-specific visualizations (raycast paths, trigger volumes, AI sight cones).
  • Write tests: Use uw-unity-test-runner — test editor tools in EditMode (validate that SerializedProperty operations produce correct results).
  • SO inspectors: Use uw-scriptable-object-arch data containers with custom inspectors for designer-friendly data editing.
  • UI Toolkit binding: Use uw-ui-toolkit-binder patterns if building editor windows with data binding.

Principles

  • Undo is non-negotiable: Any editor tool that modifies state without undo support is a bug. Always Undo.RecordObject before changes.
  • Designer empathy: Tools exist to make non-programmers productive. A confusing inspector is a failed tool. Ask: is this for designers (intuitive, visual) or developers (can be technical)?
  • Build alongside features: Don't wait for a "tooling phase." Build the inspector while the component is being created.

Rules

  • Always use SerializedProperty for inspector fields — never direct field access.
  • Always record Undo before any state modification.
  • Always serializedObject.ApplyModifiedProperties() at the end of inspector OnInspectorGUI.
  • Editor scripts live in Editor/ folders with their own .asmdef that includes only Editor platform.
  • Never reference Editor assemblies from Runtime assemblies.
  • [SerializeField] private for all Inspector fields — never public fields.
  • If ProjectConfig.yaml -> mcp.unity_mcp is true, call refresh_unity after creating files.

리뷰

아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.

댓글

로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.

아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.

보내면 바로 공개됩니다. 이메일 주소나 전화번호 같은 개인 정보는 쓰지 마세요. URL은 2개까지입니다.

0 / 1,000자

이 양식은 reCAPTCHA로 보호되며 Google 개인정보처리방침 및 서비스 약관이 적용됩니다.

같은 저장소의 스킬

adopt

무료

Brownfield onboarding — audits existing project artifacts for template format compliance (not just existence), classifies gaps by impact, and produces a numbered migration plan. Run this when joining an in-progress project or upgrading from an older template version. Distinct from /project-stage-detect (which checks what exists) — this checks whether what exists will actually work with the template's skills.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

IdoCohen560/claude-unity-game-studio222026년 7월 8일 업데이트

Creates an Architecture Decision Record (ADR) documenting a significant technical decision, its context, alternatives considered, and consequences. Every major technical choice should have an ADR.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

IdoCohen560/claude-unity-game-studio222026년 7월 8일 업데이트

Validates completeness and consistency of the project architecture against all GDDs. Builds a traceability matrix mapping every GDD technical requirement to ADRs, identifies coverage gaps, detects cross-ADR conflicts, verifies engine compatibility consistency across all decisions, and produces a PASS/CONCERNS/FAIL verdict. The architecture equivalent of /design-review.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

IdoCohen560/claude-unity-game-studio222026년 7월 8일 업데이트

art-bible

무료

Guided, section-by-section Art Bible authoring. Creates the visual identity specification that gates all asset production. Run after /brainstorm is approved and before /map-systems or any GDD authoring begins.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

IdoCohen560/claude-unity-game-studio222026년 7월 8일 업데이트

Audits game assets for compliance with naming conventions, file size budgets, format standards, and pipeline requirements. Identifies orphaned assets, missing references, and standard violations.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

IdoCohen560/claude-unity-game-studio222026년 7월 8일 업데이트

Generate per-asset visual specifications and AI generation prompts from GDDs, level docs, or character profiles. Produces structured spec files and updates the master asset manifest. Run after art bible and GDD/level design are approved, before production begins.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

IdoCohen560/claude-unity-game-studio222026년 7월 8일 업데이트

IdoCohen560의 스킬 모두 보기

이 스킬의 문제 신고