branchrust_reboot/main/CardGamescancel
317 Commits over 120 Days - 0.11cph!
If all other players are all-in, there's no point in having the one remaining active player go through the motions of checking. In that scenario, skip to the end.
Set the minimum raise if it's under, instead of just bailing out
Make the correct player input if player doesn't have enough for the blinds
Refactored the initial blinds to act like real gameplay inputs (reduce the potential bug surface)
Play a short ding sound when it's the local player's turn
Decrease central poker UI padding
Differentiate true winners from users who just got some scrap back due to all-in rules.
Fix card central UI auto-sizing.
Holding shift changes the bet/raise amount by 25 instead of 5
Clear poker table in the poker tester if the player dismounts
Fix for player order. Lock the CardPlayerData array to the mount index
Reorder all card table seats/storage/mount points so that gameplay always follows the correct clockwise order
- Fixed betting rounds not ending until the end of going around the table. Now moves on immediatey if everyone has had a turn and the bets are equal.
- Fixed the next betting round not always starting on the right player.
Fixed player's previous cards that were sent through not clearing if the new load contains no cards
Fix the first to have a turn player for two-player games
In two player games, have the dealer post the small blind. Small blind player becomes big blind.
Merge branch back to CardGames
- Fix the raise minimums to follow the rules correctly
- Made the action UI less complicated, now only showing the amount your bet will increase
- Always send card player data for all players, less bug-prone
- Move some CardPlayerData methods to server-only
Better abandoned scrap calculation
Remove temporary debug print
If a player leaves the poker game (quits/dies), but has a higher bet than anyone still in the game due to being all-in for an amount that nobody else could afford, that leaves that portion of the pot in a nominally unclaimable state since poker rules state that a player can only claim winnings from each other player up to the value of their bet. Previously this was paid out in an awkward way that could end up with non-winners claiming the "bonus" scrap. Bonus winnings are now divided equally between the winner(s) (plural in the case of a draw result) of a round.
For the dismounting on load, work around the issue of seats not being saved and therefore ending up with different UIDs on load
Remove the warnings for inputs from the non-active player, it's fine to just ignore them.
When the server loads a save and a player was mounted, move them to a valid dismount position if there is one instead of just spawning them at the spot they were mounted. Fixes getting stuck in the poker table among other things.
Match up card table shadow settings on LODs
Fix up LOD issues on the card tables
Changed "play" language key to "play_poker" since "play" is already in use for "PLAY GAME"
Checked and adjusted player mount positions for all card table seats
Fix properties not updating when using vehicle custom inspector
Match static card table A chair positions with deployable card table
Handle the case where a player leaves (or dies) mid-game, when they're all-in for more than the other player(s), and hence should have got some of the pot back even if they lost. Pay out the pot ignoring all-in limits if there are no more players to pay out to.
Rename card images for extra clarity when used in the inspector
Fix poker results calculation order bug
Add a sanity check warning if there is any scrap left in the pot after winner payouts
Dispose old winner info proto data properly on the server side
Check and Call can't ever be options in the same turn, so let them both be on the C key for simplicity
Increase time between rounds to six seconds
Fixed the player's cards not always updating at the next round. Updated how PopulateCards is set.
Fixed protobuf winner data not being copied across
Compile fix for inspector vars
Have the UI say to hold Space