Cards-Against-Humanity-Style Browser Game with Live Rooms
Real-time multiplayer party game where players match meme cards to funny prompts — a browser-based, no-download take on the Cards Against Humanity formula, with live rooms, a rotating judge, and full multi-language support.
Overview
Problem
Party games like this usually mean physical cards or a native app install — nothing lightweight that a group can jump into from a shared link, on any device, with state staying in sync for everyone in real time and surviving a dropped connection mid-round.
Approach
Split the game into two services: a Next.js client that renders a server-driven state machine (lobby → phrase_selection → picking → judging → result), and a standalone Socket.io/Express server that owns all game logic — room lifecycle, hand dealing, phase transitions, and validation of every action (is this player the judge? is it the right phase?). The client never trusts local state: a Zustand store is fully re-synced from the server's room_state broadcast after every change, with derived-state selectors (selectIsJudge, selectIsWinner) driving the UI. Reconnection is handled via a playerId + roomCode pair persisted in sessionStorage, so a dropped player can rejoin mid-game without losing their hand or score.
Stack
Outcomes
Build
Gallery
