Chore: solved some todos
This commit is contained in:
@ -135,11 +135,14 @@ func HandleStartGame(w http.ResponseWriter, r *http.Request) {
|
||||
abortWithError(w, err.Error())
|
||||
return
|
||||
}
|
||||
// TODO: check if enough players; also button should be hidden if already running
|
||||
// check if enough players
|
||||
if err := fi.Room.CanStart(); err != nil {
|
||||
abortWithError(w, err.Error())
|
||||
return
|
||||
}
|
||||
fi.Room.IsRunning = true
|
||||
fi.Room.IsOver = false
|
||||
fi.Room.TeamTurn = "blue"
|
||||
// fi.Room.LoadTestCards()
|
||||
loadCards(fi.Room)
|
||||
fi.Room.UpdateCounter()
|
||||
fi.Room.TeamWon = ""
|
||||
|
Reference in New Issue
Block a user