Anatomy of a pokerbot - blueprint
Over this series of posts I’m going to talk you through building a basic bot to play limit holdem. It won’t be a world beater, in fact it won’t even break even long term, but it should serve as a demonstration of the principals and a base to build on if you take up the hobby. I think you’ll be surprised how sophisticated a bot can be with very few lines of code.
Like building anything else a good plan helps immensely. We’re going to use a premade program to interface with our chosen poker site, so that we can concentrate on the logic the bot should follow. The program in question is called Openholdem, and will take care of watching the poker site window to see what’s happening (screen scraping), evaluating the logic we have programmed and then pressing the relevant buttons in the poker window. It will also provide us with many premade functions for evaluating the situation. Certainly for our basic bot it’s all we’ll need.
Part of openholdem is called openscrape and is responsible for the screen scraping. You provide it with a table map of the poker site which shows it where buttons and text are. You can either download these table maps or create your own (it’s very easy but takes a little time and patience). Openholdem also has the ability to import data from Pokertracker if you have it installed. It’s easy to do but beyond the scope of this little project.
I would be remiss if I didn’t mention a topic of utmost importance to botting - stealth. If you’re doing this for real then you need to use some clever tricks to prevent the poker window from knowing that it’s being operated by a bot. The poker window can see what processes you’re running, where you’re clicking and gather all sorts of data on you to report back to the casino. Since this is a basic tutorial I’m going to recommend “running naked” (as it’s known in the community) and using a disposable account. Either pick a poker site you’re never going to use again or sign up for a play money only account.

One Comment, Comment or Ping
ehsanul
Sounds like it’ll be a great series.
More on the stealth please, if you possibly could, I’m pretty concerned about that.
Aug 22nd, 2008
Reply to “Anatomy of a pokerbot - blueprint”