Software Coding For Manipulation Of Known Poker Site

hellblazer

New member
Sep 20, 2008
3,020
86
0
Probably not the right forum to post this, but I know there's some poker players in here. I'm writing a poker program for PStars and was wondering if anyone has any experience with this.

I know that dll injection used to be possible for input, but now they changed it to a proprietary system and image searching/scraping has to be used for the input process. Anyone encountered this before? Heard AHK can be partially used for the input/output process, with the code primarily managing the processing algorithm part of it. Seems like input is the real doozy after they changed their system. Think .bmp comparison might be the way to go for the cards and balance. What do you guys think?
 


Was just talking about this with some friends yesterday (no experience with poker bots but my friends know I do some web stuff so they asked me). I have no idea for the input but my idea was to hack an open source 'take screenshot' program to train it to recognize the cards and the amounts people bet etc. This was for a downloadable poker client that you would run locally.

The idea would then be to find some poker training software that you could specify cards and bet and it would tell you the best move to make and you would input this back into the client by simulating mouse clicks.

I may be way off here but was just shooting the shit you know.

For poker you play in the browser though I'm sure there are easier ways of doing it.
 
Was just talking about this with some friends yesterday (no experience with poker bots but my friends know I do some web stuff so they asked me). I have no idea for the input but my idea was to hack an open source 'take screenshot' program to train it to recognize the cards and the amounts people bet etc. This was for a downloadable poker client that you would run locally.

The idea would then be to find some poker training software that you could specify cards and bet and it would tell you the best move to make and you would input this back into the client by simulating mouse clicks.

I may be way off here but was just shooting the shit you know.

For poker you play in the browser though I'm sure there are easier ways of doing it.

Yeah, it sounds like you're basically on the right track. From what I've read you need three components: input, processing, and output. I can write my own poker analysis algorithm(processing) and telling the mouse to move to a certain spot(output) and do something is pretty easy. It's the input part that's problematic.

I found some interesting info here, the guy wrote a whole series on it. Problem is they changed their input so you can't hijack it from their calls to the Windows API functions.

I actually found a ton of info on it besides that. There's another update on some guy who built one who says image scraping/comparison via AHK is the way to go and another guy who's selling one. I'll see what happens.
 
I've been kindof interested in this too. I started writing a blackjack bot to clear bonuses because its way easier than an all out holdem bot. I did some research before hand on how I was going to get my input and opted to go with image scraping.

I played around with several Optical Character Recognition (OCR) libraries and ended up using Tessnet2 (Tessnet2 a .NET 2.0 Open Source OCR assembly using Tesseract engine). I cropped out images of the card numbers and tried to run them through but it had very poor accuracy. I finished the bot but stopped working on it here because the OCR accuracy sucked and I moved on to other projects.

When working on the blackjack bot I didn't have the game summary window on my screen, so I could only crop out the card images. With poker, you might have better luck with the OCR because you can probably get your info out of the game summary window.

I also stumbled upon that coding the wheel blog while I was doing my research and looking back if I did it again I would definitely would with his approach of grabbing a few pixels to identify each card. Even with the game summary window I would use it as an extra safeguard.
 
As far as I understand, the game summary window doesn't work anymore. PStars changed to their own proprietary class. Everything has to be done via image scraping.
 
What I meant was that you could take a screen shot, crop out the window where regular text is displayed, and OCR that to see what it says.

I noticed with my project that whenever the cards were dealt, the cards are not perfectly horizontal to the screen 99% of the time, and the extra rotation/angles/etc tend to mess up the OCR results. A status window would be a lot easier to interpret and you could probably get much more accurate results.
 
There are a couple communities that deal with CAPTCHA cracking and making AutoHotKey scripts and C++/C# programs to automate gaming sites with point rewards and that sort of thing. They talk about OCR, image recognition, and even manipulating Flash behind the scenes.

Start at Mango12.com • Index page and go to their IRC channel and you can get advice on this kind of stuff. Their big thing is automating ClubBing.com. There's another site that's larger but I can't recall the URL offhand and I don't have it bookmarked.

It's mostly a bunch of kids, hacker wannabes, but they're doing the exact kind of shit you're talking about.
 
  • Like
Reactions: RockDiesel
DUDE use Sikuli.

The whole point of it is that it's automation based on screenshots and image comparison. Screenshot each card and create a visual dictionary in jython then just run comparisons based on the current hand.

I swear, it's like sikuli was created for botting card games

Project SIKULI
 
Never heard of Sikuli before, so I checked out the site. It looks pretty cool. The image comparison routines in AHK are very primitive and kludgy by comparison. AutoIt is even worse.
 
I don't know why you want to write this for stars, I'd go for some shitty small network that has no clue how to even look for bot activity.

Find a network with high rakeback and super/hyper turbo SnGs so all you have to do is write some simple ICM logic for pushing or folding.
 
DUDE use Sikuli.

The whole point of it is that it's automation based on screenshots and image comparison. Screenshot each card and create a visual dictionary in jython then just run comparisons based on the current hand.

I swear, it's like sikuli was created for botting card games

Project SIKULI

This looks sik ;) I'm was originally thinking of a poker bot but now I'm more leaning towards a blackjack bot just to clear the signup bonuses. As the house edge in blackjack is very low if played with the right strategy I can see this being quite attainable.

Has anyone used sikuli yet? It seems very slow in the demo videos.
 
This looks sik ;) I'm was originally thinking of a poker bot but now I'm more leaning towards a blackjack bot just to clear the signup bonuses. As the house edge in blackjack is very low if played with the right strategy I can see this being quite attainable.

Has anyone used sikuli yet? It seems very slow in the demo videos.

I made a thread about this awhile ago

http://www.wickedfire.com/shooting-shit/82835-check-out-sikuli-picture-driven-computing.html

I personally, haven't used it. But, if you scroll down through the thread you will see that uplinked has used it and might have some more info for you. You should probably shoot him a PM.
 
  • Like
Reactions: gutterseo
Thanks for the link, very interesting thread that I somehow missed
 
I missed that thread too. Sikuli looks sick, I am definitely going to consider using it for my blackjack bot if I ever decide to fix it. It looks like it would solve all my accuracy problems.
 
FWIW poker sites often run checks and breakpoints on themselves to try to stop debuggers, and it could be very easy for them to stop responding correctly if something like sikuli is installed/running. I'd suggest you consider running the poker app in a slightly more obscure VM (such as virtualbox, not vmware) and controlling it from there. That way there are no hooks or debuggers running that are accessible by the software itself, and as long as they don't put in code to detect it's on a VM you should be good to go for quite some time.
 
here's an excellent, extremely in-depth, 10-part blog post on exactly what you're asking about -- How I Built a Working Poker Bot, Part 1

</thread>

Yeah, I found that when I first began my search. The problem is that Pokerstars changed their output system, probably due to this guy. They switched it over to their own proprietary system, meaning no more dll injection, meaning you can't hijack their WINAPI signals anymore. That's what I was referencing in my initial thread. But a lot of info in that series is extremely useful and very interesting.