Commit Graph

212 Commits

Author SHA1 Message Date
Brian Fertig d6d7bc818b Game Icon Update 2026-05-31 20:39:55 -06:00
Brian Fertig df976b572a Added glow effect on Mastermind pegs 2026-05-31 20:28:40 -06:00
Brian Fertig aa9a3a0f6c feat: add Blokus board game with heuristic AI and Phaser UI
- Implement pure state engine for Blokus rules, move generation, and scoring
- Add board geometry, polyomino definitions, and orientation transforms
- Integrate heuristic single-ply AI with 5 skill levels (configurable noise/blunders)
- Create Phaser scene for board rendering, piece tray, ghost placement, and HUD
- Register game in server registry and update client routing/dispatch
2026-05-31 20:16:21 -06:00
Brian Fertig 2c0c7d7145 Icons and Old Maid Updates 2026-05-31 19:41:57 -06:00
Brian Fertig 57c0a55710 feat: use sprite sheet for Old Maid card rendering
- Replace custom-drawn Old Maid card with sprite frame (frame 13)
- Load oldmaid-cards.png spritesheet in PreloadScene
- Rename GOFISH_CARD_FRAME to OLDMAID_CARD_FRAME for clarity
2026-05-31 19:21:09 -06:00
Brian Fertig 2bb4d14c97 feat: add Old Maid card game
- Implement core game logic, AI opponent with skill scaling, and Phaser UI
- Register game in server registry and wire into app routing
- Add card assets and sprites
2026-05-31 19:14:30 -06:00
Brian Fertig da0dc25cdd feat: add game icons to menu and animated dock arrows to Battleship
- Replace `gameicons` spritesheet with `game-icons` and load it in PreloadScene
- Add `iconFrame` support to game registry and render icons next to menu buttons
- Introduce animated dock arrows in Battleship to improve ship placement UI
- Clean up arrow lifecycle management in Battleship scene
2026-05-31 18:25:32 -06:00
Brian Fertig 63df39442c feat: add Boggle word game with AI opponents and board solver
- Implement full Boggle frontend using Phaser, featuring a wooden tray UI, player word sheet, opponent cards, and an animated hourglass timer.
- Add AI scheduling system that simulates opponent word finds based on configurable skill levels and word length/rarity weighting.
- Introduce pure game logic for adjacency validation, path checking, and classic scoring with duplicate-word resolution.
- Add backend board generation and exhaustive solver using a dictionary trie, exposing `/api/words/boggle/start` for board setup.
- Register Boggle in the game registry, scene router, and opponent selection UI.
- Include tutorial assets for Parchisi.
2026-05-31 15:17:00 -06:00
Brian Fertig f5e74d7970 Tutorials 2026-05-31 13:54:32 -06:00
Brian Fertig 588925e564 feat: add Connect 4 game and image support to tutorial modal
- Register Connect 4 in server registry and frontend game config
- Add Connect 4 to slug dispatch and opponent select skill controls
- Update TutorialModal markdown parser to render embedded images
2026-05-31 13:39:00 -06:00
Brian Fertig f83b8e72e9 Text alignment 2026-05-31 13:11:22 -06:00
Brian Fertig 651ef51633 fix: adjust Battleship UI layout and positioning
Repositions ship pips and placement buttons to prevent overlap and improve visual alignment. Updates Y-coordinates for Randomize, Clear, and Ready buttons to fit within the game area, and shifts ship labels left for better spacing.
2026-05-31 13:01:05 -06:00
Brian Fertig 81d3a28195 fix: exclude Mastermind and Battleship from playfield selection
Prevents the playfield option section from appearing for Mastermind and Battleship games, which do not utilize playfield tiles in the same way as other games.
2026-05-31 12:52:16 -06:00
Brian Fertig 0bb32359b2 feat(mastermind): add Exact Placement scoring mode
Introduces a per-peg feedback system where each marker corresponds to the specific slot's result (exact, partial, or none) instead of aggregate counts. Added `scoreGuessPerPeg` logic, updated UI rendering and sound triggers to handle per-peg data, and added a scene toggle for switching between Standard and Exact Placement modes.
2026-05-31 12:44:38 -06:00
Brian Fertig 2c5bcbd478 Backgammon Tutorial 2026-05-31 12:22:51 -06:00
Brian Fertig 99497e19fa Backgammon Tutorial 2026-05-31 11:53:40 -06:00
Brian Fertig 0c416f362b feat(mastermind): improve UI layout and enhance peg reveal animation
- Relocate Leave button to the bottom of the game screen
- Extend peg reveal animation duration to 2.3s with smoother tick timing
- Introduce MASTERMIND_CALCULATE sound effect to play during the reveal
- Update audio preload and SFX registry to support the new sound
2026-05-31 10:19:42 -06:00
Brian Fertig 13b9d0d1cc Turn arrow placement 2026-05-31 10:01:18 -06:00
Brian Fertig 676a4d3106 feat: add Mastermind decryption duel game with 5 AI skill levels
- Introduce core game logic, AI engine, and Phaser UI for a cyberpunk-themed Mastermind implementation.
- AI features 5 difficulty tiers using random, consistent, and Knuth minimax strategies.
- Implement turn-based duel mechanics where player and AI race to crack each other's secret codes.
- Add neon visuals, peg-fly animations, staggered feedback reveals, and 7 custom sound effects.
- Register game in server registry, update menu/room scenes, preload assets, and include tutorial docs.
2026-05-31 09:53:37 -06:00
Brian Fertig b0d6817c54 Rounded Tutorial Buttons 2026-05-31 08:24:35 -06:00
Brian Fertig 98e799bf25 feat: add tutorial modal system and register battleship game
- Introduce `hasTutorial` flag to game registry
- Add "?" button on game menu to open tutorial modals
- Implement shared hover tooltip on game menu
- Add tutorial modal CSS styling
- Register Battleship game with tutorial flag
- Load Battleship sound effects
2026-05-31 00:04:01 -06:00
Brian Fertig 84cf864fd9 chore(ticket-to-ride): Refine US land outline and Great Lakes shapes
Hand-trace a more accurate US lower-48 + southern Canada outline with additional
points for Pacific NW, Great Lakes, Florida, and Gulf Coast. Update GREAT_LAKES
polygon to better match actual geography.
2026-05-30 21:15:01 -06:00
Brian Fertig a932cc5797 feat(ticket-to-ride): Support curved routes with quadratic bezier curves
Introduce `ROUTE_CURVES` configuration and helper functions (`bezierPolyline`,
`polylineLength`, `pointAtDist`) to sample and measure polylines. Update
`routeSegments` and `routeMidpoint` to distribute cars and calculate midpoints
along curved paths instead of straight lines, improving board visual fidelity
and route alignment.
2026-05-30 20:49:20 -06:00
Brian Fertig b6d85e30be feat: improve Go Fish AI with card sprites and turn exclusions
- Add custom card texture spritesheet and render cards using sprite frames
- Prevent AI from repeatedly asking for the same rank after a failed catch
- Track and exclude previously attempted (target, rank) pairs per turn to reduce redundant moves
- Load gofish-cards assets in preload scene
2026-05-30 19:28:48 -06:00
Brian Fertig 618d3d31c4 feat: add Othello and Go games with AI and Phaser UI
- Implement pure game logic for Othello (8x8) and Go (9x9)
- Add configurable AI opponents (skill 1-5) using heuristic look-ahead and alpha-beta minimax
- Build Phaser scenes with polished UI, stone/disc rendering, capture/flip animations, territory scoring, and end-game panels
- Register games in server registry and update client routing, opponent selection, and scene registration
2026-05-30 18:59:48 -06:00
Brian Fertig 8ccb100678 feat: add single-player Sudoku game with hints and scoring
- Implement Phaser UI and client-side logic for gameplay
- Add server-side puzzle generator with 5 difficulty levels
- Register game in frontend router and backend registry
- Include hint system, score calculation, and notebook-themed design
2026-05-30 18:05:40 -06:00
Brian Fertig fcc061e43d Added VP coins to Dominion 2026-05-30 17:18:37 -06:00
Brian Fertig eca8013fd4 feat: polish Ticket to Ride visuals and add animated game menu tabs
- Introduce muted palette and stroke outlines for unclaimed route segments so claimed routes pop
- Refactor busy state handling to toggle dim overlay and suppress hand render flicker during animations
- Improve modal layout using right-band centering, responsive font sizing, and word wrapping
- Block input briefly after modal close to prevent accidental clicks
- Add animated tab icons to the game menu with scale transitions and pulsing glow effects
- Load new tab-icons assets in the preload scene
2026-05-30 15:09:03 -06:00
Brian Fertig 2521146579 feat: replace route cars with animated train car sprites and card animations
- Generate a `ttr-train-car` texture and use images instead of procedural drawing for owned routes.
- Add `animateClaimRoute` to animate cards flying from hand to a lineup, transforming into train cars, then placing on the route.
- Update human and AI route claim flows to use the new animation.
- Add a pulsing turn indicator triangle that moves to the current player's portrait.
- Track `trainCarObjs` for proper cleanup during route re-renders.
2026-05-30 13:41:14 -06:00
Brian Fertig 97befdb502 feat: add market card sliding and refill animations to Ticket to Ride
- Implement `animateMarketSlideUp` to slide remaining cards up when one is drawn.
- Add `animateRefillMarketSlot` to animate a new card appearing from the deck.
- Update human and AI draw handlers to orchestrate card draw, slide, and refill animations.
- Introduce `marketSlotObjs` to track UI objects per slot for targeted tweens.
- Create `renderAllExceptMarket` to render the rest of the game while market animations play.
- Refactor `renderMarket` to group objects by slot index.
2026-05-30 13:17:49 -06:00
Brian Fertig ae6c69e25c feat: add opponent hand visualization and update AI draw animations
- Introduce mini face-down card fans below opponent portraits to show hand size.
- Modify AI draw animations to target specific slots within the mini hand fan.
- Adjust layout constants (OPP_STEP) and text positions to accommodate the new UI.
- Simplify opponent info text to remove redundant card counts.
2026-05-30 12:52:41 -06:00
Brian Fertig 402293fea2 feat: add cinematic card drawing animations to Ticket to Ride
- Implement `animateCardDraw` with a multi-phase animation: flip, fly to center,
  fireworks particle effect, and fly to destination.
