home *** CD-ROM | disk | FTP | other *** search
/ Loadstar 54 / 054.d81 / challenge (.txt) < prev    next >
Commodore BASIC  |  2022-08-26  |  3KB  |  89 lines

  1. 10 ifa=1 then 60
  2. 20 poke53281,0:poke53280,12:pl=0
  3. 50 ifa=0thena=1:load"challenge.o",8,1
  4. 60 :
  5. 70 s=54272:v=53248:poke53276,255:pokev+27,255:pokev+16,0:pokev+28,0
  6. 80 forn=stos+24:poken,0:next:pokes+5,144
  7. 85 pokes+6,251:poke49378,2:poke49380,1
  8. 90 forn=0to6:x=212-28*n:poke49153+n,x
  9. 95 poke49161+n,x-21:poke53248+n*2,30+n*30
  10. 100 poke53249+n*2,230:next:poke53262,240:poke49152,240:poke49160,219
  11. 110 poke53263,230:forn=0to3:poke2040+n,255
  12. 115 pokev+39+n,1:next:forn=4to7:poke2040+n,254:pokev+39+n,2:next
  13. 120 poke646,peek(53281)-1:poke49383,0
  14. 130 poke49374,1:poke53269,0
  15. 140 print"[147]"chr$(142)"          1 [146] [152]-[154] knight's challenge"
  16. 141 print"          2 [146] [152]- [154]color challenge"
  17. 150 print" [155]         please choose (1 or 2) [146]";:poke198,0
  18. 160 getk$:ifk$=""then160
  19. 170 ifk$<>"1"andk$<>"2"then120
  20. 180 print"[147]  [155]  please choose difficulty level"
  21. 190 print"[154]    pick a number from  1 [146][154] (easy)"
  22. 195 print "                    to  3 [146][154] (hard)"
  23. 200 getk1$:ifk1$=""then200
  24. 210 k=asc(k1$)-48:ifk<1ork>3then200
  25. 220 ifk$="1"thengosub400:poke829,peek(53281)
  26. 230 ifk$="2"thengosub600
  27. 240 ifpl=0then:sys16385:pl=1
  28. 250 poke49377,1:ifpl=1thenpoke174,71:poke175,4
  29. 260 poke49396,3:print"[147]"spc(7)"let the challenge begin!"
  30. 270 printspc(8)"(use joystick port2)"
  31. 275 print"your challenge is to duplicate"
  32. 280 printspc(12)"this pattern"
  33. 285 print"press  f7 [146] during game to see"
  34. 290 printspc(12)"this solved puzzle"
  35. 295 print"  press space bar to begin":c=0
  36. 300 c=(1-c):poke53269,c*255:forn=1to100
  37. 305 if peek(197)<>60then next n:goto300
  38. 310 n=100:next
  39. 320 if peek(197)<>64 then320
  40. 330 print"[147]shuffling pattern":poke53269,0:poke49383,1
  41. 335 for n=1 to 200:next n
  42. 340 poke53281,peek(53281)+1:print"[147]":poke53281,peek(53281)-1:poke1095,31
  43. 350 forn=1499to1503:poken,48:next
  44. 360 poke646,peek(53281)+1
  45. 370 poke49374,0:print""spc(34)" moves"
  46. 375 poke53269,255:poke49377,0:poke49379,0
  47. 380 ifpeek(49379)=1thenpoke49377,1:goto700
  48. 381 geta$:ifa$="q"then pokes+24,.:goto120
  49. 390 goto380
  50. 400 ifpl=1then poke53281,peek(829):goto550
  51. 410 poke53269,255
  52. 420 poke646,peek(53281)+1
  53. 430 print"[147]"spc(10)" to change colors "
  54. 435 printspc(9)" press function keys"
  55. 440 print" f1 [146] changes screen color"
  56. 445 print" f3 [146] changes background color"
  57. 450 print" f5 [146] changes chesspiece 1 color"
  58. 460 print" f7 [146] changes chesspiece 2 color"
  59. 470 print" press space bar to start"
  60. 480 getk2$:ifk2$=""then480
  61. 490 if k2$=" "thenprint"[147]":goto550
  62. 500 ifk2$="[133]"thenx=peek(53281)+1:gosub680:poke53281,x:goto420
  63. 510 ifk2$="[134]"thenx=peek(53280)+1:gosub680:poke53280,x
  64. 520 ifk2$="[135]"thengosub640
  65. 530 ifk2$="[136]"thengosub660
  66. 540 goto480
  67. 550 print" please wait...":forr=0to6:co=peek(49378):sh=0:forc=0to7
  68. 560 ifc>3thenco=peek(49380):ifk=1thensh=1
  69. 570 ifk=2thensh=int(c/2)+2*(c>3)
  70. 580 ifk=3thensh=c+4*(c>3)
  71. 590 poke49170+c+r*8,co:poke49226+c+r*8,255-sh:next:next:return
  72. 600 print" please wait...":forr=0to6:co=0:forc=0to7
  73. 605 ifk=1thenifc>3thenco=1
  74. 610 ifk=2thenco=int(c/2)
  75. 620 ifk=3thenco=c
  76. 630 poke49170+c+r*8,co+1:poke49226+c+r*8,251:next:next
  77. 635 forn=16064to16127:poken,255:next:poke53281,0:return
  78. 640 forn=0to3:x=peek(v+39+n)+1:ifx>255thenx=0
  79. 650 pokev+39+n,x:next:poke49380,x:return
  80. 660 forn=4to7:x=peek(v+39+n)+1:ifx>255thenx=0
  81. 670 pokev+39+n,x:next:poke49378,x:return
  82. 680 ifx>253thenx=0
  83. 690 return
  84. 700 pokes+24,15:forj=0to1:restore:forj1=1to15:readhf,lf:poke53269,lf
  85. 710 pokes+1,hf:pokes,lf:pokes+4,33-j*16:forn=1to80:next:pokes+4,32-j*16
  86. 720 forn=1to100:next:next:forn=1to100:next:next:pokes+24,0:goto120
  87. 730 data21,31,21,31,22,96,25,30,25,30,22,96,21,31,18,209,16,195,16,195
  88. 740 data18,209,21,31,21,31,18,209,18,209
  89.