medgelabs / gomr

Game of Go
0 stars 0 forks source link

Figure out backend solution #5

Closed rjmontgo closed 4 years ago

rjmontgo commented 4 years ago

We need to determine how our backend will interact with the frontend to manage the state between rooms and secondarily how to allocate users to a room.

I'm thinking the best approach would be to have a single backend server that can pass game state to get something working. Then expand on that to figure out how to have multiple rooms with games running in them.

MatthewEdge commented 4 years ago

Agreed. If we have some kind of "create room" screen on the FE then we could do a POST /room/{id} which would create a new game state, and provide a link for them to give to someone to join? Something like /room/{id}/join?key=laksdhgahghea;hgiaol;h which could act as a very simple auth strat. Once two players are connected - lock the room to the two players?

We could also ask for account creation and lock it that way, as well. It wouldn't be as ideal but could also prevent spambots