Sfoglia il codice sorgente

Fixed bug where dealer has blackjack in inusrance phase but doesn't reveal it

Insurance bets were not being paid and game should have been halted after blackjack reveal since player cannot possibly win even with 21.
kirath 8 mesi fa
parent
commit
1374f66d62
1 ha cambiato i file con 4 aggiunte e 4 eliminazioni
  1. 4 4
      locations/casino.qsrc

+ 4 - 4
locations/casino.qsrc

@@ -860,10 +860,9 @@ if $ARGS[0] = 'insurance1':
 	act 'No insurance' : gt 'casino', 'insurance2'
 end
 
-if $ARGS[0] = 'insurance2':
-	if deckFace[dealerCards[1]] > 9: gs 'casino', 'blackjack_view', 1
-	if deckFace[dealerCards[1]] < 10: gs 'casino', 'blackjack_view'
-	if dealerPoints = 21:
+if $ARGS[0] = 'insurance2': 
+	if dealerPoints = 21 or deckFace[dealerHand[1]] > 9:
+        gs 'casino', 'blackjack_view', 1
 		*pl 'DEALER WINS'
 		*p 'The dealer takes your <<playerBets[0]>> <b>₽</b> bet'
 		if insurance > 0: *p ' but also gives you <<insurance>> <b>₽</b> for your side bet'
@@ -872,6 +871,7 @@ if $ARGS[0] = 'insurance2':
 		money += insurance
 		act 'Continue' : gt 'casino', 'blackjack_play'
 	else
+      	gs 'casino', 'blackjack_view'
 		*pl 'The dealer takes a peek at his hole card; no blackjack.'
 		if insurance > 0: *p 'He relieves you of <<insurance>> <b>₽</b> for your side bet.'
 		money -= insurance