Feat: end turn endpoint
This commit is contained in:
@ -59,6 +59,17 @@ type Room struct {
|
||||
RedTurn bool // false is blue turn
|
||||
}
|
||||
|
||||
func (r *Room) ChangeTurn() {
|
||||
switch r.TeamTurn {
|
||||
case "blue":
|
||||
r.TeamTurn = "red"
|
||||
case "red":
|
||||
r.TeamTurn = "blue"
|
||||
default:
|
||||
r.TeamTurn = "blue"
|
||||
}
|
||||
}
|
||||
|
||||
type WordCard struct {
|
||||
Word string
|
||||
Color WordColor
|
||||
|
Reference in New Issue
Block a user