more stable first-card drawing

This commit is contained in:
Jannes Höke 2016-05-21 18:56:27 +02:00
parent 73365f49fc
commit a02813477a

View file

@ -37,12 +37,10 @@ class Game(object):
def __init__(self, chat):
self.chat = chat
self.deck = Deck()
self.last_card = self.deck.draw()
self.last_card = None
while self.last_card.special:
self.deck.dismiss(self.last_card)
self.deck.shuffle()
while not self.last_card or self.last_card.special:
self.deck = Deck()
self.last_card = self.deck.draw()
self.logger = logging.getLogger(__name__)