Improve Gym Deck & Seeded RNG scene: full deck grid + browser tests (CG-0MPLT8ADR0099WF3)#588
Merged
SorraTheOrc merged 5 commits intoMay 26, 2026
Conversation
added 5 commits
May 26, 2026 00:12
…ard deck face-up in compact grid - Replace single-card draw/flip/deal/reset UI with full-deck grid display - All 52 cards rendered face-up in 8-column grid on scene load - Keep seed adjustment controls and shuffle button; remove Draw/Flip/Deal/Reset buttons - Remove event log; replace with simple status display - Cards positioned using SLL cardDisplay zone anchors - Cards scaled to 0.7x to fit 8-column grid within viewport - Update GymRegistry description to reflect new scene behavior - Update tests: remove Draw/Flip/Deal-specific tests, add full-deck and shuffle determinism tests
…s for AC 9 - Fixed critical bug: this.deck was never populated before renderFullDeckGrid() was called in create(), resulting in 0 cards displayed on scene load. - Added this.deck = createStandardDeck() before renderFullDeckGrid() in create(). - Added GymDeckRngScene.browser.test.ts with 6 browser tests: - 52 card sprites rendered on load (AC 1, 6) - Removed controls absence (AC 2) - Seed controls present, event log absent (AC 4, 5) - Shuffle clears and redraws 52 cards (AC 3) - Seed adjustment controls modify seed value (AC 4) - Same seed determinism reproduces identical arrangement (AC 3, 9) - All 2726 tests pass (2625 unit + 101 browser), 5 skipped
…n by 100px - Cards were too small at scale 0.7 (~33x46px) and too close to the header area (top row at y≈122 barely below controls at y≈83). - Increased cardScale from 0.7 to 0.85 giving ~41x55px cards with clearer face-up textures. - Shifted grid center Y from 270 to 370 (SLL anchor + 100) so the top row clears the header/controls area comfortably. - All 2726 tests continue to pass.
…huffle uses random seed - Initial deck rendering now shuffles with the default seed (42) instead of displaying cards in unshuffled standard order. - Shuffle button generates a random seed (0-99999) and updates the seed display so the user can reproduce the arrangement. - +/- and Reset Seed buttons now automatically re-shuffle and re-render the deck with the adjusted seed value. - Updated help text to reflect new behavior. - Updated browser determinism test to use +/- auto-shuffle instead of Shuffle (which is now random). - All 2726 tests pass.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Goal
Reimplement the GymDeckRngScene to display all 52 cards face-up in a compact grid with deterministic seeded RNG shuffle, and add scene-level browser tests to validate visual behavior.
Changes
Bug fix (critical)
New browser tests (tests/gym/GymDeckRngScene.browser.test.ts) — 6 tests
How to test
Browser tests
Full suite
Review focus
Closes: CG-0MPLT8ADR0099WF3