aboutsummaryrefslogtreecommitdiff
path: root/internal/game/render_cash_hunt.go
diff options
context:
space:
mode:
authorhistoria <[not public]>2026-10-05 17:05:14 -0400
committerhistoria <[not public]>2026-10-05 17:05:14 -0400
commite42952469dadfb3535633c66c881050ac128703c (patch)
treea78f7396b72cdbd6fa4f6c454c830f40cf2ad0cb /internal/game/render_cash_hunt.go
parent90ad8c0c33b519d5830c69d4128bdc984b5e9de8 (diff)
downloadthehouseoficarus-e42952469dadfb3535633c66c881050ac128703c.tar.gz
fix: gather verbs, walk oom, admin path bypass, roulette refund
Diffstat (limited to 'internal/game/render_cash_hunt.go')
-rw-r--r--internal/game/render_cash_hunt.go9
1 files changed, 5 insertions, 4 deletions
diff --git a/internal/game/render_cash_hunt.go b/internal/game/render_cash_hunt.go
index 0bb05fc..bdda321 100644
--- a/internal/game/render_cash_hunt.go
+++ b/internal/game/render_cash_hunt.go
@@ -51,7 +51,8 @@ const (
// cashHuntCenter pads text to a fixed tile width, keeping every column aligned
// whether it holds a one- or three-digit square number.
-func cashHuntCenter(text string, width int) string {
+func cashHuntCenter(text string) string {
+ width := cashHuntTileWidth
if len(text) >= width {
return text
}
@@ -175,12 +176,12 @@ func renderCashHunt(s *casino.CashHuntSnapshot, mode string, unicode bool, rtp s
for col := 0; col < cashHuntColumns; col++ {
k := row*cashHuntColumns + col
bg := cashHuntTileBlack
- number := cashHuntCenter(fmt.Sprintf("%d", k+1), cashHuntTileWidth)
- value := cashHuntCenter(fmt.Sprintf("%dx", s.Squares[k]), cashHuntTileWidth)
+ number := cashHuntCenter(fmt.Sprintf("%d", k+1))
+ value := cashHuntCenter(fmt.Sprintf("%dx", s.Squares[k]))
nf, vf := 244, cashHuntPrizeColor(s.Squares[k])
selected := s.Selected == k+1
if selected {
- number = cashHuntCenter(fmt.Sprintf(">%d<", k+1), cashHuntTileWidth)
+ number = cashHuntCenter(fmt.Sprintf(">%d<", k+1))
nf, vf, bg = 16, 16, 226
}
numbers[col] = color.Render(mode, color.ColorSpec{Fg: nf, Bg: bg, Bold: selected}, number)