home *** CD-ROM | disk | FTP | other *** search
/ 64'er Special 21 / 64er_Magazin_Sonderheft_21_19xx_Markt__Technik_de_Side_B.d64 / library (.txt) < prev    next >
Commodore BASIC  |  2022-10-26  |  2KB  |  64 lines

  1. 50000 rem ********************
  2. 50010 rem * library v 1.0    *
  3. 50020 rem * zusammengestellt *
  4. 50030 rem *       von:       *
  5. 50040 rem *  thomas  kolbe   *
  6. 50050 rem ********************
  7. 50060 :
  8. 50100 \proc cls:print"[147]";:\end
  9. 50110 :
  10. 50150 \proc cursor x,y
  11. 50160 poke781,y:poke782,x:poke783,peek(783)and254:sys65520
  12. 50170 \end
  13. 50180 :
  14. 50200 \proc prtat x,y,a$:!cursor x,y:printa$;:\end
  15. 50210 :
  16. 50220 \proc waitkey #zq$,er$,modus:\var i:ifmodusthenprint" [146][157]";
  17. 50230 getzq$:ifzq$=""then50230
  18. 50235 if er$=""then 50245
  19. 50240 !position zq$,er$,i:ifi=0 then 50230
  20. 50245 ifmodusthenprintzq$;
  21. 50250 \end
  22. 50260 :
  23. 50300 \proc position a$,b$,#zq
  24. 50310 forzq=1to(len(b$)-len(a$)+1)
  25. 50320 ifa$<>mid$(b$,zq,len(a$))then:nextzq:zq=0
  26. 50330 \end
  27. 50340 :
  28. 50350 \proc clreol:\var i
  29. 50360 i=40-peek(211)
  30. 50370 printleft$("                                        ",i);:\end
  31. 50380 :
  32. 50400 \proc linie a:for a=ato1step-1:print"[164]";:nexta:\end
  33. 50410 :
  34. 50450 \proc color ra,hi:poke53280,ra:poke53281,hi:\end
  35. 50460 :
  36. 50500 \proc center a$
  37. 50510 !prtat int((40-len(a$))/2),peek(214),a$:\end
  38. 50520 :
  39. 50550 \proc fetch #zy$,l:\var i,t$:zy$=""
  40. 50560 !linie l:fori=1tol:print"[157]";:nexti
  41. 50570 print" [146][157]";
  42. 50575 !waitkey t$,"",0
  43. 50580 ift$>=" "andt$<="_"andl>len(zy$)thenprintt$;:zy$=zy$+t$:goto50570
  44. 50590 ift$=chr$(20)andlen(zy$)>0thenzy$=left$(zy$,len(zy$)-1):print"[157] [164][157][157]";
  45. 50600 ift$=chr$(20)then50570
  46. 50610 ift$<>chr$(13)then50575
  47. 50620 print"[164]":\end
  48. 50630 :
  49. 50650 \proc lprint sek,a$:open 1,4,sek:print#1,a$:close1:\end
  50. 50660 :
  51. 50670 \proc status #qn,#qe$,#qt,#qs:close15:open15,8,15
  52. 50680 input#15,qn,qe$,qt,qs:close15:\end
  53. 50690 :
  54. 50700 \proc beep h,l:\var i:poke54296,15:poke54295,0:poke54272,h-int(h/256)*256
  55. 50710 poke54273,h/256:poke54277,26:poke54278,230:poke54276,33
  56. 50720 fori=1tol:nexti:poke54276,32:\end
  57. 50730 :
  58. 50740 \proc catalog:\var a$,b$:close3
  59. 50750 open3,8,0,"$":get#3,a$,a$
  60. 50760 get#3,a$,a$:ifst=64thenclose3:\end
  61. 50770 get#3,a$,b$:printmid$(str$(asc(a$+chr$(0))+256*asc(b$+chr$(0))),2)" ";
  62. 50780 get#3,a$:printa$;:ifa$<>""then50780
  63. 50790 print:goto50760
  64.