feat(simulation): sprint 12 server — tier system, sound events, KG access, line previewer

Implements 4 completed tickets + partial progress on 2 more:

- #93 Tier marker components (ActiveSim, BackgroundSim, StateSaved + TierPlugin)
- #138 Information tag schema (ObserverAccess enum in knowledge/types.rs)
- #124 Sound event system (SoundEventEmitter, SoundEventQueue, bridge wiring)
- #193 Line previewer CLI (line_preview binary with filter/explain/sequence modes)
- #94 Active tier simulation (in progress — With<ActiveSim> filters)
- #139 Component-level access control (in progress — filter_by_access)

Updates snapshot fixtures and test golden files for new sound_events field.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-02-19 13:33:23 +01:00
co-authored by Claude Opus 4.6
parent f7e5b7eb63
commit 066f8031fd
30 changed files with 1646 additions and 14 deletions
+5 -1
View File
@@ -8,6 +8,7 @@ use bevy_ecs::prelude::*;
use crate::npc::{DailyRoutine, Npc};
use crate::simulation::movement::TilePosition;
use crate::simulation::pathfinding::PathRequest;
use crate::simulation::tier::ActiveSim;
use crate::simulation::time::{DayPhase, SimulationTime};
/// Resource tracking the previous day phase for transition detection.
@@ -28,11 +29,14 @@ impl Default for PreviousDayPhase {
/// System: detect day-phase transitions and issue PathRequests for NPC routines.
/// Runs after advance_tick so the current phase is up-to-date.
///
/// Scoped to `ActiveSim` NPCs — only active-tier NPCs receive routine-based
/// PathRequests on phase transitions (D-026, #94).
pub fn check_phase_transition(
time: Res<SimulationTime>,
mut previous: ResMut<PreviousDayPhase>,
mut commands: Commands,
npcs: Query<(Entity, &TilePosition, &DailyRoutine), With<Npc>>,
npcs: Query<(Entity, &TilePosition, &DailyRoutine), (With<Npc>, With<ActiveSim>)>,
) {
let current_phase = time.day_phase();
let current_day = time.day();