- Update human market and deck click handlers to play animations when drawing cards.
- Add card draw animations for AI turns, flying cards to opponent positions.
- Refactor turn logic to await animations before advancing game state.
- Add `handDestForColor` helper for calculating hand layout positions.
2026-05-30 12:41:27 -06:00
Brian Fertig 8222b61f0a feat: upgrade Ticket to Ride UI with card sprites and improved layout
- Replace procedural card drawing with spritesheet images for better visuals
- Rotate cards to landscape orientation and adjust right-panel dimensions
- Reorganize opponent panels into a two-column grid for better screen utilization
- Add circular score badges above player and opponent portraits
- Display actual top card on discard pile instead of generic face-down graphic
- Move game log to bottom-right corner
- Update PreloadScene to load new card assets
2026-05-30 12:05:20 -06:00
Brian Fertig 975d40b4b0 refactor: overhaul game menu layout, enhance Button component, and adjust Dominion AI
- Replace column-based game list with a tabbed category interface and grid layout
- Add active state management to tabs and refactor Button component for consistent visual states
- Increase Dominion AI Platinum purchase threshold from 5 to 9 coins in Colony games
- Add Ticket to Ride card assets
2026-05-30 10:47:50 -06:00
Brian Fertig 2dbcb83754 feat: add single-player Hangman game with difficulty levels
- Implement Hangman game scene using Phaser with a sketch/paper-style UI
- Add pure logic module for word masking, wrong guess tracking, and win/loss conditions
- Create backend `/api/words/hangman/start` endpoint with curated word pools for easy, medium, and hard difficulties
- Register game in scene manager and route dispatcher for seamless menu integration
- Add score tracking and basic game state management
2026-05-30 08:50:44 -06:00
Brian Fertig d9a68de8e4 feat: add Ticket to Ride (USA edition) game
Implement a fully playable Ticket to Ride game featuring a pure logic engine,
heuristic AI opponent, and Phaser UI scene.

