Public
Like
BlackJack
Val Town is a collaborative website to build and scale JavaScript apps.
Deploy APIs, crons, & store data – all from the browser, and deployed in milliseconds.
Viewing readonly version of main branch: v22View latest version
A fun Blackjack game implementation for Val Town with a twist - the "Booze" mechanic adds unpredictability to your gameplay!
- Classic Blackjack gameplay
- Interactive card UI
- "Booze" feature that increases your betting amount and adds randomness
- Responsive design
- Real-time score tracking
- Click "Start New Game" to begin
- Choose to "Hit" (get another card) or "Stand" (end your turn)
- Try to get as close to 21 as possible without going over
- Click "Booze Up" to increase your bet multiplier, but beware of random behavior!
- Frontend: React 18 with TypeScript
- Backend: Hono API framework on Deno
- Hosting: Val Town
- Standard Blackjack rules apply (Aces are 1 or 11, face cards are 10)
- Dealer must draw until they have at least 17
- The Booze feature increases your bet amount and may trigger automatic hits
├── backend/
│ ├── controllers/
│ │ └── gameController.ts # API endpoints
│ ├── models/
│ │ ├── Card.ts # Card interface
│ │ ├── GameState.ts # Game state interface
│ │ └── Player.ts # Player interface
│ ├── utils/
│ │ └── deckUtils.ts # Deck utilities
│ ├── gameEngine.ts # Game logic
│ └── index.ts # Backend entry point
├── frontend/
│ ├── components/
│ │ ├── App.tsx # Main app component
│ │ ├── BlackjackTable.tsx # Game table UI
│ │ ├── BoozeButton.tsx # Booze mechanic UI
│ │ ├── BoozeMeter.tsx # Booze level indicator
│ │ └── Scoreboard.tsx # Score tracking
│ ├── index.html # HTML template
│ └── index.tsx # Frontend entry point
└── README.md
Enjoy the game! 🃏 🍺
