Hand: select() update - Fix holecards for holdem
This commit is contained in:
parent
d94f7a68a2
commit
2382152cb8
|
@ -309,9 +309,15 @@ db: a connected Database object"""
|
||||||
#print "DEBUG: addPlayer(%s, %s, %s)" %(seat,name,str(chips))
|
#print "DEBUG: addPlayer(%s, %s, %s)" %(seat,name,str(chips))
|
||||||
self.addPlayer(seat,name,str(chips))
|
self.addPlayer(seat,name,str(chips))
|
||||||
#print "DEBUG: card1: %s" % card1
|
#print "DEBUG: card1: %s" % card1
|
||||||
cardlist = map(Card.valueSuitFromCard, [card1, card2, card3, card4])
|
# map() should work, but is returning integers... FIXME later
|
||||||
cardlist = [card1, card2, card3, card4]
|
#cardlist = map(Card.valueSuitFromCard, [card1, card2, card3, card4])
|
||||||
|
cardlist = [Card.valueSuitFromCard(card1), Card.valueSuitFromCard(card2), Card.valueSuitFromCard(card3), Card.valueSuitFromCard(card4)]
|
||||||
#print "DEUBG: cardlist: '%s'" % cardlist
|
#print "DEUBG: cardlist: '%s'" % cardlist
|
||||||
|
if cardlist[0] == '':
|
||||||
|
pass
|
||||||
|
elif self.gametype['category'] == 'holdem':
|
||||||
|
self.addHoleCards('PREFLOP', name, closed=cardlist[0:2], shown=False, mucked=False, dealt=True)
|
||||||
|
elif self.gametype['category'] == 'omaha':
|
||||||
self.addHoleCards('PREFLOP', name, closed=cardlist, shown=False, mucked=False, dealt=True)
|
self.addHoleCards('PREFLOP', name, closed=cardlist, shown=False, mucked=False, dealt=True)
|
||||||
if winnings > 0:
|
if winnings > 0:
|
||||||
self.addCollectPot(name, str(winnings))
|
self.addCollectPot(name, str(winnings))
|
||||||
|
|
Loading…
Reference in New Issue
Block a user