Skip to content

fix(holdem): cut the dead time between hands from about 10s to about 6s - #71

Merged
JonasFocus merged 9 commits into
mainfrom
onyx/quicker-turnaround
Oct 20, 2026
Merged

JonasFocus merged 9 commits into
mainfrom
onyx/quicker-turnaround

Conversation

@JonasFocus

Copy link
Copy Markdown
Owner

Summary

Shortens the idle time between Hold'em hands from about 10s to about 6s.

Changes

  • Lower SHOWDOWN_MS from 7000 to 5000 and RUNOUT_MS from 2200 to 1500
  • Add AFTER_HAND_MS (1200) as the delay before the next hand's start time, and export it from the Hold'em module
  • syncLobby takes an optional delay (default START_MS); resetTable passes AFTER_HAND_MS, other callers keep the 3s join beat
  • Add tests for the last-action-to-next-deal gap and for a rebuy keeping the full START_MS wait

Why

Players waited about 10s between the last action and the next deal, which made the table feel slow. A table that is already seated and funded does not need the full join beat after a hand ends.

Testing

  • Tested locally
  • Existing tests pass (304)
  • Added tests
  • Lint, typecheck and build pass
  • Ran a heads-up all-in against a local server: 3.0s join beat to the first deal, runout streets at 1.5s, lobby 5.0s after showdown

Notes

The next-deal timing itself is covered by the unit tests only. The page was not driven in a browser.

@vercel

vercel Bot commented Oct 20, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
game-time Ready Ready Preview Oct 20, 2026 8:10pm UTC

- Shorten the showdown beat from 7s to 5s and the all-in runout street gap from 2.2s to 1.5s
- Add a 1.2s after-hand lobby beat (AFTER_HAND_MS) instead of the 3s join beat once a hand settles
- Keep the 3s beat for a fresh table and for rebuys that leave fewer than two funded players
- Cover the settle-to-deal gap, the late joiner case, rebuy timing and the runout/animation bound in tests

Claude-Session: https://claude.ai/code/session_01SiinSXHP71xKCXmAjpTHaM
- Drop the 1.2s after-hand lobby beat so rebuy, sit out and stand up keep the 3s window
- Take the turnaround savings from SHOWDOWN_MS and RUNOUT_MS only
- Cover a busted player rebuying in a three-handed game before the next deal

Claude-Session: https://claude.ai/code/session_01SiinSXHP71xKCXmAjpTHaM
- Add AFTER_HAND_MS and use it for the post-showdown start clock when nobody seated is broke
- Keep the full START_MS beat when a seated player has no chips so they can rebuy before the deal
@JonasFocus JonasFocus added the ready Green and self-reviewed; waiting for merge label Oct 20, 2026
# Conflicts:
#	lib/texasholdem/index.ts
#	tests/texasholdem.test.ts
@JonasFocus
JonasFocus merged commit 30e43ec into main Oct 20, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready Green and self-reviewed; waiting for merge

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant