Determine blind amounts from RINGLIMIT and max buyin
The previous method was giving wrong results in some cases (e.g. the preflop forced allin situation from blind positions), so here's an another enhancement. At PartyPoker there's two types of buyins for a cashgame table: 20BB min and 100BB max. The former has a 40BB max, while the latter has 35BB min too. This patch makes fpdb to determine if a ring table is a 20BB min or 100BB max table, then calculates the correct big blind amount from that. When big blind is ready then halves it for the small blind (except when big blind is 0.25$ when small blind is 0.10$).
This commit is contained in:
parent
5c76ec77d6
commit
31d3c37224
|
@ -96,8 +96,7 @@ class PartyPoker(HandHistoryConverter):
|
||||||
re_NoSmallBlind = re.compile(
|
re_NoSmallBlind = re.compile(
|
||||||
'^There is no Small Blind in this hand as the Big Blind '
|
'^There is no Small Blind in this hand as the Big Blind '
|
||||||
'of the previous hand left the table', re.MULTILINE)
|
'of the previous hand left the table', re.MULTILINE)
|
||||||
re_ringSB = re.compile(r"(?P<PLAYER>.*) posts small blind \[\$(?P<RINGSB>[.,0-9]*) USD\]\.")
|
re_20BBmin = re.compile(r"Table 20BB Min")
|
||||||
re_ringBB = re.compile(r"(?P<PLAYER>.*) posts big blind \[\$(?P<RINGBB>[.,0-9]*) USD\]\.")
|
|
||||||
|
|
||||||
def allHandsAsList(self):
|
def allHandsAsList(self):
|
||||||
list = HandHistoryConverter.allHandsAsList(self)
|
list = HandHistoryConverter.allHandsAsList(self)
|
||||||
|
@ -186,8 +185,7 @@ class PartyPoker(HandHistoryConverter):
|
||||||
|
|
||||||
info = {}
|
info = {}
|
||||||
m = self._getGameType(handText)
|
m = self._getGameType(handText)
|
||||||
m_sb = self.re_ringSB.search(handText)
|
m_20BBmin = self.re_20BBmin.search(handText)
|
||||||
m_bb = self.re_ringBB.search(handText)
|
|
||||||
if m is None:
|
if m is None:
|
||||||
return None
|
return None
|
||||||
|
|
||||||
|
@ -219,11 +217,18 @@ class PartyPoker(HandHistoryConverter):
|
||||||
info['type'] = 'ring'
|
info['type'] = 'ring'
|
||||||
|
|
||||||
if info['type'] == 'ring':
|
if info['type'] == 'ring':
|
||||||
if (m_sb is None) or (m_bb is None):
|
if m_20BBmin is None:
|
||||||
return None
|
bb = float(mg['RINGLIMIT'])/100.0
|
||||||
else:
|
else:
|
||||||
info['sb'] = m_sb.group('RINGSB')
|
bb = float(mg['RINGLIMIT'])/40.0
|
||||||
info['bb'] = m_bb.group('RINGBB')
|
|
||||||
|
if bb == 0.25:
|
||||||
|
sb = 0.10
|
||||||
|
else:
|
||||||
|
sb = bb/2.0
|
||||||
|
|
||||||
|
info['bb'] = "%.2f" % (bb)
|
||||||
|
info['sb'] = "%.2f" % (sb)
|
||||||
info['currency'] = currencies[mg['CURRENCY']]
|
info['currency'] = currencies[mg['CURRENCY']]
|
||||||
else:
|
else:
|
||||||
info['sb'] = clearMoneyString(mg['SB'])
|
info['sb'] = clearMoneyString(mg['SB'])
|
||||||
|
|
Loading…
Reference in New Issue
Block a user