BiomeManager
SingletonCentral registry and lock-state authority. Zones register with it, unlock evaluation runs through it, and all global events (enter/exit, unlock/lock) are raised here. One per game - it survives scene loads.
Properties
| Property | Type | Description |
|---|---|---|
| Instance | static BiomeManager | Global access point |
| OnBiomeEnter / OnBiomeExit | static event | Raised when a tracked object enters/leaves a zone |
| OnBiomeUnlocked / OnBiomeLocked | static event | Raised on lock-state changes |
| GetCurrentBiome(target) | BiomeDefinition | Biome a given object is currently inside |
| IsBiomeLocked(id) | bool | Current lock state by biome ID |
| GetUnlockedBiomeIds() / LoadUnlockedSet() | API | Persistence endpoints used by the Biome Unlocks memory |
BiomeZone
Scene ComponentThe boundary of a biome in a scene. Collider shape uses the attached trigger collider; Polygon shape uses an authored XZ outline with Scene-view handle editing. Spawns/despawns the barrier on lock changes.
Properties
| Property | Type | Description |
|---|---|---|
| Biome Definition | BiomeDefinition | The biome this zone belongs to |
| Priority | int | Nesting: when zones overlap, the highest priority provides the current biome |
| Shape | Collider | Polygon | Boundary source |
| Polygon Points / Height | List<Vector2>, float | Outline in local XZ + vertical extent |
| Tracked Tag | string | Tag polled by polygon zones (default: Player) |
| Blend Distance | float | Spatial environment blend near the border (0 = off) |
| ContainsPoint(worldPos) | bool | Polygon containment test |
| GetDistance(worldPos) | float | Distance to the zone boundary (0 inside) |
| GetClosestPoint(worldPos) | Vector3 | Nearest boundary point - anchor for direction indicators |
BiomeBarrier
Auto-SpawnedSolid wall raised on locked zone boundaries. Generates its own holographic shield visual (continuous outline ribbon on polygons) tinted with the biome’s barrier color. Contact fires the OnBarrierHit event, cooldown-gated.
Properties
| Property | Type | Description |
|---|---|---|
| OnBarrierHit | static event | (biome, worldPos) - raised on entrant contact |
| Hit Cooldown | float | Minimum seconds between feedback events |
| Hit VFX / Floating Text Prefab | GameObject | Optional feedback prefabs |
| LockedMessage / UnlockHint | string | Display texts read from the biome definition |
RequirementDatabase
Player ComponentHolds the set of granted requirement tokens. Granting the last missing token of a biome unlocks it automatically. May live on the player root or a child object - all lookups search parents, children, then the static Main fallback.
Properties
| Property | Type | Description |
|---|---|---|
| Grant(requirement) / Revoke(requirement) | method | Modify the granted set |
| Has(requirement) | bool | Membership test |
| OnGranted / OnRevoked | static event | Raised on changes |
| Main | static RequirementDatabase | First enabled instance (used by UI proximity checks) |
| GetGrantedIds() / LoadGrantedSet() | API | Persistence endpoints used by the Biome Requirements memory |
RequirementAutoGrant
Player ComponentSingle observer that sweeps all pending self-evaluating requirements (e.g. "Level ≥ 5" conditional requirements) on an interval and grants them when their conditions hold. Replaces per-requirement scene triggers.
Properties
| Property | Type | Description |
|---|---|---|
| Interval | float | Sweep frequency (default 0.5 s) |
| Evaluation Target | GameObject | Args target for Self/Target-based conditions (set to the character root when the database lives on a child) |
| Additional Watch | RequirementAsset[] | Extra requirements beyond those referenced by registered biomes |
| Sweep() | method | Force an immediate re-check after a known event |
BiomeDiscoveryDatabase
Player ComponentTracks discovered biomes and visit counts, independent of unlock state. Entering a biome records a visit automatically; manual reveals (map purchase) use the Mark Biome Discovered instruction.
Properties
| Property | Type | Description |
|---|---|---|
| IsDiscovered(biome) | bool | Has the player found this biome |
| GetVisitCount(biome) | int | Number of recorded visits |
| DiscoveredCount | int | Total discovered biomes |
| OnDiscovered | event | Raised on first discovery |
Controllers (one each per scene)
BiomeEnvironmentController
Cross-fades skybox, ambient light, fog, URP post-processing volume weight and terrain distances between environment profiles. Holds the Default Profile used outside all biomes and drives spatial border blending.
BiomeWeatherController
Spawns/cross-fades weather particles, tints the sun, drives wind and weather audio. Maintains the Available Profiles registry used by the Cycle Weather instruction, runs weather-table schedules, and raises the static OnWeatherChanged event.
BiomeAudioController
Two-source music cross-fade plus a randomized ambient one-shot pool with configurable intervals.
BiomeCozyBridge (optional)
Forwards weather changes to COZY: Stylized Weather by mapping WeatherTypes to COZY profiles. Binds via reflection — zero dependency when COZY is absent, and it warns once per unmapped weather type instead of failing silently.
Profile & Data Assets
| Asset | Create Menu | Contains |
|---|---|---|
| Biome Definition | Biome Manager → Biome Definition | Identity, lock settings, requirements, profile references, GC2 event lists |
| Environment Profile | Biome Manager → Environment → Environment Profile | Skybox, ambient, fog, post-processing, terrain distances, transition time |
| Weather Profile | Biome Manager → Environment → Weather Profile | WeatherType, particles, wind, light tint, audio loop |
| Weather Table | Biome Manager → Environment → Weather Table | Weighted weather entries with min/max hold times |
| Audio Profile | Biome Manager → Environment → Audio Profile | Music clip, ambient one-shot pool, volumes, fade time |
| Requirement | Biome Manager → Requirement | Token identity, description, icon, player-facing hint |
| Requirement (GC2 Conditions) | Biome Manager → Requirement (GC2 Conditions) | A requirement that self-evaluates via an embedded GC2 ConditionList |