Merge branch 'master' of git://github.com/kangaderoo/fpdb-kangaderoo
This commit is contained in:
commit
1c276915d8
|
@ -105,13 +105,20 @@ class PartyPoker(HandHistoryConverter):
|
||||||
|
|
||||||
def guessMaxSeats(self, hand):
|
def guessMaxSeats(self, hand):
|
||||||
"""Return a guess at max_seats when not specified in HH."""
|
"""Return a guess at max_seats when not specified in HH."""
|
||||||
mo = self.maxOccSeat(hand)
|
# Total number of players : 4/6
|
||||||
|
re_seats = re.compile("""Total\s+number\s+of\s+players\s+\:\s+\d+.{1}(?P<SEATS>\d+)""" , re.VERBOSE)
|
||||||
if mo == 10: return mo
|
try:
|
||||||
if mo == 2: return 2
|
m = re_seats.search(hand.handText)
|
||||||
if mo <= 6: return 6
|
mo = m.groupdict()
|
||||||
# there are 9-max tables for cash and 10-max for tournaments
|
mo = _mo['SEATS']
|
||||||
return 9 if hand.gametype['type']=='ring' else 10
|
return mo
|
||||||
|
except:
|
||||||
|
mo = self.maxOccSeat(hand)
|
||||||
|
if mo == 10: return mo
|
||||||
|
if mo == 2: return 2
|
||||||
|
if mo <= 6: return 6
|
||||||
|
# there are 9-max tables for cash and 10-max for tournaments
|
||||||
|
return 9 if hand.gametype['type']=='ring' else 10
|
||||||
|
|
||||||
def compilePlayerRegexs(self, hand):
|
def compilePlayerRegexs(self, hand):
|
||||||
players = set([player[1] for player in hand.players])
|
players = set([player[1] for player in hand.players])
|
||||||
|
@ -260,6 +267,7 @@ class PartyPoker(HandHistoryConverter):
|
||||||
for i,v in enumerate(self.collected):
|
for i,v in enumerate(self.collected):
|
||||||
if v[0] in self.pot.returned:
|
if v[0] in self.pot.returned:
|
||||||
self.collected[i][1] = Decimal(v[1]) - self.pot.returned[v[0]]
|
self.collected[i][1] = Decimal(v[1]) - self.pot.returned[v[0]]
|
||||||
|
self.collectees[v[0]] -= self.pot.returned[v[0]]
|
||||||
return origTotalPot()
|
return origTotalPot()
|
||||||
return totalPot
|
return totalPot
|
||||||
instancemethod = type(hand.totalPot)
|
instancemethod = type(hand.totalPot)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user