Please enable JavaScript.
Coggle requires JavaScript to display documents.
Real Time Gaming Hub - Coggle Diagram
Real Time Gaming Hub
USERS
- User can create Room
- User can join a Room
- User will see his score total and his rank
-
Model
- Username
- Password
- Rooms List
- Score Total
- Rank
ROOMS
- User will create a room and room code will be generated for the room
- User can search room by room code and join the room
- Only 1 player will be allowed to join the room
-
MODEL
- Room Name
- Room Code
- Players List
- Game
- Status
- Winner
- Created On
GAME
- Game logic will be written on frontend
- Seperate pages will be created for both the games
SOCKETS
USER JOIN
- Emit playerJoined (backend)
2, Listen playerJoined (frontend)
- Emit join-room (frontend)
Asking if user ready
- Emit isReady from Creator
- Listen isReady from User
- Emit ready from User
-
-
Actions
- Emit action along with the action taken
(For example - in pig game, user 1 drawn 6, then on emit action, 6 will be send to the backend)
- Listen action from backend
- Emit actionTaken from backend
- Listen actionTaken from user2
Game Over
- Emit gameOver from backend along with
winner name and scores
-