diff options
Diffstat (limited to 'internal/casino/table_ux.go')
| -rw-r--r-- | internal/casino/table_ux.go | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/internal/casino/table_ux.go b/internal/casino/table_ux.go index d23c8a2..5613a81 100644 --- a/internal/casino/table_ux.go +++ b/internal/casino/table_ux.go @@ -14,6 +14,13 @@ type WagerRow struct { Win string } +// rebetWager is one remembered wager a multi-bet game can replay on a bare +// bet/rebet. +type rebetWager struct { + spot string + amount int +} + const ( hintCommandRules = "rules" hintCommandList = "list" @@ -36,6 +43,18 @@ func withTableHints(commands []MenuCommand, wagerRows []WagerRow) []MenuCommand return commands } +// stripMenuBalance clears the wallet display from a bet response's menus, so +// placing a wager never prints the balance. Explicit status/look and later +// settlements keep their balance. +func stripMenuBalance(events []Event) []Event { + for i := range events { + if events[i].Menu != nil { + events[i].Menu.ShowBalance = false + } + } + return events +} + // RulesText is the shared rules view for table commands and room fixtures. func (c TableConfig) RulesText() string { return rulesTextOnTable(c) } |