Key additions:
- Board geometry, route definitions, destination tickets, and train card data
- State management, turn flow, payment validation, and scoring (routes, tickets, longest path bonus)
- AI decision-making for claiming routes, drawing cards/tickets, and endgame strategy
- Frontend integration (scene registration, opponent count default, slug dispatch)
- Server game registry configuration (supports 2-5 players)

Follows the existing architecture separating data, logic, AI, and rendering.
2026-05-30 08:01:02 -06:00
Brian Fertig 2958de16ce fix(catan): correct ship placement to use edge coordinates
fix(dominion): increase Platinum cost in Prosperity expansion

- Update Catan ship placement logic to calculate destination using edge positions like roads
- Adjust Dominion Prosperity expansion Platinum card cost from 5 to 9 coins for balance
2026-05-30 06:57:10 -06:00
Brian Fertig 9dbf3feae4 feat(catan): implement Seafarers expansion features (gold hexes, ships, fog)
- Add gold hex resource picking phase with AI support
- Implement ship building mechanics and update build costs UI
- Introduce fog tiles that reveal terrain when roads/ships are built adjacent
- Replace robber token with pirate ship graphic
- Persist random tile frames for consistent hex visuals
- Update game state machine to handle gold pick queue and phase transitions
- Adjust UI layout (card positions, build panel) to accommodate Seafarers elements
2026-05-29 16:13:53 -06:00
Brian Fertig c5f34b7c28 feat(catan): implement Seafarers expansion and dynamic board architecture
- Decouple static board geometry from game state by introducing a board registry and `geoFor(state)` accessor. All AI and logic functions now dynamically resolve topology.
- Add support for Seafarers scenarios (New Shores, Four Islands, Oceania, Fog Island) with scenario-specific setup rules and victory conditions.
- Implement ship mechanics: players build maritime routes on coastal/sea edges that count toward the longest road.
- Introduce sea, gold, and fog terrain types. Update hex rendering, AI pathfinding, and placement rules to respect land vs. water constraints.
- Add pirate token rendering and logic, plus expansion scoring hooks for bonus victory points.
- Update lobby UI to allow expansion and scenario selection, passing configuration through to the game scene.
- Refactor `CatanBoard.js` geometry generation for O(1) edge lookups and dynamic port assignment.
2026-05-29 15:06:20 -06:00
Brian Fertig 2c95e76b00 Added Prosperity 2026-05-29 10:29:13 -06:00
Brian Fertig 57eeb3bfee feat: add Word Search game and improve solo game flow
- Integrate Word Search game into client and server registries
- Add API endpoints for puzzle generation and theme listing
- Update GameMenuScene to skip opponent selection and stop menu music for solo-only games
2026-05-29 08:21:48 -06:00
Brian Fertig 47885bab01 Game updates 2026-05-28 21:01:28 -06:00
Brian Fertig 371724dc84 feat: add Ghost word game with server-side AI and skill profiles
- Implement client and server logic for Ghost game (`GhostGame`, `GhostLogic`, `GhostAI`, `ghostEngine`).
- Add perfect-play search and 5-tier skill system to the server-side dictionary engine.
- Register Ghost in the game registry and route it through `GameRoomScene`.
- Add `playIntro` option to `Portrait.js` and `skipIntro` to Wordle to control intro speeches on round restarts.
- Improve Scrabble rack reordering layout and gap handling during drag-and-drop.
- Expose Ghost API endpoints (`/ghost/judge`, `/ghost/ai-move`) in `wordRoutes.js`.
2026-05-28 19:05:36 -06:00
Brian Fertig dd384d6c15 New music tracks 2026-05-28 00:02:32 -06:00
Brian Fertig 95ff6f8de2 feat: add Scrabble game with client-server AI and Phaser UI
- Implement `ScrabbleGame` scene with drag-and-drop, rack management, and animated tile placement.
- Add pure JS modules for Scrabble rules, scoring, and tile data (`ScrabbleLogic`, `ScrabbleTiles`).
- Create server-side dictionary trie and DFS-based move generator for AI (`scrabbleEngine`).
- Register game routes for move validation and AI move requests (`wordRoutes`).
- Update game registry, opponent selection, and preload scenes to support Scrabble.
- Include custom font (`YummyCupcakes`) for the scorepad UI.
2026-05-27 23:54:02 -06:00
Brian Fertig 17133787c1 refine wordle AI balance, add Catan tutorial, fix opponent select layout, enable word category
- Adjust Wordle AI skill profiles to lower win rates and increase blunder chances for better difficulty curve
- Center Wordle player portrait vertically with the playfield
- Add Steve's humorous tutorial for Settlers of Catan (markdown + assets)
- Update OpponentSelectScene to hide playfield options for word games and adjust scroll height
- Fix migration script to temporarily disable foreign keys to allow schema changes
- Add migration to extend games.category to include 'word'
2026-05-27 23:22:15 -06:00
Brian Fertig 690d05b28d feat: add Wordle game support and word routes
- Register Wordle game in server registry under 'word' category
- Add `/api/words` API routes
- Update client to integrate WordleGame scene
- Adjust game menu layout to accommodate a new 'Word' category column
- Enable skill controls and game room dispatch for Wordle
2026-05-27 21:14:31 -06:00
Brian Fertig 33bbeff79b feat: enhance card animations and improve icon row fitting
- Add `_animPurchaseShowcase` for a dramatic card reveal with a dark overlay and animated comet border effect
- Refactor purchase and gain flows to use the new showcase animation before flying the card to its destination
- Update `addIconRow` to accept a width constraint, dynamically scale text/tokens, and fallback to colored bars when space is too limited
2026-05-27 19:33:30 -06:00
Brian Fertig ca38548700 feat(dominion): add animated deck/discard counters and refine turn SFX
- Track deck/discard pile counts during animations for real-time UI updates
- Implement animated discard pile countdown when shuffling
- Dynamically show/hide deck and discard piles based on animation state
- Replace generic card SFX with specific sounds for buying treasures, purchasing, and dealing
- Update Dominion card assets to align with new UI/audio feedback
2026-05-27 18:53:30 -06:00
Brian Fertig 0536a261f6 feat(dominion): add sparkle particles and coin sound to supply piles
- Add a particle emitter effect to supply pile cards using a generated sparkle texture.
- Include a `coins.mp3` sound effect for purchase interactions.
- Implement `_clearSupplyFx` to manage emitter lifecycle during render cycles.
2026-05-27 17:58:58 -06:00