some endgame stuff
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
import config
|
||||
from Event import Event
|
||||
|
||||
from events.EndGameEvent import EndGameEvent
|
||||
@@ -31,8 +32,9 @@ class EndBallEvent(Event):
|
||||
self.scorePoints()
|
||||
self.gameState.currentPlayer.deactivate()
|
||||
|
||||
if self.gameState.currentPlayer.ballsLeft == 0:
|
||||
if self.gameState.currentPlayer.ballsLeft == 0 and self.gameState.currentPlayer.id == config.MAX_PLAYERS - 1:
|
||||
EndGameEvent().trigger(None)
|
||||
return
|
||||
|
||||
self.gameState.nextPlayer()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user