unity-scene-contracts

Define Unity scene contracts for root objects, components, and bootstrap wiring.

Updated Aug 27, 2026
One-click install
npx skills add https://github.com/mandexonla/Top-Down-Template --skill unity-scene-contracts-mandexonla
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: unity-scene-contracts
Source: https://github.com/mandexonla/Top-Down-Template/tree/main/.codex/skills/unity-skills/skills/scene-contracts
Command: npx skills add https://github.com/mandexonla/Top-Down-Template --skill unity-scene-contracts-mandexonla

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Scene setup in Unity often relies on hidden runtime lookups, which leads to fragile builds. This skill provides an explicit scene contract to declare required root objects, components, bootstrap logic, and reference wiring rules, reducing surprises during runtime.

Core Features & Use Cases

  • Define required root objects and the components that must exist on each root.
  • Specify which references are assigned in Inspector and which objects are used for bootstrap/installers.
  • Capture which objects are runtime-spawned and what the scene contract requires to validate early.
  • Use cases include deterministic scene assembly across platforms, clear wiring rules, and early validation during development and CI. Guardrails:
  • Mode: Both (Semi-Auto + Full-Auto) — advisory only, no REST skills
  • Prefer explicit scene wiring over Find calls
  • Keep bootstrap objects focused and small.

Quick Start

Create a Unity scene contract by listing required root objects, components, bootstrap logic, and reference rules in SKILL.md and apply it to your scene to validate wiring.

Frequently Asked Questions about unity-scene-contracts

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

FAQPage Schema
How do I prevent hidden runtime lookups in Unity scenes?

To prevent hidden runtime lookups in Unity, define explicit scene contracts that specify required root objects, components, and reference wiring rules instead of relying on Find calls. This approach ensures deterministic scene assembly and early validation during development.

What is a Unity scene contract?

A Unity scene contract is an explicit declaration of required root objects, components, bootstrap logic, and reference wiring rules. It eliminates fragile builds by enforcing deterministic scene assembly and early validation across platforms and configurations.

How do I set up deterministic scene assembly in Unity?

Set up deterministic Unity scene assembly by creating a scene contract in SKILL.md that lists required root objects, bootstrap sequences, and inspector wiring rules. Applying this contract validates runtime-spawned objects and reference wiring early.

Can I validate Unity bootstrap ordering and reference wiring during CI?

Yes, you can validate Unity bootstrap ordering and reference wiring during CI by applying explicit scene contracts. These contracts output validation criteria and identify risks early, ensuring deterministic assembly across platforms.

Does explicit scene wiring work for runtime-spawned objects in Unity?

Yes, explicit scene wiring works for runtime-spawned objects by capturing what the scene contract requires to validate them early. You specify which references are assigned in the Inspector and declare the necessary bootstrap logic.

What is the best way to manage Unity bootstrap objects and installer references?

The best way to manage Unity bootstrap objects and installer references is to keep them focused and small while specifying them in an explicit scene contract. This advisory approach defines reference wiring rules and prevents hidden runtime lookups.