Commit fc037ba8 authored by ceddral's avatar ceddral
Browse files

game: do not call state transitions on nil update

this is not currently an issue, since the only transition with
side effects is final scoring which is idempotent
parent f858bd66
......@@ -437,9 +437,10 @@ func (g *Game) Loop(p *GamePlayer, initState GameState) {
for {
select {
case newState := <-p.gameEvent:
if newState != nil {
state = newState
if newState == nil {
state = newState
if state.getAgent() == p {
} else {
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment