Two Plus Two Newer Archives  

Go Back   Two Plus Two Newer Archives > Internet Gambling > Software
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 05-21-2007, 04:14 PM
Pomtidom Pomtidom is offline
Senior Member
 
Join Date: Sep 2006
Posts: 125
Default Fix for GameTime+ on Everest Poker

Hi,

If anyone here plays on Everest Poker and uses GameTime+ they probably noticed that you have to move the labels around each time you open a new table, because Everest always places you at the front seat no matter what seat you have.

I've created a script to workaround this annoying problem. It's written in Python which you'll need to run the script. Python can be found here: http://www.python.org/download/

What this script does is monitor the HH's Everest Poker produces, converts them to make sure you are always at seat 0 in the handhistory and writes them in a different directory (output_dir) which you can import into PT.

There are 3 settings in this script:
- everest_dir: this is the directory where Everest Poker places the handhistories, this is usually correct by default.
- output_dir: the directory the script outputs the parsed handhistories, make sure this directory exists.
- number_of_players: whether you play headsup (2), shorthanded (6) or fullring (10).

Save the code of the script to a .py file (e.g. ConvertEverest.py) and doubleclick to run it. It will not output anything on screen but will parse the handhistories every 60 seconds. Just let it run. Make sure PT imports the output_dir and not the everest_dir.

Here's the script:
<font class="small">Code:</font><hr /><pre>import os, time, re, xml.dom.minidom, xml.parsers.expat

############################### SETTINGS ###############################

everest_dir = "C:\Program Files\Everest Poker\history\\"
output_dir = "C:\Program Files\Everest Poker\history\processed\\"
number_of_players = 6

############################# / SETTINGS ###############################


def ParseFile( filename ):
in_file = open( everest_dir + filename, 'rb' )
out_file = open( output_dir + filename, 'wb' )
lines = in_file.readlines()
handtext = [ ]
for line in lines:
handtext.append( line )
if '&lt;SESSION' in line:
xmlLine = xml.dom.minidom.parseString( line )
nickname = xmlLine.childNodes[0].getAttribute( 'screenName' )
elif '&lt;HAND' in line:
position = { }
elif '&lt;SEAT' in line:
xmlLine = xml.dom.minidom.parseString( line )
pos = xmlLine.childNodes[0].getAttribute( 'position' )
name = xmlLine.childNodes[0].getAttribute( 'name' )
position[ name ] = pos
elif '&lt;DEALER' in line:
offset = int( position[ nickname ] )
elif '&lt;/HAND&gt;' in line:
for l in handtext:
try:
xmlLine = xml.dom.minidom.parseString( l )
pos = xmlLine.childNodes[0].getAttribute( 'position' )
pos = int(pos)
pos = (pos - offset) % number_of_players
out_file.write( re.sub( 'position="[0-9]+"', 'position="' + str(pos) + '"', l ) )
except (ValueError, xml.parsers.expat.ExpatError):
if '&lt;WIN' in l:
pos = int( l[ 17 ] )
pos = (pos - offset) % number_of_players
l = l[:17] + str(pos) + l[18:]
out_file.write( l )
handtext = [ ]


handled = { }
while True:
files = os.listdir( everest_dir )
for file in files:
if re.match( "^[0-9]+\.txt", file ):
mtime = os.path.getmtime( everest_dir + file )
if file not in handled:
handled[ file ] = 0
if mtime &gt; handled[ file ]:
ParseFile( file )
handled[ file ] = mtime
time.sleep( 60 )</pre><hr />

I have tested this briefly and it seems to work. Any questions/comments/suggestions are welcome.
Reply With Quote
  #2  
Old 05-25-2007, 11:42 AM
HoschH HoschH is offline
Junior Member
 
Join Date: Apr 2007
Location: out of position
Posts: 14
Default Re: Fix for GameTime+ on Everest Poker

Nice one!
Thanks.

I've tested it and it works for me.
Reply With Quote
  #3  
Old 06-03-2007, 09:26 AM
Zaghomat Zaghomat is offline
Senior Member
 
Join Date: Jun 2006
Posts: 273
Default Re: Fix for GameTime+ on Everest Poker

Hi, I tired the sof, but I got this error:


C:\Program Files\Everest Poker&gt;everest.py
Traceback (most recent call last):
File "C:\Program Files\Everest Poker\everest.py", line 57, in &lt;module&gt;
ParseFile( file )
File "C:\Program Files\Everest Poker\everest.py", line 14, in ParseFile
out_file = open( output_dir + filename, 'wb' )
IOError: [Errno 2] No such file or directory: 'C:\\Program Files\\Everest Poker\
\history\\processed\\110.txt'
Reply With Quote
  #4  
Old 06-03-2007, 10:00 AM
Zaghomat Zaghomat is offline
Senior Member
 
Join Date: Jun 2006
Posts: 273
Default Re: Fix for GameTime+ on Everest Poker

Ok got it, I have to create the 'C:\Program Files\Everest Poker\history\processed\ folder.
Reply With Quote
  #5  
Old 06-09-2007, 02:53 PM
Sergioxxx Sergioxxx is offline
Junior Member
 
Join Date: Jun 2007
Posts: 1
Default Re: Fix for GameTime+ on Everest Poker

Thank you very much for creating the script and to share it. It is of great help
Reply With Quote
  #6  
Old 06-10-2007, 03:19 PM
Triggerle Triggerle is offline
Senior Member
 
Join Date: Oct 2005
Location: What\'s a matter with you, rock?
Posts: 1,439
Default Re: Fix for GameTime+ on Everest Poker

Shouldn't this be trivially easy to implement directly into gametime+? I don't know any C++ or else I would try.
Reply With Quote
  #7  
Old 06-10-2007, 05:10 PM
Pomtidom Pomtidom is offline
Senior Member
 
Join Date: Sep 2006
Posts: 125
Default Re: Fix for GameTime+ on Everest Poker

Yes, shouldn't be too hard. Problem is the code on sourceforge is appearently not up to date. Also, I'm lazy.
Reply With Quote
  #8  
Old 06-25-2007, 06:45 PM
burt777 burt777 is offline
Junior Member
 
Join Date: Jan 2007
Location: Hilversum, Netherlands
Posts: 6
Default Re: Fix for GameTime+ on Everest Poker

A very effective improvement of my lie's quality!! Thanks a lot for this!

2 assumptions:
1) it's light weight, not a big task for the computer
2) the sleep 60 in the end means the script is executed every 60 seconds

I'm not a very good programmer, but if i'm correct, i could make the script run every 15 seconds, so the delay between handhistory and gametime stats is reduced a bit, right?

Anyway, great job!!
Reply With Quote
  #9  
Old 07-02-2007, 08:01 PM
Pomtidom Pomtidom is offline
Senior Member
 
Join Date: Sep 2006
Posts: 125
Default Re: Fix for GameTime+ on Everest Poker

[ QUOTE ]
2 assumptions:
1) it's light weight, not a big task for the computer
2) the sleep 60 in the end means the script is executed every 60 seconds

I'm not a very good programmer, but if i'm correct, i could make the script run every 15 seconds, so the delay between handhistory and gametime stats is reduced a bit, right?

[/ QUOTE ]
This is all true.

I doubt it would make a difference changing the 60 to 15 because you can only let PokerTracker import once every 60 seconds.
Reply With Quote
  #10  
Old 07-08-2007, 09:10 AM
SpaceyFCB SpaceyFCB is offline
Junior Member
 
Join Date: Mar 2005
Posts: 25
Default Re: Fix for GameTime+ on Everest Poker

Does this thing affect your position stats in Pokertracker or does the button also moves according your seat?

Greets. K.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 12:23 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.