Add body-camera timeline to the shift review
- New src/game/ui/event_timeline.gd flattens every recorded incident event (ADR-0005) into one time-ordered list and shows time, person, and a one-line summary. Step with Left/Right or the buttons; Esc returns to the review. No live 3D replay in this first version. - Shift review gains a "Body camera timeline" button that hands the review to the timeline; the review dim is hidden while it is open (stacked overlays made the screen nearly black) and restored on close. - ShiftCoordinator records started_at_ms so the review can stamp events as mm:ss. - 8 new string keys for the timeline UI and the review button. Tests/docs - Headless suite 113 -> 120 (test_event_timeline.gd), new smoke_timeline.gd that opens the timeline from the review, steps through every event, and closes back. - README, TODO section moved to DONE, MEMORY notes. Version 0.2.6.
This commit is contained in:
1 parent
921bab796e
commit
1b976bf351
14 files changed
+614
-71
No files matched your search
@@ -21,6 +21,8 @@ signal phase_changed(phase: int)
|
||||
var scenario: VenueScenario = null
|
||||
var duration_s: float = 900.0
|
||||
var elapsed_s: float = 0.0
|
||||
## Wall-clock start, so the shift review can show event times as mm:ss.
|
||||
var started_at_ms: int = 0
|
||||
var current_phase: int = Rules.Phase.EARLY
|
||||
var running := false
|
||||
|
||||
@@ -65,6 +67,7 @@ func start() -> void:
|
||||
return
|
||||
running = true
|
||||
_shift_finished = false
|
||||
started_at_ms = Time.get_ticks_msec()
|
||||
elapsed_s = 0.0
|
||||
_spawn_accum_s = 0.0
|
||||
current_phase = _phase_for_time(0.0)
|
||||
@@ -137,6 +140,7 @@ func build_review() -> Dictionary:
|
||||
"scenario_id": scenario.id if scenario else "",
|
||||
"duration_s": duration_s,
|
||||
"elapsed_s": elapsed_s,
|
||||
"started_at_ms": started_at_ms,
|
||||
"phase_at_end": current_phase,
|
||||
"spawned_count": spawned_count,
|
||||
"incidents": recorder.to_dict(),
|
||||
|
||||
Reference in new issue
Block a user