diff options
| author | salmonik <salmonik@tuta.io> | 2026-11-01 21:24:48 +0100 |
|---|---|---|
| committer | salmonik <salmonik@tuta.io> | 2026-11-01 21:24:48 +0100 |
| commit | a5ea79739783682c46983d5b67b2b4b7b5338ccb (patch) | |
| tree | d7e06cacfffdb173e8b27bcca426d6bbdd152ee3 /gui/src/blackjack.rs | |
| parent | v4.2.0: wire the GUI to the core, transport and all four games (diff) | |
| download | zagan-bet-a5ea79739783682c46983d5b67b2b4b7b5338ccb.tar.gz zagan-bet-a5ea79739783682c46983d5b67b2b4b7b5338ccb.zip | |
v4.2.1: plain-language game copy and a balance fetch on login
The lobby and every game screen now speak to a player, not an operator: each game has one how-to sentence, and the table headers, limits, RTP, paytable and server-timing notes are gone. The account and balance are fetched whenever a session signs in, including stored-credential auto-login, so the header is filled before the lobby appears.
Diffstat (limited to 'gui/src/blackjack.rs')
| -rw-r--r-- | gui/src/blackjack.rs | 36 |
1 files changed, 2 insertions, 34 deletions
diff --git a/gui/src/blackjack.rs b/gui/src/blackjack.rs index d42f000..bbe96fa 100644 --- a/gui/src/blackjack.rs +++ b/gui/src/blackjack.rs | |||
| @@ -70,11 +70,7 @@ fn sidebar(ui: &mut Ui, view: &BlackjackView) -> Option<Command> { | |||
| 70 | .font(theme::sans(22.0)) | 70 | .font(theme::sans(22.0)) |
| 71 | .color(theme::TEXT), | 71 | .color(theme::TEXT), |
| 72 | ); | 72 | ); |
| 73 | ui.label( | 73 | widgets::note(ui, "Get close to 21 without going over."); |
| 74 | eframe::egui::RichText::new("6 decks · dealer stands on 17 · 3:2") | ||
| 75 | .font(theme::sans(12.0)) | ||
| 76 | .color(theme::TEXT_DIM), | ||
| 77 | ); | ||
| 78 | 74 | ||
| 79 | ui.add_space(theme::SPACE_5); | 75 | ui.add_space(theme::SPACE_5); |
| 80 | ui.label(theme::label("Bet")); | 76 | ui.label(theme::label("Bet")); |
| @@ -104,12 +100,6 @@ fn sidebar(ui: &mut Ui, view: &BlackjackView) -> Option<Command> { | |||
| 104 | ui.add_space(theme::SPACE_3); | 100 | ui.add_space(theme::SPACE_3); |
| 105 | widgets::error(ui, error); | 101 | widgets::error(ui, error); |
| 106 | } | 102 | } |
| 107 | |||
| 108 | ui.add_space(theme::SPACE_4); | ||
| 109 | ui.separator(); | ||
| 110 | ui.add_space(theme::SPACE_2); | ||
| 111 | widgets::note(ui, "Blackjack pays 3:2. The dealer stands on soft 17."); | ||
| 112 | widgets::note(ui, "Double only on the first two cards."); | ||
| 113 | }); | 103 | }); |
| 114 | }, | 104 | }, |
| 115 | ); | 105 | ); |
| @@ -189,29 +179,7 @@ fn result_text(result: &str, winnings: u64) -> (String, Color32) { | |||
| 189 | } | 179 | } |
| 190 | 180 | ||
| 191 | fn board(ui: &mut Ui, view: &BlackjackView) { | 181 | fn board(ui: &mut Ui, view: &BlackjackView) { |
| 192 | ui.horizontal(|ui| { | 182 | ui.add_space(theme::SPACE_2); |
| 193 | ui.label( | ||
| 194 | eframe::egui::RichText::new("Table 01") | ||
| 195 | .font(theme::sans(15.0)) | ||
| 196 | .color(theme::TEXT), | ||
| 197 | ); | ||
| 198 | ui.label( | ||
| 199 | eframe::egui::RichText::new("Blackjack · six decks") | ||
| 200 | .font(theme::sans(12.0)) | ||
| 201 | .color(theme::TEXT_DIM), | ||
| 202 | ); | ||
| 203 | ui.with_layout( | ||
| 204 | eframe::egui::Layout::right_to_left(eframe::egui::Align::Center), | ||
| 205 | |ui| { | ||
| 206 | ui.label( | ||
| 207 | eframe::egui::RichText::new("3:2 · S17") | ||
| 208 | .font(theme::mono(12.0)) | ||
| 209 | .color(theme::TEXT_FAINT), | ||
| 210 | ); | ||
| 211 | }, | ||
| 212 | ); | ||
| 213 | }); | ||
| 214 | ui.add_space(theme::SPACE_5); | ||
| 215 | 183 | ||
| 216 | let Some(hand) = &view.hand else { | 184 | let Some(hand) = &view.hand else { |
| 217 | centered_note(ui, "Place a bet and deal a hand."); | 185 | centered_note(ui, "Place a bet and deal a hand."); |
