Tibs Manor

Friday, August 12, 2005

Video Poker 100

You may recall my raving about my favorite video poker machine in Las Vegas. Well I liked it so much I wrote a JavaScript/DHTML version that lets me play for free. My good friend Brad has posted an article about it on his site PokerFilter, and is also graciously hosting it on said site, at this link.

Obviously this is all play-money, for fun and amusement only, etc., no real money can be won or lost here.

Instructions - when you first hit the page, you can pick your bet amount and number of hands. Click "deal" to get your starting hand. Click on cards you want to hold, click "draw" to run your draws. Rinse and repeat.

If you're on IE for Windows, or Safari for OSX, you can hold cards with keyboard keys 1->5 or A->G, and deal/draw with the spacebar. There are some bugs still...Firefox on OSX has trouble displaying the HTML entities for card suits ( )...the "hold" indicators vary according to platform, and keyboard shortcuts only work on some browser/OS combinations. But it works and it is awfully fun if I do say so myself. All in JavaScript so very low bandwidth, only time it hits the server is for initial page load and for the various popups. I learned a few new tricks writing this thing that will actually make parts of my job easier I think.

Next on the agenda is a version to allow user-specified hands and a far higher number of trials (without the spiffy animated reveal, I don't want to display 1,000 or 10,000 hands of cards!). I'd like a page where I can enter a given hand, and see how different strategies on that hand pay off in the long run. This shouldn't be terribly hard to write the basics, I can reuse some of this code for the display side, and the new bits won't be hard, I just need to pick a language. I'll just need some help if I do any real statistical analysis. Good thing I'm marrying an economics doctoral candidate!


Post a Comment

<< Home