Merge branch 'master' into stats

Conflicts:
	pyfpdb/DerivedStats.py
	pyfpdb/fpdb_import.py
This commit is contained in:
Worros 2009-12-22 13:47:26 +08:00
commit af1b516b23
5 changed files with 29 additions and 5 deletions

View File

@ -272,7 +272,7 @@ class DerivedStats():
# XXX: enumerate(list, start=x) is python 2.6 syntax; 'start'
# came there
#for i, street in enumerate(hand.actionStreets[2:], start=1):
for i, street in enumerate(hand.actionStreets[2:]:
for i, street in enumerate(hand.actionStreets[2:]):
name = self.lastBetOrRaiser(hand.actionStreets[i+1])
if name:
chance = self.noBetsBefore(hand.actionStreets[i+2], name)

View File

@ -89,6 +89,7 @@ class PartyPoker(HandHistoryConverter):
(?P<TTYPE>[a-zA-Z0-9 ]+)\s+
(?: \#|\(|)(?P<TABLE>\d+)\)?\s+
(?:[^ ]+\s+\#(?P<MTTTABLE>\d+).+)? # table number for mtt
(\(No\sDP\)\s)?
\((?P<PLAY>Real|Play)\s+Money\)\s+ # FIXME: check if play money is correct
Seat\s+(?P<BUTTON>\d+)\sis\sthe\sbutton
""",

View File

@ -203,6 +203,8 @@ class PokerStars(HandHistoryConverter):
if key == 'TOURNO':
hand.tourNo = info[key]
if key == 'BUYIN':
#FIXME: The key looks like: '€0.82+€0.18 EUR'
# This should be parsed properly and used
hand.buyin = info[key]
if key == 'LEVEL':
hand.level = info[key]

View File

@ -1,4 +1,5 @@
#!/usr/bin/python
# -*- coding: iso-8859-15 -*-
#Copyright 2008 Steffen Jobbagy-Felso
#This program is free software: you can redistribute it and/or modify
@ -538,7 +539,11 @@ def parseAnteLine(line, isTourney, names, antes):
#returns the buyin of a tourney in cents
def parseBuyin(topline):
pos1 = topline.find("$")+1
pos2 = topline.find("+")
if pos1 != 0:
pos2 = topline.find("+")
else:
pos1 = topline.find("")+3
pos2 = topline.find("+")
return float2int(topline[pos1:pos2])
#parses a card line and changes the passed arrays accordingly
@ -635,9 +640,14 @@ def parseCashesAndSeatNos(lines):
#returns the buyin of a tourney in cents
def parseFee(topline):
pos1=topline.find("$")+1
pos1=topline.find("$",pos1)+1
pos2=topline.find(" ", pos1)
pos1 = topline.find("$")+1
if pos1 != 0:
pos1 = topline.find("$", pos1)+1
pos2 = topline.find(" ", pos1)
else:
pos1 = topline.find("")+3
pos1 = topline.find("", pos1)+3
pos2 = topline.find(" ", pos1)
return float2int(topline[pos1:pos2])
#returns a datetime object with the starttime indicated in the given topline

View File

@ -0,0 +1,11 @@
PokerStars Game #25979907808: Omaha Pot Limit ($0.05/$0.10 USD) - 2009/03/15 6:20:33 ET
Table 'Waterman' 6-max Seat #1 is the button
Seat 1: s0rrow ($11.65 in chips)
s0rrow: posts small blind $0.05
ritalinIV: is sitting out
Hand cancelled
*** SUMMARY ***
Seat 1: s0rrow (button) collected ($0)