Skip to content

Scribble assignment - Zakila Banu#122

Open
zakilabanu wants to merge 5 commits into
everest-engineering:mainfrom
zakilabanu:scribble-lab
Open

Scribble assignment - Zakila Banu#122
zakilabanu wants to merge 5 commits into
everest-engineering:mainfrom
zakilabanu:scribble-lab

Conversation

@zakilabanu

@zakilabanu zakilabanu commented Jun 10, 2026

Copy link
Copy Markdown

Summary

Implemented the core multiplayer drawing game flow covering room management, gameplay, scoring, and restart functionality.

Room Setup & Lobby

  • Added room creation and join flows using unique room codes.
  • Automatically assign the room creator as the host.
  • Added validation and user feedback for invalid or empty room codes.
  • Ensured room isolation so players only interact with participants in their own room.
  • Implemented lobby polling (~2s) to keep participant lists synchronized.
  • Restricted game start functionality to the host and enforced a minimum of two players before starting.

Game Start & Drawer Flow

  • Added player name validation with trimming and rejection of empty/whitespace-only names.
  • Implemented game start flow with deterministic word selection from the starter word list.
  • Assigned the first player/host as the drawer for the initial round.
  • Displayed the secret word exclusively to the drawer.
  • Added clear visual identification of the active drawer.

Gameplay Interaction

  • Implemented drawing and canvas clear functionality for the drawer.
  • Synchronized guess history across players through polling.
  • Added guess validation with trimming and rejection of empty submissions.
  • Implemented case-insensitive guess matching.
  • Added scoring logic awarding 100 points for correct guesses and 0 points for incorrect guesses.
  • Initialized all player scores to zero at the start of the game.

Results & Restart

  • Added result screen displaying:

    • Correct word
    • Final scores
    • Complete guess history
  • Implemented host-controlled game restart functionality.

  • Preserved room participants on restart while clearing all round-specific state.

  • Returned all players to the lobby after restart.

Validation

  • Verified end-to-end multiplayer flow including room creation, joining, gameplay, scoring, result display, and restart behavior.
  • Confirmed polling-based synchronization and room isolation across concurrent rooms.

Contributor

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant