def isDone(self, game):
""" returns whether the game is over, with a win/lose flag """
from pygame.locals import K_ESCAPE, QUIT
if game.keystate[K_ESCAPE] or pygame.event.peek(QUIT):
return True, False
else:
return False, None
# This needs to go at the bottom so that classes in core are already loaded
评论列表
文章目录