use game start dto that i already defined
This commit is contained in:
parent
e8a181a4f7
commit
23703dbe3e
@ -94,10 +94,9 @@ func (s *Server) joinAndServe(p person) {
|
|||||||
go gameActor(ctx, g, p, other, nil)
|
go gameActor(ctx, g, p, other, nil)
|
||||||
}
|
}
|
||||||
// Reply with the game ID so they can share.
|
// Reply with the game ID so they can share.
|
||||||
r := struct {
|
r := serve.GameStart{
|
||||||
Game lobby.GameID `json:"game"`
|
ID: id,
|
||||||
}{
|
Dealer: deal,
|
||||||
Game: id,
|
|
||||||
}
|
}
|
||||||
if err := wsjson.Write(context.TODO(), p.conn, r); err != nil {
|
if err := wsjson.Write(context.TODO(), p.conn, r); err != nil {
|
||||||
slog.WarnContext(ctx, "got a game but player dropped", "game", id, "player", p.id)
|
slog.WarnContext(ctx, "got a game but player dropped", "game", id, "player", p.id)
|
||||||
|
Loading…
Reference in New Issue
Block a user