Poker Hand Maker
In my UE4 poker scripting, I've found I really need to be able to play a predetermined hand in order to debug changes to the blueprints. One example is, I have a bug when checking the bes kicker for players who match rank for Three of A Kind; the bug seems to happen where the best kickers are on the table (so the players would split pot). It'd be easy to fix if I could test just this case. If I want to check this by playing random hands until I hit the same result, that is a lot of hands to play. So it's best if I can inject a predetermined hand from the outset. To do this I had to make a UI widget to manually add hand values, and get the gamestate to read the UI input and report it and evaluate it.
The cool feature of the UI is that you can control via slider how many players are in the hand and the UI for each player pops in and out to match the player count. In my base game all the player names are presets, and you can set from 2 to 10 players. It doesn't permit blank card entries, but it does require the correct format for any input (like 10D, AD, QC), but this isn't a problem since it's just for me to use for debugging.
The next step I'll be tring will be to take the last hand result, write it to disk, so it can be automatically populated into the Poker Hand Maker UI from a button press, which would be good for re-testing the same hand when tracking down a bug. The video below is quite minimal, but not bad for a SaturdayScreenshot.