diff --git a/main.go b/main.go index 714e683..8aae7d0 100644 --- a/main.go +++ b/main.go @@ -37,6 +37,19 @@ func main() { } func registerForRandomGame(c *gin.Context) { + + /* + What should be done: + 1. Register player + 2. Check if there is a game open that lacks one player + 3. Fill open game, then respond with player id and game id. + OR + + 1. Register player + 2. If there is no open game, open a game and wait for a second player to join + 3. Only after a second player joins, respond with player id and game id. + */ + player := server.NewPlayer(uuid.New()) lobby := server.GetLobby()