Skip to content

[feat] 24-b r1: the game-football e2e suite (real scene + real zip, two peers + late joiner) - #226

Merged
AlexZ005 merged 1 commit into
release/nextfrom
feat/29-football-suite
Sep 19, 2026
Merged

AlexZ005 merged 1 commit into
release/nextfrom
feat/29-football-suite

Conversation

@AlexZ005

Copy link
Copy Markdown
Collaborator

Lane 29-football: the 24-B remainders (R1 → R2 → R3).

What landed

  • R1 2be54c3: tests/e2e/game-football.test.cjs. It loads the real games/football/scene.tpscene from the scenes feed (SCENES_BASE @v2) and installs the real football.zip on two peers plus a late joiner. If the scene or the zip can't be reached, the suite skips with the reason printed; it never fails on the network. It covers the modules test-flight's cases, the HUD screens (menu, playing, pause, over) and the P menu. Game-shell transitions are asserted on the trigger log, never on a perRound flowValue.
    • Counterfactuals:
      • A ball nobody touched, put into the red gate, still scores for blue and credits no player (in-suite).
      • The late joiner with remoteSimulating cleared gets a dead knock probe (in-suite, then restored).
      • With the handshake simulate push disabled in peerHandler, checks 5.3 and 5.8 go red; restored, they pass.
  • R2 (D1, the HUD-builder decision): no, nothing committed. I tried a gameShellHud({...}) extraction and authored Towers and Stars Room before and after it (--only towers,stars-room --out .d1/{before,after}, then node scripts/compare-authored.cjs .d1/before .d1/after):
    • Towers came out identical; Stars Room did not (first difference: pause panel w 400 → 380).
    • Stars Room has no menu screen, and its pause screen uses different sizes and spacing from Towers' (400x400 panel with 5 buttons 50px apart, against 380x300 with 3 buttons 52px apart). The Beat contest's menu differs from Towers' in 8 numbers.
    • The only screen with the same shape in two games is "over", and Football's HUD lives in the module (hud.js → football.def.json), so a core helper can't produce it.
  • R3 is modules PR [docs] 24-b r3: football row, api.onHit/hitLog digest, DEVX #15 yes modules#6 (docs).

Suites

suite this branch base
game-football (new) 102 PASS / 0 FAIL, 71 s —
game-stars-room 36 36
game-towers 20 20
knock-node 50 50
knock-physics 76 + 2.14 red 76 + 2.14 red (already failing on base)

No core code changed, so the held suites stay at their base counts. svelte-check is 341 errors / 47 warnings with the same list as the base, and the build passes.

Findings (core, not fixed here)

  • Two peers can both run the physics simulation. If both press Play inside the sim's start-up window, both pass maybeSimOnPlay's "is a sim already running?" guard before the other's simulate message lands, so both simulate. After B's hit, B sent the ball about 74 moves in 2 s; on A the ball then sat under a permanent hold: external, applyThrow snapped back, and no goal could score. The suite enters Play in order and asserts check 2.2b (B does not start a second simulation). This needs a ticket: a peer that receives simulate while it is simulating should yield by a deterministic rule.
  • P pauses everyone. In the Football template the P pause menu is session-wide, because the Key Press pulse replicates. Check 3.10 asserts that behaviour as it is.

Owed

  • The headset half of the football flight (VR hands, the physical buttons by ray, a colocated match).

🤖 Generated with Claude Code

… real zip

- tests/e2e/game-football.test.cjs: loads games/football/scene.tpscene from the scenes
  FEED (SCENES_BASE, tag v2; FOOTBALL_TPSCENE or a sibling scenes checkout as fallbacks)
  and installs the REAL football.zip (FOOTBALL_ZIP, a packed sibling modules checkout, or
  the modules CDN) on two peers plus a late joiner. Skip-never-fail: an unreachable scene
  or zip prints the reason and exits green.
- covers the modules test-flight's cases on the file: the world and its physics block,
  joining through a real HUD button click AND the physical button's click path, Start ->
  the playing HUD, the P menu (open / Resume), B's hit -> lastTouch on both + A's hit log,
  a blue goal credited to B's own row only, lamps + DOM HUD score, an own goal, own goals
  ignored, duel refusing a second red, the late joiner mid-match (score, slots, playing
  HUD via showWhile, its own live knock), time mode ending the match for all three, the
  over screen, the saved log, New match back to menu.
- game-shell transitions asserted on the TRIGGER LOG (evstart / evover / evnew stamps),
  never on a perRound flowValue.
- counterfactuals: an untouched ball into the red gate scores for blue and credits NOBODY
  (4.12/4.13, in-suite); C with remoteSimulating cleared has a dead probe (5.8, in-suite,
  restored); the handshake `simulate` push disabled in peerHandler -> 5.3 and 5.8 RED
  (C is never told, and in fact starts its own second sim), restored -> green.
- FINDINGS recorded, not fixed (outside this lane): (1) a DUAL-SIMULATOR race - two Play
  presses inside the sim start-up window both pass maybeSimOnPlay's guard, both peers
  simulate, and the ball is fought over forever (a parked ball snapped back under a
  permanent `hold: external`, no goal could score); the suite enters Play in order and
  asserts 2.2b. (2) the template's P pause menu is session-wide (the keypress pulse
  replicates), asserted as-is in 3.10.
- suite: 102 PASS / 0 FAIL in 71s. held suites at base: game-stars-room 36, game-towers
  20, knock-node 50, knock-physics 76 + its base red 2.14 (no core code changed).
- svelte-check 341 errors / 47 warnings, list identical to base; build green.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@AlexZ005
AlexZ005 merged commit 32df7d4 into release/next Sep 19, 2026
4 checks passed
@AlexZ005
AlexZ005 deleted the feat/29-football-suite branch September 19, 2026 20:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant