How locitanit/ket-igaz-egy-hamis works
Két igaz, egy hamis is a real-time classroom party game. The main workflow is creating or joining a room, submitting shuffled statements, waiting for the host to start, voting on each player’s lie, then revealing answers and displaying scores. Firebase Realtime Database carries shared room state; live updates keep players’ views synchronized. The app also documents room reconnection and an admin room-wipe capability. The source excerpt is partial, so links for voting, final ranking, and some view updates rely on the README’s documented behavior rather than inspected implementation details.
Main entry points: index.html Single-page shell · app.js Room live sync · style.css Game styling
Components 16
Entry and rooms
- Create or join
app.js - Room lifecycle
app.js - Admin wipe
app.js
Game stages
- Statement submission
app.js - Submission lobby
app.js - Turn ordering
app.js - Lie voting
app.js - Answer reveal
app.js - Scores and ranking
app.js
User interface
- Single-page shell
index.html - Game styling
style.css
Shared services
- Room live sync
app.js - Room data
- Firebase Realtime Database
- Reconnect storage
Other components
- Students and host
Connections 25
- Students and host → Single-page shell: use game
- Single-page shell → Create or join: submit room actions
- Create or join → Room data: check and create rooms
- Create or join → Room lifecycle: enter room
- Room lifecycle → Reconnect storage: save room code
- Room lifecycle → Room live sync: subscribe to room
- Room live sync → Room data: receive room updates
- Room live sync → Submission lobby: refresh room view
- Room live sync → Lie voting: refresh game view
- Single-page shell → Statement submission: submit statements
- Statement submission → Room data: write player data
- Submission lobby → Room data: read player submissions
- Single-page shell → Submission lobby: host starts game
- Submission lobby → Turn ordering: start with submitted players
- Turn ordering → Room data: write order and game state
- Single-page shell → Lie voting: cast vote
- Lie voting → Room data: write votes
- Single-page shell → Answer reveal: host closes and reveals
- Answer reveal → Room data: write reveal and scores
- Scores and ranking → Room data: read scores
- Scores and ranking → Single-page shell: display ranking
- Single-page shell → Admin wipe: enter admin code
- Admin wipe → Room data: delete all rooms
- Room data → Firebase Realtime Database: persist shared state
- Single-page shell → Game styling: apply styles