home *** CD-ROM | disk | FTP | other *** search
/ 64'er Special 53 / 64er_Magazin_Sonderheft_53_19xx_Markt__Technik_de_Side_A.d64 / testdemo (.txt) < prev    next >
Commodore BASIC  |  2022-10-26  |  10KB  |  310 lines

  1. 1 rem *********************************
  2. 2 rem ** 'testdemo' demonstrations-  **
  3. 3 rem **  programm        fuer       **
  4. 4 rem ** 'gr2001'  -   befehle       **
  5. 5 rem ** --------------------------- **
  6. 6 rem ** dr.h.domes           (1986) **
  7. 7 rem ** josef marx str. 13          **
  8. 8 rem ** a - 8043 graz / austria     **
  9. 9 rem *********************************
  10. 20 le$="                   "
  11. 30 deffnbo(wi)=wi*2*(NULL)/360
  12. 250 goto700
  13. 300 poke198,0:wait198,1:(NULL) :return
  14. 350 (NULL)zm,x0,y0,x1,y1   :return
  15. 360 (NULL)zm,x0,y0,fnbo(wi),l1,l2:return
  16. 400 (NULL)zm,x0,y0,x1,y1,ri,sw:return
  17. 450 (NULL) zm,r,b,h,v,a,x0,y0,a$ :return
  18. 500 (NULL)zm,x1%,y1%,x2%,y2%:return
  19. 520 (NULL)hv,sz,of:return
  20. 550 ifzx<40andzy<25thenpoke214,zy:poke211,zx:sys58640
  21. 600 return
  22. 650 rem******************************
  23. 700 (NULL)1:(NULL)4,0:(NULL):print"[147][156]";chr$(8)
  24. 750 forx=0to319step8:fory=00to68step8 :(NULL)x,y,1,2:(NULL)x,199-y,1,2
  25. 800 (NULL)x,71+y,2,1:next:next:(NULL)255
  26. 900 zm=2:r=1:b=2:h=3:v=15:a=16:x0=46:y0=10:reada$:gosub450
  27. 950 :
  28. 1000 (NULL)5,2:zm=0:r=1:b=2:h=3:v=15:a=16:x0=46 :y0=40:reada$:gosub450
  29. 1050 :
  30. 1100 zm=2:r=1:b=1:h=1:v=8 :a=16:x0=30:y0=88:reada$:gosub450
  31. 1150 :
  32. 1200 zm=0:r=1:b=2:h=3:v=15:a=16:x0=46:y0=100:reada$:gosub450
  33. 1250 :
  34. 1300 (NULL)14,2
  35. 1350 zm=0:r=1:b=2:h=3:v=15:a=16:x0=46:y0=140:reada$:gosub450
  36. 1400 :
  37. 1450 zm=2:r=1:b=1:h=1:v=8 :a=8 :x0=56:y0=175:reada$:gosub450
  38. 1500 :(NULL)0,0
  39. 1550 read x1,y1,x2,y2:(NULL)0,x1,y1,x2,y2:
  40. 1600 read x1,y1,x2,y2:(NULL)0,x1,y1,x2,y2
  41. 1650 (NULL)0,0:
  42. 1660 gosub2050:poke198,0
  43. 1700 gosub50170
  44. 1710 bl=1:(NULL)0:gosub50270
  45. 1719 rem-------------------------------
  46. 1720 oni gosub 2150,2550,55000,6850,7400,52000,3800,3800,1800
  47. 1721 rem-------------------------------
  48. 1750 goto1710
  49. 1800 (NULL)255:(NULL)255:(NULL)
  50. 1810 print"[147][144]beep:l[207]"chr$(34)"gra1"chr$(34)",8":print"run"
  51. 1820 poke631,19:fori=1to3:poke631+i,13:next:poke198,4:end
  52. 2001 rem****** vorspann ***************
  53. 2050 print"[147]":(NULL):(NULL)4,0:(NULL)4,0:(NULL)0
  54. 2100 a$="demo     grafik"
  55. 2110 zm=0:r=1:b=1:h=1:v=0:a= 7:x0=01:y0=02:gosub450
  56. 2115 a$="befehle:   2001 ":y0=12:gosub450
  57. 2120 (NULL)0,0:y=0:forx=0to70step8:ifpeek(203)<>64then2140
  58. 2125 (NULL)x,y:next:print"<taste>[146]";
  59. 2130 print"":forx=70to80step2:ifpeek(203)<>64then2140
  60. 2135 (NULL)x,y:next:print"[156]":ifpeek(203)=64then2100
  61. 2140 gosub300:(NULL):return
  62. 2149 rem*****   recht   ***************
  63. 2150 (NULL):zm=0:r=1:b=1:h=1:v=0:a= 8:x0=01:y0=2:a$="recht"
  64. 2160 gosub450:(NULL)0,0:gosub300:(NULL)
  65. 2170 print"[159]":(NULL)0,0:gosub300:print"[156]"
  66. 2180 (NULL)
  67. 2199 rem*******************************
  68. 2200 y0=peek(162)and100:zm=2:yz=1:ax=2:ay=2:rem schrittweite
  69. 2250 (NULL):(NULL)1
  70. 2300 forx0=0to159stepax:y0=y0+ay*yz:ify0>199thenyz=-1:y0=y0+ay*yz:(NULL)
  71. 2350 ify0<0thenyz=1:y0=y0+ay*yz:(NULL)
  72. 2400 x1=319-x0:y1=199-y0:gosub350:next
  73. 2450 ifax<3then(NULL):ax=ax+2:goto2300
  74. 2460 gosub300:(NULL):return
  75. 2500 rem*********************************
  76. 2550 (NULL):(NULL)1:zm=0:x0=10:y0=10:  r=1:h=2:b=2:a=16:v=2
  77. 2560 a$="statistik demo":gosub450
  78. 2600 rem*********************************
  79. 2650 x0=10:y0=190:r=1:h=1:b=1:a=08:v=1
  80. 2700 t =rnd(-ti)
  81. 2750 fori=1to10:y0(i)=rnd(8)*160+30:next:rem statistikwerte
  82. 2800 fory=190to30step-16:(NULL) 0,8,y:(NULL)0,318,y:next:(NULL) 0,12,110:(NULL)0,315,110
  83. 2850 forx=42to312step28:(NULL)0,x,110:(NULL)0,x+1,110:      :next
  84. 2900 (NULL) 0,190 :(NULL)0,30:rem 0=horiz
  85. 2950 (NULL) 1,8   :(NULL)1,318:rem 1=vertik.
  86. 2960 x0=296:y0=106:r=1:h=1:b=1:a=08:v=1:zm=1:a$="   [146]":gosub450
  87. 2970 zm=0:a$="50%":gosub450
  88. 2980 a$="100%":x0=288:y0=22:gosub450
  89. 2990 z=0
  90. 3000 forx1=40to319step28:z=z+1:x0=x1-22:y0=y0(z):y1=190:yp%=100*(190.5-y0)/160
  91. 3050 gosub350
  92. 3100 a$=str$(yp%):a$=right$(a$,len(a$)-1) :y0=y1+2:x0=x0+2:
  93. 3150 :ifyp%<10thenx0=x0+8
  94. 3200 gosub450:next
  95. 3250 ri=0:sw=3
  96. 3300 gosub300:(NULL)
  97. 3350 z=0
  98. 3400 forx1=40to319step28:z=z+1:x0=x1-22:y0=y0(z):y1=190:yp%=100*(190-y0)/160
  99. 3450 gosub400:next
  100. 3500 ri=1:sw=2:gosub300
  101. 3600 z=0
  102. 3650 forx1=40to319step28:z=z+1:x0=x1-22:y0=y0(z):y1=190
  103. 3700 gosub400:next:gosub300
  104. 3710 z=0:ri=1:sw=2
  105. 3715 forx1=40to319step28:zm=2:z=z+1:x0=x1-22:y0=y0(z):y1=189
  106. 3720 gosub400:zm=0:gosub350:next
  107. 3750 gosub300:return
  108. 3800 rem******************************
  109. 3810 print"[147]":(NULL)0:(NULL)
  110. 3820 print" demonstration discreen/gtscreen[146]"
  111. 3825 print" anleitung: ";le$
  112. 3830 print"editiermodus   menuezeile: gruen[156]"
  113. 3832 print"<joystick fire>[146] : punkt setzen/loeschen"
  114. 3833 print"<return>[146]        : ---------''----------"
  115. 3834 print"<space>[146]         : setz-/ loeschmodus"
  116. 3835 print"( gesetzter punkt erscheint als [209]   )"
  117. 3836 print"[159]auswahl[156]:cursor auf gewuenschte funktion in menuezeile & <return>[146]"
  118. 3837 print"[154]gtscreen[156][146]: editierter ausschnitt wird in hires bild eingefuegt, ";
  119. 3838 print"lokalisiert durch <return>[146]/<fire>[146] dann in menuezeile aus-wahl ";
  120. 3839 print"<return>[146]".
  121. 3840 print"[158]hiresausschnitt holen : menue-zeile:gelb[156]"
  122. 3841 print"ausschnittort <return>[146]/<fire>[146] dann in   menuezeile auswahl ";
  123. 3842 print"<discreen>[146] <return>[146]."
  124. 3843 print"zm : zeichenmodus: setz/loesch/inv"
  125. 3844 print"<taste>[146][145]":gete$:ife$=""thenpoke646,f1:f1=f1+1+15*(f1>=14):goto3844
  126. 3848 rem*******************************
  127. 3849 rem****** discreen/gtscreen  *****
  128. 3850 print"[147][156]"
  129. 3860 se$(0)="reset ":se$(1)="set   "
  130. 3900 wc$=chr$(13):zm=0:r=1:b=1:h=1:v=00:a=8:x0=00:y0=00:a$="di/gt":gosub450
  131. 3950 zm=2:x0=00:y0=8:h=2:a=6:a$="screen":gosub450
  132. 4000 zm=1:y1%=8:y2%=25:forx1=0to48step6:x1%=x1:x2%=x1:gosub500:next
  133. 4050 (NULL)00,00
  134. 4100 zx=0:zy=24:gosub550
  135. 4150 print"         / gtscreen /   inv   / menue /[156]";
  136. 4200 fori=704to704+63:pokei,0:next:k=0:fori=39915to39929:poke704+k,peek(i):k=k+1:next
  137. 4350 :
  138. 4400 (NULL)1:fl=51268:bc(0)=32:bc(1)=81:k=0
  139. 4450 kk=kk+1
  140. 4500 k=k-(k=0)+(k=1):(NULL):zx=0:zy=24:gosub550:printse$(k);
  141. 4600 rem*******************************
  142. 4650 pokefl,0:(NULL)2:poke51265,8:x1%=x%/8:y1%=y%/8:fi=peek(fl)
  143. 4700 ifpeek(203)=60then4450
  144. 4720 getw$
  145. 4750 ify1%<24then5050
  146. 4800 ifx1%>32and(fiorw$=wc$)thenfi=0:return
  147. 4850 ifx1%<10and(fiorw$=wc$)thenfi=0:goto4450
  148. 4900 ifx1%>10andx1%<20and(fiorw$=wc$)thenfi=0:goto5550
  149. 4950 ifx1%>20andx1%<30and(fiorw$=wc$)thenfi=0:(NULL):gosub5300
  150. 5000 goto4650
  151. 5050 p=x1%+40*y1%:pe=peek(1024+p)
  152. 5150 iffiorpeek(203)=1thenpoke(1024+p),bc(k):poke(55296+p),4
  153. 5200 goto4650
  154. 5250 rem*****"invers********************
  155. 5300 [217]1:[204]:[227]0,0,0:[153]"wait" : [224]100,0:[233]
  156. 5320 [224]0,0:[233]:[217]1:[142]
  157. 5449 [143]*******************************
  158. 5450 [143]***** gtscreen  ***************
  159. 5500 [209]
  160. 5550 [237] 0,189:[208]1
  161. 5600 zx[178]0:zy[178]24:[141]550:[153]"sys/ zm      / gtscreen/ discreen/ menue waitclr";
  162. 5650 zx[178]5:[141]550:[153]z1;:[151]51265,8
  163. 5700 [151]fl,0:[208]2:fi[178][194](fl)
  164. 5720 [161]w$
  165. 5750 [139]fi[176]w$[178]wc$[167][141]6550
  166. 5800 [139]y%[179]190[176](fi[178]0[175]w$[179][177]wc$)[167]5700
  167. 5850 [209]:x1%[178]x%[173]8:y1%[178]y%[173]8
  168. 5900 :
  169. 5950 [139]x1%[177]0[175]x1%[179]10[167]z1[178]z1[170]1[170]3[172](z1[177][178]2):zx[178]5:zy[178]24:[141]550:[153]z1;
  170. 6000 :
  171. 6050 [139]x1%[177]10[175]x1%[179]20[175]rb[167]zm[178]2:[141]350:[227]z1,x0,y0:rb[178]0
  172. 6100 :
  173. 6150 [139]x1%[177]20[175]x1%[179]30[175]rb[167]zm[178]2:[141]350:[237]:[224]x0,y0:rb[178]0:[137]4100
  174. 6200 :
  175. 6250 [139]x1%[177]30[175]x1%[179]40[167][137]7650
  176. 6300 :
  177. 6400 [151]51265,8:[143] step 8
  178. 6450 [137]5700
  179. 6500 :
  180. 6550 [139]x%[177]279[176]y%[177]175[167][142]
  181. 6600 [139]rb[167]zm[178]2:[141]350:rb[178]0
  182. 6650 [139]rb[178]0[167]zm[178]2:x0[178]x%:y0[178]y%:x1[178]x%[170]40:y1[178]y%[170]24:[141]350:rb[178]1
  183. 6700 [151]51265,8
  184. 6750 [142]
  185. 6800 [143]****************************
  186. 6849 [143]*****   enlarg    **********
  187. 6850 [204]:[205]4,0:[237]0,190:zx[178]0:zy[178]24:[141]550
  188. 6900 [153]"demo enlarg :<taste>";:[141]300
  189. 6910 [141]6950:
  190. 6920 [129]i[178]0[164]2:[221]i:[141]300:[204]:[217]1:[130]
  191. 6930 [206]0:[209]255:[142]
  192. 6949 [143]----------"  muster -----------
  193. 6950 ax=2:ay=2:rem schrittweite
  194. 6955 y0=peek(162)/2.5:zm=2:yz=1
  195. 7000 (NULL):(NULL)1
  196. 7050 forx0=0to158stepax:y0=y0+ay*yz:ify0>90thenyz=-1:y0=y0+ay*yz:(NULL)
  197. 7100 ify0<0thenyz=1:y0=y0+ay*yz:(NULL)
  198. 7150 x1=158-x0:y1=90-y0:y1=y1*(1+(y0>90))        :gosub350:next
  199. 7200 ifax<3then(NULL):ax=ax+2:goto7050
  200. 7250 (NULL)0,0:(NULL)1:(NULL):(NULL)1:(NULL):(NULL):(NULL)1:(NULL)4,0:return
  201. 7251 rem-------------------------------
  202. 7398 rem*******************************
  203. 7399 rem**********"  mirror  **********
  204. 7400 [204]:[205]4,0
  205. 7460 zm[178]0:r[178]1:a[178]8:b[178]1:h[178]2:v[178]0:x0[178]25:y0[178]172:a$[178]"demo mirror ":[141]450
  206. 7462 x0[178]150:y0[178]100:r[178]4:[141]450
  207. 7465 r[178]1:b[178]6:h[178]6:x0[178]25:y0[178]120:a$[178]"_":[141]450
  208. 7466 [211]0,189:[211]1,159
  209. 7470 x0[178]250:y0[178]120:a$[178]"^":[141]450
  210. 7480 ax[178]4:ay[178]4:[141]6955
  211. 7500 [217]:[204]:[218]1:sz[178]40
  212. 7510 [237]0,190
  213. 7520 [129]hv[178]0[164]1:[129]of[178]0[164]3:[129]sz[178]0[164]40[169]10
  214. 7522 [237]:[206]1:[141]520:[141]7680:[237]0,190
  215. 7525 [129]uu[178]0[164]1000:[130]
  216. 7530 [204]:[218]1:[161]w$:[139]w$[178]"*"[167]hv[178]1:of[178]3:sz[178]40:[209]:[209]
  217. 7532 [130]:[130]:[130]
  218. 7535 [141]550:[153]"<taste> menue"le$;:[141]300:
  219. 7649 [143]------------------------
  220. 7650 [237]:[209]255:[142]
  221. 7651 [143]------------------------
  222. 7680 zx[178]0:zy[178]24:[141]550:[153]le$le$:[141]550
  223. 7685 [153]"mirror "hv" ,"sz" ,"of"   open<*>clrwait stop";:[142]
  224. 7699 [143] ********************************
  225. 7700 [131] grafik 2000, (c) f.brendel
  226. 7750 [131] modified by,dr.h.domes
  227. 7800 [131] grafik 2001,made in austria
  228. 7850 [131] 5,5,314,70,   5,75, 314,194
  229. 50010 :
  230. 50020 :
  231. 50030 :
  232. 50040 [151]53280,0:[151]53281,0:[153]"clr"
  233. 50050 [143]------------------------10.12.85-
  234. 50060 [143] mu$(...)auswahlbegriffe
  235. 50070 [143] tl$( ) titel fuer menueseite
  236. 50080 [143] mi(block#) index beg.block in mu$
  237. 50090 [143] "mb=maxim blockanzahl
  238. 50100 rem "ni= eingabezahl
  239. 50110 [143] "nu=untergrenze, no=obergrenze
  240. 50120 rem "data struktur:
  241. 50130 [143] "^^" blockbeginn
  242. 50140 [143] "__" datenendenn
  243. 50150 [143] "*@" zahleneingabe,nu,no
  244. 50160 [143]--------------------------------
  245. 50170 [134]mu$(80),mi(20),tl$(20)
  246. 50180 di$(0)[178]"ononon":di$(1)[178]"":di$(2)[178]"on":     di$(3)[178]""
  247. 50190 le$[178]"                    "
  248. 50200 [143]--------------------------------
  249. 50210 i[178]0:zi[178]1:[143]einlesen
  250. 50215 [135]mu$:[139]mu$[179][177]"!!"[167]50215
  251. 50220 [135]mu$
  252. 50230 [139]mu$[178]"^^"[167][135]tl$(zi):mi(zi)[178]i:     zi[178]zi[170]1:[137]50220
  253. 50240 [139]mu$[179][177]"__"[167]mu$(i)[178]mu$:i[178]i[170]1:[137]50220
  254. 50250 mi(zi)[178]i:mb[178]zi[171]1:[142]
  255. 50260 [143]--------------------------------
  256. 50270 :
  257. 50300 ib[178]mi(bl):ie[178]mi(bl[170]1)[171]1
  258. 50310 [153]"load":[151]198,0:[141]50340
  259. 50320 [209]:[209]255: [142]
  260. 50330 [143]--------------------------------
  261. 50340 [153]""tl$(bl)di$(3)
  262. 50350 [139]mu$(ib)[178]"*@"[167]50480
  263. 50360 [129]i[178]ib[164]ie:[153]mu$(i):[153]:[130]
  264. 50370 [153]""tl$(bl)di$(3):i[178]ib:
  265. 50380 [153]""mu$(i)
  266. 50390 [161]w$:[139]w$[179][177]"on"[175]w$[179][177]""[175]w$[179][177][199](13)[167]50390
  267. 50400 li[178]i:[143] letzter i wert
  268. 50410 [139]w$[178][199](13)[167]i[178]i[171]ib[170]1:[142]
  269. 50420 [139]w$[178]""[167]i[178]i[170]1:zi[178]1:[139]i[177]ie[167]i[178]ie:zi[178]2
  270. 50430 [139]w$[178]"on"[167]i[178]i[171]1:zi[178]0:[139]i[179]ib[167]i[178]ib:zi[178]2
  271. 50440 [153]"on"mu$(li):[153]di$(zi)""mu$(i)
  272. 50450 [137]50390
  273. 50460 [143]================================
  274. 50470 [143]================================
  275. 50480 nu[178][197](mu$(ib[170]1)):no[178][197](mu$(ib[170]2))
  276. 50490 [129]i[178]0[164]2:[153]""le$:[130]:[153]"onononclr"
  277. 50500 [153][163]5)"    cmdcmdcmdcmd"ni"on":[151]646,c:c[178]4
  278. 50510 [161]w$:[139]w$[178]""[167]c[178]5:ni[178]ni[170]1:[139]no[179]ni[167]ni[178]nu
  279. 50520 [139]w$[178]"cmd"[167]c[178]2:ni[178]ni[171]1:[139]ni[179]nu[167]ni[178]no
  280. 50530 [139]w$[178]""[167]c[178]2:ni[178]ni[171]10:[139]ni[179]nu[167]ni[178]no
  281. 50540 [139]w$[178]"on"[167]c[178]5:ni[178]ni[170]10:[139]no[179]ni[167]ni[178]nu
  282. 50550 [139]w$[178][199](13)[167][142]:[143]=======
  283. 50560 [137]50500
  284. 50570 [143]================================
  285. 50580 [131] "!!":[143] startflag
  286. 50590 [131] "^^",demonstration > grafik 2001 <
  287. 50600 [131] recht,block,rorecht,enlarg,mirror,sprplot,gtscreen,discreen
  288. 50610 [131] "openendeclr"
  289. 50640 [131] "__":[143] endflag
  290. 51999 [143]****" sprplot        **********
  291. 52000 (NULL)1:(NULL)
  292. 52020 fori=1to3:n$="testsprite"+right$(str$(i),1):(NULL)i,n$,8:next
  293. 52050 fory=0to150step42:forx=0to280step72              
  294. 52080 fori=1to3:(NULL)i,0,x+24*(i-1),y:next:next:next
  295. 52150 fori=4to6:n$="testsprite"+right$(str$(i),1):(NULL)i,n$,8:next
  296. 52180 fory=21to171step42:forx=0to280step72:fori=4to6
  297. 52200 (NULL)i,0,x+24*(i-4),y:next:next :next:gosub300
  298. 52300 p1=1:forii=0to40:rn=rnd(-ti):x=rnd(8)*245:y=rnd(8)*145
  299. 52303 (NULL)p1,00:p1=p1+1+15*(p1>14)
  300. 52305 (NULL)1,x,y,x+71,y+41:(NULL)0,x,y,x+71,y+41
  301. 52310 fori=1to3:(NULL)i,0,x+(i-1)*24,y:next
  302. 52315 fori=4to6:(NULL)i,0,x+(i-4)*24,y+21:next
  303. 52320 next:(NULL):(NULL)4,0:(NULL)255:return
  304. 54999 rem **** "rorecht" **************
  305. 55000 (NULL)1:(NULL)
  306. 55010 l1=50:l2=10:y1=50:y2=145:w1=0:w2=360:x2=310
  307. 55110 forx1=0to300step10:w1=w1+9:wi=w1:x0=x1:y0=y1:gosub360
  308. 55120 w2=w2-9:wi=w2:x2=x2-10:x0=x2:y0=y2:gosub360
  309. 55210 next:(NULL)255:gosub300:(NULL)0:return
  310.