Minor fixups: set->list and FullTilt lookup table

This commit is contained in:
Worros 2009-03-03 00:10:15 +09:00
parent 3018483a6f
commit 25ae39d7b5
3 changed files with 11 additions and 5 deletions

View File

@ -62,6 +62,7 @@ class Everleaf(HandHistoryConverter):
def readSupportedGames(self): def readSupportedGames(self):
return [["ring", "hold", "nl"], return [["ring", "hold", "nl"],
["ring", "hold", "pl"], ["ring", "hold", "pl"],
["ring", "hold", "fl"],
["ring", "omahahi", "pl"] ["ring", "omahahi", "pl"]
] ]

View File

@ -181,7 +181,7 @@ class FullTilt(HandHistoryConverter):
# "2c, qh" -> set(["2c","qc"]) # "2c, qh" -> set(["2c","qc"])
# Also works with Omaha hands. # Also works with Omaha hands.
cards = m.group('CARDS') cards = m.group('CARDS')
cards = set(cards.split(' ')) cards = cards.split(' ')
hand.addHoleCards(cards, m.group('PNAME')) hand.addHoleCards(cards, m.group('PNAME'))
def readPlayerCards(self, hand, street): def readPlayerCards(self, hand, street):
@ -195,7 +195,7 @@ class FullTilt(HandHistoryConverter):
if player.group('NEWCARD') != None: if player.group('NEWCARD') != None:
print cards print cards
cards = cards + " " + player.group('NEWCARD') cards = cards + " " + player.group('NEWCARD')
cards = set(cards.split(' ')) cards = cards.split(' ')
hand.addPlayerCards(cards, player.group('PNAME')) hand.addPlayerCards(cards, player.group('PNAME'))
def readAction(self, hand, street): def readAction(self, hand, street):
@ -218,7 +218,7 @@ class FullTilt(HandHistoryConverter):
def readShowdownActions(self, hand): def readShowdownActions(self, hand):
for shows in self.re_ShowdownAction.finditer(hand.string): for shows in self.re_ShowdownAction.finditer(hand.string):
cards = shows.group('CARDS') cards = shows.group('CARDS')
cards = set(cards.split(' ')) cards = cards.split(' ')
hand.addShownCards(cards, shows.group('PNAME')) hand.addShownCards(cards, shows.group('PNAME'))
def readCollectPot(self,hand): def readCollectPot(self,hand):
@ -229,7 +229,7 @@ class FullTilt(HandHistoryConverter):
for m in self.re_ShownCards.finditer(hand.string): for m in self.re_ShownCards.finditer(hand.string):
if m.group('CARDS') is not None: if m.group('CARDS') is not None:
cards = m.group('CARDS') cards = m.group('CARDS')
cards = set(cards.split(' ')) cards = cards.split(' ')
hand.addShownCards(cards=cards, player=m.group('PNAME')) hand.addShownCards(cards=cards, player=m.group('PNAME'))

View File

@ -409,7 +409,12 @@ Map the tuple self.gametype onto the pokerstars string describing it
"0.20" : ("0.05", "0.10"), "0.20" : ("0.05", "0.10"),
"0.50" : ("0.10", "0.25"), "0.50" : ("0.10", "0.25"),
"1.00" : ("0.25", "0.50") "1.00" : ("0.25", "0.50")
},
"FullTilt" : { "0.10" : ("0.02", "0.05"),
"0.20" : ("0.05", "0.10"),
"1" : ("0.25", "0.50"),
"2" : ("0.50", "1"),
"4" : ("1", "2")
} }
} }
return betlist[self.sitename][self.bb] return betlist[self.sitename][self.bb]