Where does the time go? I meant to make this post earlier this month, but I kept putting it off for one reason or another, and before I knew it, February was around the corner. I decided I didn’t want to wait another month before posting though, so even though I don’t have as much to show at this exact moment, it’d be a good time to get it out of the way.
The last month and a half on Pixel Poker have been a bit of a roller coaster of emotions. On the one hand, I am actively working on getting AI working well, but on the other hand, right now it’s basically complete crap. My primary work this past month has been in a few UI updates, and work on improving the back-end of the game to adapt it for my current AI goals.
The situation I’m in now is that unless I want to start working towards making the AI mimic actual players, and actual thought processes perfectly, I need to take better advantage of the way computers work. Since creating poker AI which mimics actual player thought processes was never my goal, I’ve determined that having players evaluate their hands the same way as real players is not always an ideal because it forces me to create complex if statements and handle many specific scenarios before I can even get close to that. Instead I should be striving to evaluate them in a more statistical way, which computers can do more effectively on the fly than a person can . The best way I can find to do this is simply to have the AI players evaluate their hand against hundreds of random hands, and record how often they win. Then, after looking at the probability they will win they can use other information such as how much they have to bet, their position, and even their rank in the game as a whole, to determine whether betting is worthwhile. From there I could start doing things to mimic aspects of a real player such as confidence, and skill level to adjust the exact scenarios in which they would be willing to play.
While this method is very simple on paper, it was not what I was expecting to do to begin with, and thus it brought many problems to my existing systems. The first and foremost problem is simply speed of the algorithms I’m currently using. At the beginning of this month, the algorithm I was using to do the base evaluation of a hand, to determine what type of hand the player has, was very inefficient. I’ve done a lot of work to improve it, but in all honesty, it could still be even better, so I’m still working on that. The next problem is in the way all of the systems work together. Simply put, the web of systems I’ve been using to determine the final value of the hand, and what cards are in the hand is very complex. Because of how interconnected certain systems are with each other, disconnecting them enough that I can even run the test without creating thousands of new objects on the fly is problematic to say the least.
So after all that, it comes down to this, the systems I have in place are not well-enough designed and right now my primary goal has been to restructure them to increase efficiency and work more effectively with my new AI goals. I’ve already done some major work in this area, but it seems like I will have to do even more to disconnect these systems and make them more independent to create powerful and efficient AI. Part of the reason I put off this update for so long was because I didn’t know what to do about this, and I was trying to find a solution before posting. As usual though, just typing this out is helping me consider new ideas, and even if most of my days are frustrating, I know that I am getting closer. After all, ruling out a bad solution just brings you one step closer to finding a good one.
Small UI Changes
I think that the UI is mostly unchanged, however I did modify the Call/Check buttons. Since they have very similar functions, and since they are never active at the same time, I decided to reconcile them to two smaller buttons which take up the same space as a single button. I think it makes the most sense, and it feels a bit better than it did before in my opinion. I considered making them one button which adjusts based on the situation, but I liked this better. This change also gave me a lot of extra room to increase the “bet” area on the UI and make the Call text much larger and clearer. Finally, you’ll notice that there are now a red and black line on the Bet Slider. The Red line represents the minimum bet it would take to call, and the black one is the minimum you can raise by.
While I think this is a major improvement over the previous version of the menu, I still plan on playing around with it a bit more. Eventually I’d like to remove the bet slider entirely and switch to a system which allows the player to click on images of chips and have the chips represented on the table, but that’s going to come later on since I’m pretty sure there are still some flaws in how I calculate minimum bets in uncommon situations or in situations where one player is going all-in.
Aside from the bet menu, the UI is completely the same.
This update was also a major one for general bug fixing. Shortly after my last update I found a much more efficient way to test, and it allowed me to see many more games to completion. This lead to me finding a number of different errors that had previously gone completely unseen. While many of these errors have been dealt with, I’m still working on some of them. For now I’ve decided to spend all my time getting past the AI hurdles I outlined above, and then move on to tackling the bugs. I’m doing it this way because the changes due to the AI adjustments will be fairly large and I ‘d hate to spend days working on improving a system that ends up getting completely overhauled during the AI changes anyway.
That’s all the info I’ve got for Pixel Poker today, however I’ll be updating the blog again tomorrow to discuss my Global Game Jam 2015 entry. See you all tomorrow!