408_igrkart2 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175
  1. # igrkart2
  2. clr
  3. gs 'stat'
  4. set minut += 5
  5. if turn1 = 0:
  6. CLA
  7. '<right><img src="images\casino\stavkacw.jpg"></right>'
  8. ' Please give me your bets, gentlemen.'
  9. ACT 'IPod':
  10. deal = input 'Enter the amount'
  11. if money < deal:
  12. msg 'You have enough money'
  13. gt 'igrkart2'
  14. end
  15. if deal < 0:
  16. msg 'Wrong, try again.'
  17. gt 'igrkart1'
  18. end
  19. if deal > 1000:
  20. msg 'The maximum rate of 1000 rubles.'
  21. gt 'igrkart1'
  22. end
  23. set money -= deal
  24. turn1 = 1
  25. GT 'igrkart2'
  26. END
  27. ACT 'Move away from the table':
  28. GT 'kazvar'
  29. END
  30. end
  31. if turn1 = 1:
  32. CLA
  33. '<right><img src="images\casino\stavkacw.jpg"></right>'
  34. nich = 0
  35. ACT 'Put another draw':
  36. if money < deal:
  37. msg 'You have enough money'
  38. turn1 = 2
  39. nich = 0
  40. gt 'igrkart2'
  41. end
  42. set money -= deal
  43. turn1 = 2
  44. nich = 1
  45. gt 'igrkart2'
  46. end
  47. ACT 'Continue without an additional rate':
  48. turn1 = 2
  49. nich = 0
  50. gt 'igrkart2'
  51. end
  52. end
  53. if turn1 = 2:
  54. CLA
  55. '<right><img src="images\casino\cartcw.jpg"></right>'
  56. ' The dealer deals the cards:'
  57. '...'
  58. suit = RAND(1,4)
  59. number = RAND(1,13)
  60. $di_card[1] = $number[number] + $suit[suit]
  61. di_points = points[number]
  62. di_poi = number
  63. suit = RAND(1,4)
  64. number = RAND(2,14)
  65. $pl_card[1] = $number[number] + $suit[suit]
  66. pl_points = points[number]
  67. pl_poi = number
  68. wait 1000
  69. 'Map of dealer:'
  70. '  <<$di_card[1]>>'
  71. '__________________________'
  72. 'Player Maps:'
  73. '  <<$pl_card[1]>>'
  74. if di_poi > pl_poi:
  75. ' '
  76. 'Casinos won'
  77. act 'You lost':
  78. turn1 = 0
  79. gt 'igrkart2'
  80. end
  81. end
  82. if di_poi < pl_poi:
  83. ' '
  84. 'You won'
  85. act 'You have won <<2*deal>> rub.':
  86. set money += 2 * deal
  87. turn1 = 0
  88. gt 'igrkart2'
  89. end
  90. end
  91. if di_poi = pl_poi:
  92. if nich = 1:
  93. ' '
  94. 'You won'
  95. act 'You have won <<11*deal>> rub.':
  96. set money += 11 * deal
  97. turn1 = 0
  98. gt 'igrkart2'
  99. end
  100. else
  101. turn1 = 3
  102. gt 'igrkart2'
  103. end
  104. end
  105. end
  106. if turn1 = 3:
  107. act 'Continue to play':
  108. if money < deal:
  109. msg 'You have enough money'
  110. gt 'igrkart2'
  111. end
  112. set money -= deal
  113. CLA
  114. '<right><img src="images\casino\cartcw.jpg"></right>'
  115. ' The dealer deals the cards:'
  116. '...'
  117. suit = RAND(1,4)
  118. number = RAND(1,13)
  119. $di_card[2] = $number[number] + $suit[suit]
  120. di_points = points[number]
  121. di_poi = number
  122. suit = RAND(1,4)
  123. number = RAND(2,14)
  124. $pl_card[2] = $number[number] + $suit[suit]
  125. pl_points = points[number]
  126. pl_poi = number
  127. wait 1000
  128. 'Map of dealer:'
  129. '  <<$di_card[1]>>'
  130. '  <<$di_card[2]>>'
  131. '__________________________'
  132. 'Player Maps:'
  133. '  <<$pl_card[1]>>'
  134. '  <<$pl_card[2]>>'
  135. if di_poi > pl_poi:
  136. ' '
  137. 'Casinos won'
  138. act 'You lost':
  139. turn1 = 0
  140. gt 'igrkart2'
  141. end
  142. end
  143. if di_poi < pl_poi:
  144. ' '
  145. 'You won'
  146. act 'You have won <<4*deal>> rub.':
  147. set money += 4 * deal
  148. turn1 = 0
  149. gt 'igrkart2'
  150. end
  151. end
  152. if di_poi = pl_poi:
  153. ' '
  154. 'Again draw'
  155. act 'Pick up <<3*deal>> rub.':
  156. set money += 3 * deal
  157. turn1 = 0
  158. gt 'igrkart2'
  159. end
  160. end
  161. end
  162. act 'Pick up half your bet':
  163. if deal mod 2 = 1:
  164. deal = deal + 1
  165. end
  166. set money += deal/2
  167. gt 'igrkart2'
  168. end
  169. end
  170. --- igrkart2 ---------------------------------