home *** CD-ROM | disk | FTP | other *** search
/ Digital Talk 63 / Digital_Talk_63_2003-10-28_Digital_Talk_de_Side_B.d64 / !kht-fileprint02 (.txt) next >
Commodore BASIC  |  2023-02-26  |  6KB  |  225 lines

  1. 1 print"[147]"
  2. 2 rem - kht-fileprint02 140703 -
  3. 3 printtab(12)"!kht-fileprint02[146]":print"[154] bitte warten -- dateien werden geladen"
  4. 12 if peek(56)=149 then 26
  5. 14 f=peek(187)+256*peek(188)
  6. 16 if peek(f)<>77 and peek(f+1)<>67 and peek(f+2)<>50 then load "mc1.obj",8,1
  7. 18 poke 55,0:poke 56,149:clr:load "mc2.obj",8,1
  8. 26 io=38912:cr=io+6
  9. 28 da=io+12:de=io+15
  10. 30 vl=io+24
  11. 48 tr=39888:ma=tr:fs=tr+3
  12. 68 pi=50960:wi=pi+3:pu=pi+6
  13. 80 ei=50176:qu=52240
  14. 84 ch=53039:gc=38144
  15. 104 sysfs:sysma:sysch:syspi
  16. 114 printchr$(14)chr$(8)
  17. 119 poke2,0
  18. 120 rem n$="commodore.cod,p,r"
  19. 122 n$="khtpr02.cod,p,r"
  20. 123 sys vl,n$,1792,1792+256
  21. 142 al$="qwertyuiopasdfghjklzxcvbnm[209][215][197][210][212][217][213][201][207][208][193][211][196][198][199][200][202][203][204][218][216][195][214][194][206][205]"
  22. 144 al$=al$+":;@[][186],./<>?=*^[192]1234567890+-\[169]!#$%&'() "+chr$(34)
  23. 152 e1$=chr$(13)+chr$(17)+chr$(145)+chr$(133)+chr$(134)+chr$(137)+chr$(138)
  24. 154 e2$=chr$(13)+chr$(137)
  25. 162 fa=128:dimv$(fa):sz=1
  26. 172 a$(1)=" ([198]1)=[211]eite vor     ([198]5)=[204][207][193][196]-[196]atei"
  27. 174 a$(2)=" ([198]2)=[211]eite zur@ck  ([198]6)=[211][193][214][197]-[196]atei"
  28. 176 a$(3)=" ([198]7)=[196]rucken       ([198]8)=[211]chliessen"
  29. 180 b$(1)="[196]ateiname>"
  30. 184 c$(1)=" ([198]1)=[193]b hier   ([198]2)=[193]bbruch"
  31. 186 c$(2)=" ([198]3)=[206]ur diese [211]eite"
  32. 232 print"[147]":poke53280,5:poke53281,9:poke646,7
  33. 234 printtab(7)"[200]allo, liebe [195]64er-freaks!"
  34. 235 printtab(7)"[129][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162][162]"
  35. 236 print"[158][196]ieses ist ein kleines selbsterdachtes"
  36. 237 print"[208]rint-[208]rogramm,  das u.a. mit ein paar"
  37. 238 print"[205][195]-[210]outinen arbeitet,  die in dem [194]uch"
  38. 240 print"von  [205]arkt&[212]echnik  zum [195]64/[195]128 unter"
  39. 242 print"dem [212]itel '[208][210][207][198][201]-[212][207][207][204][211]' ver:ffentlicht"
  40. 244 print"wurden."
  41. 250 print"[205]it diesem  [208]rogramm  sollen  einzelne"
  42. 252 print"[211]eiten v. [196][212]-[197][196][201][212][207][210]-[212]exten konvertiert"
  43. 254 print"auf den [196]rucker ausgegeben werden."
  44. 260 print"[208]roblemstellung aus dem [208]rogramm>"
  45. 262 print"[218]ur entsprechenden [193]npassung des ange-"
  46. 263 print"schlossenen  [196]ruckers  sind  eventuell"
  47. 264 print"noch [208]rogramm-]nderungen in den [218]eilen"
  48. 265 print"ab 702 u.im [208]rinter-[218]eichensatz n:tig.":gosub902
  49. 272 print"[147][158][208]rogramm-[193]nfang    mit    '[193][158]'"
  50. 273 print"[129]([201]ntro-[194]ildschirm)
  51. 274 [153]"sys(NULL)tart als (NULL)oter    mit    '(NULL)sys'"
  52. 275 [153]"for(valdit-(NULL)creen leer)
  53. 278 print"[158][218]um [212]ext/[205]enues    mit   '[198]1[158]'"
  54. 279 print"[215]enn n:tig zur@ck  mit   '[198]2[158]'"
  55. 280 r$="":getr$:ifr$=""then280
  56. 282 ifr$<>"a"andr$<>"s"andr$<>chr$(133)andr$<>chr$(137)then280
  57. 284 on-(r$="a")-2*(r$="s")goto232,302
  58. 286 on-(r$=chr$(133))-2*(r$=chr$(137))goto290,232
  59. 290 ifpg%<>1then302
  60. 292 vs=val(vs$):goto402
  61. 302 la$="":nr%=1:mo=0:i=1:as=0:pg%=1
  62. 304 vd$="":vf$="":vs$="":vs=0
  63. 306 e$=e1$:gosub362
  64. 308 fori=0tofa:v$(i)="":next:goto402
  65. 340 gosub380
  66. 342 sys ei,0,i,40,v$(i+as),al$,e$,la$,nr%,mo,e%
  67. 350 ifla$=chr$(17)then370
  68. 351 ifla$=chr$(145)andi>1theni=i-1
  69. 352 ifla$=chr$(29)andi<16theni=i+1:nr%=1
  70. 353 ifla$=chr$(157)andi>1theni=i-1:nr%=40
  71. 354 ifla$=chr$(133)thengosub362:goto510
  72. 355 ifla$=chr$(134)theni=16:goto340
  73. 357 ifla$=chr$(137)thengosub362:goto376
  74. 358 ifla$=chr$(138)theni=1:goto340
  75. 360 ifla$=chr$(13)then370
  76. 361 goto340
  77. 362 l1$=la$:n1%=nr%:i1=i:return
  78. 370 ifi>15andas>111then374
  79. 372 i=i+1
  80. 373 ifi>16andas<112thenas=as+16:i1=1:goto402
  81. 374 nr%=1:goto340
  82. 376 as=0:i1=1:nr%=1:goto272
  83. 380 z1$=str$(i):ifval(z1$)>9then384
  84. 382 z1$=" "+z1$
  85. 384 z$=mid$(z1$,2)
  86. 386 sys cr,36,0:print"[155]"z$"[158]":return
  87. 390 sz=int(as/16+1)
  88. 392 s1$=str$(sz)
  89. 394 s$=mid$(s1$,2)
  90. 396 sys cr,28,0:print"[155]"s$"[158]":return
  91. 402 gosub914:gosub662:gosub930
  92. 410 sys cr,0,1:j=1+as
  93. 412 printv$(j)
  94. 414 fori=j+1toj+15
  95. 415 k=len(v$(i-1)):ifk<40then418
  96. 417 print"[145]";
  97. 418 printv$(i):next
  98. 420 la$=l1$:nr%=n1%:e$=e1$:i=i1
  99. 422 goto340
  100. 442 sys pu,9,19,29,3,0
  101. 444 printchr$(18);
  102. 446 sys wi,9,19,29,3,b$(1)
  103. 450 v$="":e$=e2$:la$="":nr%=0
  104. 452 sys ei,20,20,16,v$,al$,e$,la$,nr%,1,e$
  105. 456 sys pu,9,19,29,3,1
  106. 458 sys pu,1,19,38,5,1
  107. 460 printchr$(146)chr$(145)
  108. 462 sys cr,9,20:return
  109. 472 sys pu,7,19,31,4,0
  110. 474 printchr$(18);
  111. 476 sys wi,7,19,31,4,c$(1)
  112. 480 r4%=0:r$="":getr$:ifr$=""then480
  113. 482 ifr$=chr$(133)thenr4%=1:goto486
  114. 483 ifr$=chr$(134)thenr4%=2:goto486
  115. 484 ifr$=chr$(137)thenr4%=3:goto486
  116. 485 goto480
  117. 486 sys pu,7,19,31,4,1
  118. 488 sys pu,1,19,38,5,1
  119. 490 printchr$(146)chr$(145):goto702
  120. 510 sys pu,1,19,38,5,0
  121. 520 printchr$(18);
  122. 522 sys wi,1,19,38,5,a$(1)
  123. 530 r$="":getr$:ifr$=""then530
  124. 533 ifr$=chr$(133)thenr%=1:goto550
  125. 534 ifr$=chr$(134)thenr%=7:goto550
  126. 535 ifr$=chr$(135)thenr%=4:goto552
  127. 536 ifr$=chr$(136)thenr%=3:goto554
  128. 537 ifr$=chr$(137)thenr%=2:goto550
  129. 538 ifr$=chr$(138)thenr%=8:goto550
  130. 539 ifr$=chr$(139)thenr%=5:goto552
  131. 540 ifr$=chr$(140)thenr%=6:goto550
  132. 544 goto530
  133. 550 sys pu,1,19,38,5,1
  134. 552 printchr$(146);
  135. 554 onr%goto560,570,472,622,602,402,580,590
  136. 560 ifas<112thenas=as+16:vs=vs+1:goto402
  137. 562 goto340
  138. 570 ifas>15thenas=as-16:vs=vs-1:goto402
  139. 572 goto340
  140. 580 i=16:goto340
  141. 590 i=1:goto340
  142. 602 gosub442:ifla$=chr$(137)then402
  143. 604 print"[211][193][214][197]> "v$
  144. 606 open1,8,15,"s:"+v$:close1
  145. 608 v$=v$+",s,w"
  146. 610 open2,8,2,v$
  147. 612 sys da,2,128,v$(1)
  148. 614 close2:goto402
  149. 622 gosub442:ifla$=chr$(137)then402
  150. 624 print"[204][207][193][196]> "v$
  151. 626 v9$=left$(v$,3)
  152. 628 ifv9$<>"edt"andv9$<>"fdt"then640
  153. 630 v1$="   [196][212]":vd$=mid$(v$,4,2)
  154. 632 v2$="[198][204]":vf$=mid$(v$,8,2)
  155. 634 vs$=mid$(v$,11,2):goto644
  156. 640 v1$="     ":vd$="  ":v2$="  ":vf$="  "
  157. 642 vs$="01"
  158. 644 gosub660
  159. 646 v$=v$+",s,r"
  160. 648 open2,8,2,v$
  161. 650 sys de,2,128,v$(1)
  162. 652 close2:goto402
  163. 660 vs=val(vs$)
  164. 662 vx$=str$(vs)
  165. 664 vp$=mid$(vx$,2)
  166. 666 ifvs<10thenvp$="0"+vp$
  167. 668 return
  168. 702 close1:close4:close6:close7
  169. 704 open1,4,10:print#1:close1
  170. 710 l9=10:zh=30:l9$="          "
  171. 712 open4,4:open6,4,6:open7,4,7
  172. 714 print#6,chr$(30)
  173. 722 ifr4%=1then742
  174. 724 ifr4%=2then732
  175. 726 ifr4%=3then782
  176. 732 p0=as+1:pz=p0+15:vy=vs-1:goto744
  177. 742 p0=as+1:pz=128:vy=vs-1
  178. 744 gosub912:p1=0:forp=p0topz:qp$=v$(p)
  179. 750 ifp=1orp=17orp=33orp=49orp=65orp=81orp=97orp=113then802
  180. 752 goto766
  181. 760 vy=vy+1:print#7,chr$(10);
  182. 762 vy$=mid$(str$(vy),2):iflen(vy$)<2thenvy$=" "+vy$
  183. 764 print#7,l9$;l9$;l9$;v1$;vd$;v2$;vf$" [211]eite "vy$
  184. 766 print#7,l9$;qp$
  185. 770 qp$="":r$="":p1=p1+1
  186. 774 ifp1=64then790
  187. 776 getr$:ifr$="a"then796
  188. 780 next
  189. 782 print#6,chr$(36)
  190. 784 print#4:print#7
  191. 786 close4:close6:close7:gosub910:goto340
  192. 790 gosub908:poke198,0
  193. 792 gosub910:gosub912:goto780
  194. 796 p=pz:poke198,0:goto780
  195. 800 rem -test next side-
  196. 802 p%=0:pp=p
  197. 804 qx$=v$(pp)
  198. 806 ifqx$<>""then760
  199. 810 pp=pp+1:p%=p%+1
  200. 812 ifp%<16then804
  201. 820 goto796
  202. 902 sys cr,12,24:print"[155][215]eiter mit [212]aste[145][145][145]"
  203. 904 r$="":getr$:ifr$=""then904
  204. 906 return
  205. 908 sys cr,3,24:print"[158]  [206]eues [194]latt einlegen!  ([212]aste)  [146][145][145][145]":goto904
  206. 910 sys cr,1,24:print"                                     [145][145][145]":return
  207. 912 sys cr,3,24:print"[158]  [196]ruck laeuft!  [193]bbruch mit ([193])  [146][145][145][145]":return
  208. 914 print"[147][155][192][192] [197]ditor-[194]ildschirm [192][192][211]eite [192][192][218]eile  [192][192]":gosub390:goto916
  209. 916 print""
  210. 917 print"[155][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][192][192][192][192][192][192][192][192][192][192]"
  211. 918 print"[145][155] [212]ext von [196][212]-[206]r.>    [198]ile>    [211]eite>"
  212. 919 print"[155][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][192][192][192][192][192][192][192][192][192][192]"
  213. 928 printtab(6)"[198]1 = [205]enue     [198]2 = zur@ck"
  214. 929 printtab(6)"[198]3 = [218]eile 16  [198]4 = [218]eile 1[158][145][145][145]":return
  215. 930 sys cr,18,18:print"[158]"vd$
  216. 932 sys cr,27,18:print"[158]"vf$
  217. 934 sys cr,37,18:print"[158]"vp$:return
  218. 9990 poke198,0:wait198,1:goto272
  219. 9992 sys64738
  220. 9994 print"[147]":sys cr,6,24:print"  [206]och nicht programmiert!  [146][145][145][145]"
  221. 9995 fori=0to1500:next:goto272
  222. 9997 open4,4:open6,4,6:cmd4:print#6,chr$(27):close6:close4:end
  223. 9998 open15,8,15,"s:-kht-fileprint02":close15
  224. 9999 save"-kht-fileprint02",8
  225.