aboutsummaryrefslogtreecommitdiff
path: root/internal/game/render_video_poker.go
diff options
context:
space:
mode:
Diffstat (limited to 'internal/game/render_video_poker.go')
-rw-r--r--internal/game/render_video_poker.go23
1 files changed, 14 insertions, 9 deletions
diff --git a/internal/game/render_video_poker.go b/internal/game/render_video_poker.go
index d7b1a57..b8baef8 100644
--- a/internal/game/render_video_poker.go
+++ b/internal/game/render_video_poker.go
@@ -76,7 +76,7 @@ func renderPokerPayTable(s *casino.VideoPokerSnapshot, mode string) string {
}
lines = append(lines, row(cells, true))
}
- lines = append(lines, border("└", "┴", "┘"), fmt.Sprintf("1 coin = %d credits | %d hand(s) | selected coin column in red", s.Denomination, s.Hands))
+ lines = append(lines, border("└", "┴", "┘"), fmt.Sprintf("1 coin = %d credits | %d hand(s)", s.Denomination, s.Hands))
if s.Config.Feature != "" {
lines = append(lines, fmt.Sprintf("Feature ON adds %d coin(s) per hand; requires five base coins.", s.Config.FeatureFeeCoins()))
}
@@ -127,27 +127,31 @@ func renderPokerCards(cards []casino.CardView, held *[5]bool, mode string, unico
}
func renderVideoPoker(s *casino.VideoPokerSnapshot, mode string, unicode bool, size int, style string, store *cardart.Store) string {
+ if s.Hands >= 100 {
+ unicode = true
+ }
+ size = cardRenderSize(unicode, size)
if s.Hands > 1 {
size = min(size, 5)
}
if s.Hands >= 25 {
size = 1
}
- if s.Hands >= 100 {
- unicode = true
- }
var lines []string
if s.ShowPayTable {
lines = append(lines, renderPokerPayTable(s, mode), "")
}
- feature := "CLASSIC"
+ feature := ""
if s.Config.Feature != "" {
feature = s.Config.FeatureLabel() + " OFF"
if s.FeatureOn {
feature = s.Config.FeatureLabel() + " ON"
}
}
- badge := pokerInk(mode, " ["+feature+"] ", false)
+ badge := ""
+ if feature != "" {
+ badge = pokerInk(mode, " ["+feature+"] ", false)
+ }
bonus := ""
mult := s.Multiplier
if s.Config.Feature == casino.PokerUltimateX {
@@ -165,18 +169,19 @@ func renderVideoPoker(s *casino.VideoPokerSnapshot, mode string, unicode bool, s
if s.Dice[0] > 0 {
bonus += fmt.Sprintf(" Dice [%d] + [%d]", s.Dice[0], s.Dice[1])
}
+ decorated := badge != "" || bonus != ""
if len(s.Cards) > 0 && len(s.Lines) == 0 {
art := renderPokerCards(s.Cards, &s.Held, mode, unicode, size, style, store)
- if len(art) > 0 {
+ if len(art) > 0 && decorated {
art[0] += " " + badge + bonus
}
lines = append(lines, art...)
- } else if len(s.Lines) == 0 {
+ } else if len(s.Lines) == 0 && decorated {
lines = append(lines, badge+bonus)
}
for i, line := range s.Lines {
art := renderPokerCards(line.Cards, nil, mode, unicode, size, style, store)
- if i == 0 && len(art) > 0 {
+ if i == 0 && len(art) > 0 && decorated {
art[0] += " " + badge + bonus
}
if len(s.Lines) > 1 && len(art) > 0 {