You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
make roomManager class and other required classes (Player, Room)
make web route to create new room and send code as response
Example
// RoomManager.tsxclassRoomManager{rooms: Room[]=[];// orrooms=newMap<string,Room>();create(): string{// generate new unique code// create room assign to this.rooms// return code}}// it will be our manager, routes have to use this instance of classexportconstmanager=newRoomManager()
// webRoutes.tsxwebRouter.get("/create",(req,res)=>{// create new room// response with code of created room})
The text was updated successfully, but these errors were encountered:
make roomManager class and other required classes (Player, Room)
make web route to create new room and send code as response
Example
The text was updated successfully, but these errors were encountered: