fix interrupt
This commit is contained in:
2
Game.py
2
Game.py
@@ -13,7 +13,7 @@ class Game:
|
|||||||
signal.signal(signal.SIGINT, self.interrupt)
|
signal.signal(signal.SIGINT, self.interrupt)
|
||||||
self.is_running = asyncio.Condition()
|
self.is_running = asyncio.Condition()
|
||||||
|
|
||||||
def interrupt(self):
|
def interrupt(self, _, __):
|
||||||
logging.info('Received SIGINT. Stopping Game :-)')
|
logging.info('Received SIGINT. Stopping Game :-)')
|
||||||
self.is_running.release()
|
self.is_running.release()
|
||||||
|
|
||||||
|
|||||||
@@ -282,7 +282,7 @@ class PlayerState:
|
|||||||
def addPoints(self, points):
|
def addPoints(self, points):
|
||||||
if points == 0:
|
if points == 0:
|
||||||
return
|
return
|
||||||
|
|
||||||
if not self.isActive:
|
if not self.isActive:
|
||||||
return
|
return
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user