home *** CD-ROM | disk | FTP | other *** search
/ Ahoy 1985 July / Ahoy_Magazine_85-07_1985_Double_L.d64 / luck lotto (.txt) < prev    next >
Encoding:
Commodore BASIC  |  1985-01-01  |  5.3 KB  |  166 lines

  1. 30 l$=""
  2. 40 gosub 1000:goto 1500
  3. 50 dim num(45),tn(nn),pf(nn):c=0:b=0
  4. 70 print "[147]":poke 53280,6:poke 53281,1
  5. 80 print left$(l$,2)tab(8)"[151][176][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][174]"
  6. 90 print left$(l$,3)tab(8)"[194]                     [194]"
  7. 100 print left$(l$,4)tab(8)"[194]  lucky lotto menu[151]   [194]"
  8. 120 print left$(l$,5)tab(8)"[194]                     [194]"
  9. 125 print left$(l$,6)tab(8)"[173][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][189]"
  10. 130 print left$(l$,10)tab(8)"[1][146] -load number file"
  11. 140 print left$(l$,11)tab(8)"[2][146] -enter current numbers"
  12. 150 print left$(l$,12)tab(8)"[3][146] -display all numbers"
  13. 160 print left$(l$,13)tab(8)"[4][146] -6 most common numbers"
  14. 170 print left$(l$,14)tab(8)"[5][146] -end session"
  15. 175 print left$(l$,20)tab(10)"your choice ? [1-5][146]"
  16. 180 get an$:if an$="" then180
  17. 190 an=val(an$)
  18. 200 on an gosub 730,220,310,420,660
  19. 210 rem =========================
  20. 211 rem ****  input numbers  ****
  21. 212 rem =========================
  22. 220 print "[147]":poke 53280,12:poke 53281,1
  23. 230 print tab(4)"[213][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][201]"
  24. 240 print tab(4)" enter this weeks lotto numbers "
  25. 250 print tab(4)"[145][202][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][203]"
  26. 260 print left$(l$,8):t=6
  27. 270 for a=1 to 6:print tab(10)"number ";a;:input n(a)
  28. 280 for s=1 to nn:if n(a)=s then630
  29. 290 next:next
  30. 301 goto70
  31. 304 rem =========================
  32. 305 rem **** display numbers ****
  33. 306 rem =========================
  34. 310 print "[147]":poke 53280,3:poke 53281,1:t=4
  35. 320 print tab(6)"[145] current lotto number list "
  36. 330 for s=1 to nn:if s=23 thenprint "":t=24
  37. 350 if s>9 then370
  38. 360 print ""tab(t);s" "tn(s):goto380
  39. 370 print ""tab(t-1);s" "tn(s)
  40. 380 next
  41. 390 printleft$(l$,25)"[151]  press  f1 [146] for 6 most common numbers";
  42. 400 get an$:if an$="" then400
  43. 410 if an$<>"[133]" then400
  44. 414 rem ========================
  45. 415 rem **** common numbers ****
  46. 416 rem ========================
  47. 420 for i=1 to nn:if tn(i)>b thenb=tn(i)
  48. 430 next
  49. 445 print"[147]":poke 53280,6:poke 53281,1
  50. 450 print left$(l$,1)tab(8)" 6 most common numbers "
  51. 460 print left$(l$,3)tab(12)"number";tab(22)"times"
  52. 470 for e=1 to 6:sw=0
  53. 480 if b<=0 then540
  54. 490 for i=1 to nn:t=14
  55. 495 if i>9 then t=13
  56. 500 if tn(i)=b then print tab(t);i;spc(7);tn(i):sw=1
  57. 510 next
  58. 520 if sw=0 thenb=b-1:goto480
  59. 530 b=b-1
  60. 540 next e
  61. 550 printleft$(l$,22)tab(5)"press [144]f1[146] to enter more numbers"
  62. 560 print tab(5)"press [144]f3[146] to view all numbers"
  63. 570 print tab(5)"press [144]f5[146] for main menu";
  64. 580 get a$:if a$="" then580
  65. 590 if a$="[133]" then220
  66. 600 if a$="[134]" then310
  67. 610 if a$="[135]" then 70
  68. 620 if a$<>"[133]" or a$<>"[134]" or <>"[135]" then580
  69. 630 tn(s)=tn(s)+1:goto290
  70. 640 rem ========================
  71. 650 rem ****  write routine ****
  72. 660 rem ========================
  73. 670 open 2,8,2,"@0:"+nf$+",s,w"
  74. 680 for s=1 to nn
  75. 690 print#2,tn(s)
  76. 700 next
  77. 710 close 2:end
  78. 715 rem ========================
  79. 720 rem ****  read routine  ****
  80. 725 rem ========================
  81. 730 print"[147]":poke 53280,6:poke 53281,6
  82. 735 print left$(l$,10)tab(10)"loading number file..."
  83. 736 print left$(l$,12)tab(11)"one moment please"
  84. 740 open 2,8,2,"@0:"+nf$+",s,r"
  85. 750 for s=1 to nn
  86. 760 input#2,tn(s)
  87. 770 next s
  88. 780 close 2:goto 70
  89. 990 rem ==========================
  90. 991 rem ****  sprite movement ****
  91. 992 rem ==========================
  92. 1000 for s=50880 to 51116:read a:poke s,a:next
  93. 1010 data 169,255,45,0,198,240,16,169,0,141,0,198,162,21,189,0
  94. 1020 data 197,157,0,198,202,208,247,162,1,169,1,141,80,197,173,80
  95. 1030 data 197,45,0,197,240,3,76,243,198,232,232,14,80,197,208,238
  96. 1040 data 76,49,234
  97. 1050 data 169,0,29,0,197,208,3,76,97,199,169,128,61
  98. 1060 data 0,197,240,48,254,0,198,208,40,222,255,207,76,144,199,80
  99. 1070 data 197,45,16,208,208,12,173,16,208,13,80,197,141,16,208,76
  100. 1080 data 43,199,173,16,208,77,80,197,141,16,208,189,0,197,157,0
  101. 1090 data 198,76,97,199,222,0,198,208,40,254,255,207,208,29,173,80
  102. 1100 data 197,45,16,208,208,12,173,16,208,13,80,197,141,16,208,76
  103. 1110 data 91,199,173,16,208,77,80,197,141,16,208,189,0,197,157,0
  104. 1120 data 198,169,0,232,29,0,197,208,3,76,140,199,169,128,61,0
  105. 1130 data 197,240,11,254,0,198,208,20,222,255,207,76,134,199,222,0
  106. 1140 data 198,208,9,254,255,207,189,0,197,157,0,198,202,76,233,198
  107. 1150 data 169,255,221,255,207,240,3,76,43,199,173,80,197,76,17,199
  108. 1160 data 120,169,192,141,20,3,169,198,141,21,3,88,96
  109. 1170 sp=53248:ss=50433:print "[147]":poke 53280,9:poke 53281,0
  110. 1180 h=1:v=1
  111. 1190 for l=ss to ss+16 step 2
  112. 1200 poke l,h:poke l+1,v
  113. 1210 h=int(rnd(0)*247)+1:v=int(rnd(0)*3)+1:next
  114. 1220 poke 50688,ff
  115. 1230 for s=2040 to 2047
  116. 1240 poke s,14:next
  117. 1250 for s=896 to 959:read ch
  118. 1260 poke s,ch:next
  119. 1270 s=1
  120. 1280 for l=53287 to 53293
  121. 1290 poke l,s:s=s+1:next:poke 53294,14
  122. 1310 s=20:a=30
  123. 1320 for l=53248 to 53263 step 2
  124. 1330 poke l,s+48:poke l+1,a+40
  125. 1340 s=s+25:a=a+25:next
  126. 1350 poke 53269,255
  127. 1360 poke 50432,255
  128. 1370 sys 51104
  129. 1380 return
  130. 1384 rem ======================
  131. 1385 rem ****  sprite data ****
  132. 1386 rem ======================
  133. 1390 data 1,129,128,63,255,252,127,255,254,255,255,255,255,255,255
  134. 1400 data 241,129,128,241,129,128,241,129,128,255,255,252,255,255,254
  135. 1410 data 127,255,255,63,255,255,1,129,143,1,129,143,1,129,143,255,255,255,255
  136. 1420 data 255,255,127,255,254,63,255,252,1,129,128,1,129,128,0
  137. 1500 print:print:print tab(4)"[153]$[146]           $[146]"
  138. 1510 print tab(4)"$[146]           $[146]"
  139. 1520 print tab(4)"$[146]    [146]  [146]     $[146]      "
  140. 1530 print tab(4)"$$$[146]  [146]  [146]     $$$[146]  [146]  "
  141. 1540 print tab(8)" [146]  [146]    [146]      [146]  [146]    "
  142. 1550 print tab(8)"   [146]  [146]          [146]   "
  143. 1560 print tab(12)" [146]    [169] [146]       [146]     "
  144. 1570 print tab(12)"   [146]   [146][169]       [146]    "
  145. 1580 print tab(16)"  [223][146]  [146]  [146]       [146]     "
  146. 1590 print tab(16)" [146][223] [146]    [146]       [146]   [146]  "
  147. 1600 print tab(21)" [146]           [146]  "
  148. 1610 print tab(21)" [146]             "
  149. 1620 print:print "[175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175]"
  150. 1630 print "[145][149]                  [144] [149]                     "
  151. 1640 print "[145]           double[149] [144]  [149] software[149]            "
  152. 1650 print "[145]                   [144]  [149]                   "
  153. 1660 print "[145][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183]"
  154. 1670 print tab(10)"[145][149]designed by..."
  155. 1680 print tab(19)"bob lloret"
  156. 1690 print:print tab(11)"press f1 to start";
  157. 1700 get a$:if a$="" then 1700
  158. 1710 if a$="[133]" then for a=sp to sp+7:poke sp+21,0:next:goto 2000
  159. 1720 if a$<>"[133]" then 1700
  160. 2000 print"[147]"
  161. 2010 printleft$(l$,10)" enter your file name";:input nf$
  162. 2015 if nf$="" then 2010
  163. 2020 printleft$(l$,12)" enter highest number in your lotto";:input nn
  164. 2025 if nn<1 then 2020
  165. 2030 goto50
  166.