feat(games): implement blackjack game plugin with manual start and custom payouts
Some checks failed
Deploy to Production / test (push) Failing after 39s

Adds a full blackjack game with dealer AI, hit/stand/double-down actions,
and per-player payout multipliers (house-edge model). Extends the game
framework with manualStart support and a START_GAME WebSocket message so
hosts can begin when ready. Generalizes bet settlement transaction
descriptions from chess-specific to game-agnostic.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
syntaxbullet
2026-04-05 18:48:25 +02:00
parent f368da9e73
commit ef78a85b9c
67 changed files with 16234 additions and 20 deletions

View File

@@ -171,5 +171,9 @@ export function useGameRoom(roomId: string, userId: string, role?: string, prefe
send({ type: "FILL_ROOM", roomId });
}, [roomId, send]);
return { ...state, sendAction, leaveRoom, rejoin, fillRoom };
const startGame = useCallback(() => {
send({ type: "START_GAME", roomId });
}, [roomId, send]);
return { ...state, sendAction, leaveRoom, rejoin, fillRoom, startGame };
}