unity-foundation

Enforce Unity assembly boundaries and hybrid scene lifecycle contracts.

6|Updated Apr 2, 2026
One-click install
npx skills add https://github.com/dyCuong03/unity-agent-team --skill unity-foundation
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: unity-foundation
Source: https://github.com/dyCuong03/unity-agent-team/tree/main/.claude/skills/unity-foundation
Command: npx skills add https://github.com/dyCuong03/unity-agent-team --skill unity-foundation

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Unity projects often drift into inconsistent assembly boundaries and unclear scene lifecycle behavior, causing brittle integrations between ECS and MonoBehaviour and slowing development through avoidable compile and navigation confusion.

Core Features & Use Cases

  • Assembly Design Guardrails: Enforce editor/runtime separation and dedicated test assemblies so dependencies flow Tests → Runtime ← Editor and compilation stays fast.
  • Scene Lifecycle Contracts: Define explicit entry/exit expectations for ECS+MonoBehaviour hybrids, including bootstrap ordering and cleanup semantics.
  • Unity-Specific Code Quality Rules: Apply guard-clauses and thin MonoBehaviour wrappers while keeping ECS systems clean, reducing runtime errors and maintenance cost.

Quick Start

Ask the agent to apply unity-foundation guidance to your repo by mapping asmdef boundaries and rewriting the scene entry/exit lifecycle so ECS bootstrap/disposal and MonoBehaviour bootstrap remain consistent.

Frequently Asked Questions about unity-foundation

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I enforce Unity assembly boundaries in a hybrid ECS and MonoBehaviour project?

To enforce Unity assembly boundaries, separate editor and runtime code into dedicated assemblies and establish test assemblies so dependencies flow Tests to Runtime to Editor, keeping compilation fast and preventing integration drift in hybrid ECS and MonoBehaviour projects.

What is the best way to manage scene lifecycle entry and exit semantics in Unity ECS?

Managing scene lifecycle entry and exit semantics requires defining explicit bootstrap ordering and cleanup expectations for ECS and MonoBehaviour components. This ensures consistent scene entry and disposal behavior and reduces runtime errors during transitions in hybrid architectures.

Why does my Unity project have compilation friction and navigation confusion in large repos?

Compilation friction and navigation confusion in large Unity repos usually stems from inconsistent assembly definitions and unclear code boundaries. Mapping asmdef boundaries and checking workspace guidance files enforces separation to reduce this drift.

How do I structure MonoBehaviour wrappers when using Unity ECS?

Structure MonoBehaviour wrappers as thin components that apply guard clauses while keeping ECS systems clean. This Unity-specific code quality approach reduces maintenance cost and runtime errors by ensuring wrappers handle bootstrap without polluting ECS logic.

Do I need a specific ECS framework to use scene lifecycle contracts for Unity hybrid architecture?

Scene lifecycle contracts apply to ECS plus MonoBehaviour hybrid projects where scenes need clear entry and exit semantics. Treat this guidance as secondary to ECS skills and use Unity-safe practices for MonoBehaviour wrappers and debug logging.

When should I not use asmdef separation for editor and runtime code in Unity?

You should maintain asmdef separation for editor and runtime code whenever your Unity project has distinct editor tooling and runtime logic. Avoid skipping this separation if you want fast compilation and clean dependency flow from Tests to Runtime to Editor.