fix(simulation): correct tick synchronization in snapshot generation

Snapshot for tick N should show state at END of tick N. Reorder systems
so generate_snapshot runs after validate_movement but before
advance_tick. Previously snapshot.tick was the incremented tick,
not the tick whose inputs were processed. Also fix main.rs accept
error to log address context before exiting.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-02-11 21:16:04 +01:00
co-authored by Claude Opus 4.6
parent 2cd8786036
commit b9af725b02
2 changed files with 35 additions and 71 deletions
+2 -2
View File
@@ -24,8 +24,8 @@ impl Plugin for SimulationPlugin {
Update,
(
input::process_player_input,
time::advance_tick.after(input::process_player_input),
movement::validate_movement.after(time::advance_tick),
movement::validate_movement.after(input::process_player_input),
time::advance_tick.after(movement::validate_movement),
),
);