fix player leaving in his turn with empty lobby
This commit is contained in:
parent
ce506e90ed
commit
41ca3b2747
@ -183,6 +183,7 @@ class Game:
|
|||||||
self.players[self.turn].play_turn()
|
self.players[self.turn].play_turn()
|
||||||
|
|
||||||
def next_turn(self):
|
def next_turn(self):
|
||||||
|
if len(self.players) > 0:
|
||||||
self.turn = (self.turn + 1) % len(self.players)
|
self.turn = (self.turn + 1) % len(self.players)
|
||||||
self.play_turn()
|
self.play_turn()
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user