home *** CD-ROM | disk | FTP | other *** search
/ Loadstar 221 / 221.d81 / b.schotz.mak (.txt) < prev    next >
Commodore BASIC  |  2022-08-26  |  1KB  |  58 lines

  1. 10 dv=peek(186):ifdv<8thendv=8
  2. 20 dima(12,8),oa(12*8),ob(12*8)
  3. 25 print"[147]"
  4. 30 gosub1000 :
  5. 35 ct=0
  6. 40 geta$:ifa$=""then40
  7. 41 ifa$=chr$(13)then200
  8. 42 ifa$>="a"anda$<="c"thena=asc(a$)-55:goto45
  9. 43 a=val(a$)
  10. 44 ifa=0then40
  11. 45 printa;
  12. 50 getb$:ifb$=""then50
  13. 51 ifb$>="a"andb$<="c"thenb=asc(b$)-55:goto55
  14. 52 b=val(b$)
  15. 53 ifb=0then50
  16. 55 printb;
  17. 60 getc$:ifc$=""then60
  18. 65 ifc$=chr$(13)then90
  19. 66 ifc$<"1"orc$>"5"then60
  20. 70 printc$
  21. 75 ifa(a,b)>0thengosub100:ifer>0then90
  22. 77 oa(ct)=a:ob(ct)=b:ct=ct+1
  23. 80 a(a,b)=val(c$)
  24. 90 gosub1000:goto40
  25. 100 er=0:ifb<2thener=1:return
  26. 105 fory=1tob-1:a(a,y)=a(a,y+1):next
  27. 110 return
  28. 200 print"1. remove":print"2. save":print"3. load"
  29. 210 getz$:ifz$=""then210
  30. 220 ifz$<"1"orz$>"3"then210
  31. 230 onval(z$)goto300,400,500
  32. 300 ifct=0then340
  33. 310 ct=ct-1
  34. 320 fory=ob(ct)to1step-1:a(oa(ct),y)=a(oa(ct),y-1):next
  35. 340 print"[147]":gosub1000:goto40
  36. 400 inputf$
  37. 410 open1,dv,15,"r0:"+f$+"="+f$:input#1,en:close1
  38. 420 ifen=62then450
  39. 430 printf$" exists. replace (y/n)
  40. 435 [161]z$:[139]z$[178]""[167]435
  41. 440 [139]z$[179][177]"y"[167]340
  42. 445 [159]1,dv,15,"s0:"[170]f$:[160]1
  43. 450 [159]4,dv,4,f$[170]",s,w"
  44. 460 [129]y[178]1[164]8:[129]x[178]1[164]12:[152]4,a(x,y):[130]:[130]:[152]4,ct
  45. 470 [129]x[178]0[164]ct:[152]4,oa(x):[152]4,ob(x):[130]:[160]4:[137]340
  46. 500 [133]f$:[159]1,dv,15,"r0:"[170]f$[170]"="[170]f$:[132]1,en:[160]1
  47. 510 [139]en[178]62[167][153]"file not found":[151]198,0:[146]198,1:[137]340
  48. 520 [159]4,dv,4,f$
  49. 530 [129]y[178]1[164]8:[129]x[178]1[164]12:[132]4,a(x,y):[130]:[130]:[132]4,ct
  50. 535 [129]x[178]0[164]ct:[132]4,oa(x):[132]4,ob(x):[130]:[160]4:[137]340
  51. 999 [128]
  52. 1000 [153]"sys    1  2  3  4  5  6  7  8  9  a  b  c
  53. 1005 fory=1to8:print"[158]"y"[154]";:    forx=1to12
  54. 1010 printa(x,y);:next:print:next
  55. 1030 print"          ":print"         [145][145]":return
  56. 9999 end
  57. 10000 d=peek(186):n$="shotz.mak":open1,d,15,"s0:"+n$:close1:saven$,d:end
  58.