Changed nextPlayer() call to happen after new animations
This commit is contained in:
3
game.py
3
game.py
@ -127,11 +127,12 @@ class Game(gameUtils.Game):
|
|||||||
if event.objectID == self.gun.objectID and event.animationID == 'spin':
|
if event.objectID == self.gun.objectID and event.animationID == 'spin':
|
||||||
self.timeout("FireDelay",random.randint(750,2000)/1000)
|
self.timeout("FireDelay",random.randint(750,2000)/1000)
|
||||||
self.playSound(self.gunCyclinderStop)
|
self.playSound(self.gunCyclinderStop)
|
||||||
|
elif event.objectID == self.gun.objectID and event.animationID in ['blank', 'fire']:
|
||||||
|
self.nextPlayer()
|
||||||
|
|
||||||
elif event.type == gameUtils.Timeout and event.timeoutID == 'FireDelay':
|
elif event.type == gameUtils.Timeout and event.timeoutID == 'FireDelay':
|
||||||
self.shockScale += self.fire() #check if the user gets shot
|
self.shockScale += self.fire() #check if the user gets shot
|
||||||
self.shockScale = min(self.shockScale, 1) #keeps shockScale in bounds
|
self.shockScale = min(self.shockScale, 1) #keeps shockScale in bounds
|
||||||
self.nextPlayer()
|
|
||||||
|
|
||||||
def update(self):
|
def update(self):
|
||||||
"""
|
"""
|
||||||
|
|||||||
Reference in New Issue
Block a user