diff options
| author | salmonik <salmonik@tuta.io> | 2026-10-28 23:19:52 +0100 |
|---|---|---|
| committer | salmonik <salmonik@tuta.io> | 2026-10-28 23:19:52 +0100 |
| commit | 2915d826f744612e0d975282f5bddf13270b9f3f (patch) | |
| tree | a2864bfaef91070ac3b4e13b8b731e539a757cc8 /src/server/core.rs | |
| parent | v1.0.0: replace slots with 5x3 reels and five paylines (diff) | |
| download | zagan-bet-2915d826f744612e0d975282f5bddf13270b9f3f.tar.gz zagan-bet-2915d826f744612e0d975282f5bddf13270b9f3f.zip | |
v1.1.0: highlight winning symbols on the slots board
Diffstat (limited to 'src/server/core.rs')
| -rw-r--r-- | src/server/core.rs | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/server/core.rs b/src/server/core.rs index 33cafbf..350fe18 100644 --- a/src/server/core.rs +++ b/src/server/core.rs | |||
| @@ -254,6 +254,11 @@ impl ServerCore { | |||
| 254 | .get("win_lines") | 254 | .get("win_lines") |
| 255 | .cloned() | 255 | .cloned() |
| 256 | .unwrap_or_else(|| "-".to_string()); | 256 | .unwrap_or_else(|| "-".to_string()); |
| 257 | let win_cells = result | ||
| 258 | .result_data | ||
| 259 | .get("win_cells") | ||
| 260 | .cloned() | ||
| 261 | .unwrap_or_else(|| "-".to_string()); | ||
| 257 | 262 | ||
| 258 | match database::apply_spin( | 263 | match database::apply_spin( |
| 259 | &mut self.conn, | 264 | &mut self.conn, |
| @@ -268,7 +273,7 @@ impl ServerCore { | |||
| 268 | Ok(new_balance) => { | 273 | Ok(new_balance) => { |
| 269 | let _ = self.sessions.remove_session(&session_id); | 274 | let _ = self.sessions.remove_session(&session_id); |
| 270 | format!( | 275 | format!( |
| 271 | "GAME_RESULT {session_id} {winnings} {bet_amount} {new_balance} {reels} {win_type} {win_lines}" | 276 | "GAME_RESULT {session_id} {winnings} {bet_amount} {new_balance} {reels} {win_type} {win_lines} {win_cells}" |
| 272 | ) | 277 | ) |
| 273 | } | 278 | } |
| 274 | Err(error) => { | 279 | Err(error) => { |
