aboutsummaryrefslogtreecommitdiff
path: root/internal/casino/core.go
diff options
context:
space:
mode:
authorhistoria <[not public]>2026-09-24 20:06:41 -0400
committerhistoria <[not public]>2026-09-24 20:07:31 -0400
commit13db3e50cb6e29eedbf25416e5284bf08b0adefb (patch)
treed5e9b99030b25cc7fc102288b694c133f8832f84 /internal/casino/core.go
parentd114c747a7672c7e4daab3a5b5f1b2f066ebc912 (diff)
downloadthehouseoficarus-13db3e50cb6e29eedbf25416e5284bf08b0adefb.tar.gz
feat: casino table ux: aliases, rebet hints, deadline notifications, spectator mode
Diffstat (limited to 'internal/casino/core.go')
-rw-r--r--internal/casino/core.go10
1 files changed, 9 insertions, 1 deletions
diff --git a/internal/casino/core.go b/internal/casino/core.go
index 7143841..a927ab1 100644
--- a/internal/casino/core.go
+++ b/internal/casino/core.go
@@ -89,7 +89,15 @@ func (c *tableCore[P]) openBettingLocked(events []Event) []Event {
func (c *tableCore[P]) advanceBettingLocked(resolve func() []Event, reset func()) []Event {
sitOuts, goRound, pending := c.window.advance(c.players.participants())
if pending {
- return nil
+ var events []Event
+ if c.window.timer.warn() {
+ for _, p := range c.players.participants() {
+ if p.Connected && !p.HasBet && !p.SittingOut {
+ events = append(events, c.warning(p.Name, fmt.Sprintf("Betting closes in %d ticks. Bet now or sit out this hand.", c.window.timer.remaining())))
+ }
+ }
+ }
+ return events
}
var events []Event
for _, name := range sitOuts {