remove sync that no longer happens oops
This commit is contained in:
parent
658634c0db
commit
fb6f99e7b0
4
game.go
4
game.go
@ -58,10 +58,6 @@ func gameActor(ctx context.Context, g *game.Match, dealer, chall person, join <-
|
||||
// definitely expired.
|
||||
ctx, stop := context.WithTimeoutCause(ctx, 4*time.Hour, errMatchExpired)
|
||||
defer stop()
|
||||
// Accept joins from the dealer and challenger. We don't care which is
|
||||
// which, but we need to get both to synchronize the socket.
|
||||
<-join
|
||||
<-join
|
||||
var obs []observer
|
||||
actions := make(chan action, 2)
|
||||
go playerActor(ctx, dealer, actions)
|
||||
|
@ -195,11 +195,9 @@ func (s *Server) joinAndServe(p person) {
|
||||
return
|
||||
}
|
||||
if deal {
|
||||
ch := make(chan person, 2)
|
||||
g := game.New(p.id, chall.id)
|
||||
<-chall.sync
|
||||
go gameActor(context.TODO(), g, p, chall.person, ch)
|
||||
ch <- p
|
||||
go gameActor(context.TODO(), g, p, chall.person, nil)
|
||||
}
|
||||
// Reply with the game ID so they can share.
|
||||
r := serve.GameStart{
|
||||
|
Loading…
Reference in New Issue
Block a user