[Phase 3.1] Headless Match Server & project_for_player() Fog-of-War Masking #11

Open
opened 2026-11-17 06:12:20 +00:00 by john4064 · 0 comments
Owner

Goal

Stand up isolated server-authoritative DromeMatchInstance rooms in a headless Bevy MinimalPlugins binary routing every outgoing update through project_match_state_for_player().

Metadata

  • Phase / Step: Phase 3.1
  • Depends On: #26, #27
  • Unlocks: #14, #15, #28, #30
  • Target Crates / Paths: crates/chaotic_server/, src/netcode/
  • Line Budget Plan: Production .rs <= 400 lines, test .rs <= 600 lines, mod.rs < 80 lines (AGENTS.md Section 2.3)

Acceptance Criteria

  • Never broadcast raw MatchState via Bevy Changed<T> replication.
  • Route 100% of outgoing packets through project_match_state_for_player(state, viewer).
  • Strip unrevealed face-down Battlegear IDs (CardVisibility::FaceDown), unflipped Location/Attack deck order (remaining_count: u8), and opponent Attack/Mugic hand identities (hand_count: u8).
  • Integration test asserts opponent packet payloads contain zero hidden Battlegear or hand card IDs.
## Goal Stand up isolated server-authoritative `DromeMatchInstance` rooms in a headless Bevy `MinimalPlugins` binary routing every outgoing update through `project_match_state_for_player()`. ## Metadata - **Phase / Step:** Phase 3.1 - **Depends On:** #26, #27 - **Unlocks:** #14, #15, #28, #30 - **Target Crates / Paths:** `crates/chaotic_server/`, `src/netcode/` - **Line Budget Plan:** Production `.rs` <= 400 lines, test `.rs` <= 600 lines, `mod.rs` < 80 lines (`AGENTS.md` Section 2.3) ## Acceptance Criteria - [ ] Never broadcast raw `MatchState` via Bevy `Changed<T>` replication. - [ ] Route 100% of outgoing packets through `project_match_state_for_player(state, viewer)`. - [ ] Strip unrevealed face-down Battlegear IDs (`CardVisibility::FaceDown`), unflipped Location/Attack deck order (`remaining_count: u8`), and opponent Attack/Mugic hand identities (`hand_count: u8`). - [ ] Integration test asserts opponent packet payloads contain zero hidden Battlegear or hand card IDs.
Sign in to join this conversation.
No description provided.