-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(client): block UI until player connected and notify winner
Implement blocking of the UI board until both players are connected and notify the winner, blocking the board after the game is over. * **JoinGame.tsx** - Add state to track if both players have joined. - Add effect to block the board until both players have joined. - Update `bothPlayersJoined` event handler to set the state. - Update `Board` component to disable tile clicks until both players have joined. * **useJoinGame.ts** - Add state to track if the game is over. - Update `gameIsOver` event handler to set the state. - Add logic to block the board if the game is over.
- Loading branch information
Showing
2 changed files
with
14 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters