From 2317022c16b520dd5272facfd5092a4c58cac44b Mon Sep 17 00:00:00 2001 From: historia <[not public]> Date: Wed, 30 Sep 2026 17:49:28 -0400 Subject: fix: simplified simplified craps, removed unnecessary commands and instructions --- internal/casino/craps_ux.go | 32 +++++++++++++++++++++++--------- 1 file changed, 23 insertions(+), 9 deletions(-) (limited to 'internal/casino/craps_ux.go') diff --git a/internal/casino/craps_ux.go b/internal/casino/craps_ux.go index 948ab99..10f7fcb 100644 --- a/internal/casino/craps_ux.go +++ b/internal/casino/craps_ux.go @@ -8,22 +8,36 @@ import ( func (t *crapsTable) commands(name string) []MenuCommand { commands := []MenuCommand{} p := t.players.get(name) + simplified := t.Config.Craps.variant() == "simplified" if p != nil { // Pass-only editions cannot accept another contract while a point or // the player's existing pass bet is live. if t.Config.Craps.allows("come") || t.Config.Craps.allows("buy") || (t.point == 0 && !p.HasBet) { - target := "" - if !t.Config.Craps.allows("buy") { - target = "pass" + if simplified { + // Pass is the only target, so the bare bet is a rebet. + if p.lastBet > 0 { + commands = append(commands, + MenuCommand{Command: "bet", Desc: fmt.Sprintf("Rebet %d on pass (also: rebet)", p.lastBet)}, + MenuCommand{Command: "bet ", Desc: "New amount on pass; the dice roll 3 seconds after a bet"}) + } else { + commands = append(commands, MenuCommand{Command: "bet ", Desc: "Wager on pass; the dice roll 3 seconds after a bet"}) + } + } else { + target := "" + if !t.Config.Craps.allows("buy") { + target = "pass" + } + commands = append(commands, MenuCommand{Command: "bet on " + target, Desc: "Place a wager; targets: table rules"}) } - commands = append(commands, MenuCommand{Command: "bet on " + target, Desc: "Place a wager; targets: table rules"}) } if p.HasBet { - if t.shooter() == p && (!t.multiplayer || t.roundElapsed >= crapsBetDelay) { - commands = append(commands, MenuCommand{Command: "roll", Desc: "Shoot now"}) - } - if !p.autoRoll { - commands = append(commands, MenuCommand{Command: "autoroll", Desc: "Roll automatically on your turn"}) + if !simplified { + if t.shooter() == p && (!t.multiplayer || t.roundElapsed >= crapsBetDelay) { + commands = append(commands, MenuCommand{Command: "roll", Desc: "Shoot now"}) + } + if !p.autoRoll { + commands = append(commands, MenuCommand{Command: "autoroll", Desc: "Roll automatically on your turn"}) + } } for _, b := range p.bets { if !crapsContract(b.kind) || b.odds.Total > 0 { -- cgit v1.2.3