home *** CD-ROM | disk | FTP | other *** search
/ Commodore Disk User Volume 4 #11 / Commodore_Disk_User_Vol.4_11_1991_-.d64 / editor_scroller (.txt) < prev    next >
Commodore BASIC  |  2022-10-26  |  5KB  |  185 lines

  1. 10 if zz=0thenzz=1:load"mc code",8,1
  2. 100 ifdv<>0then231
  3. 101 poke52,31:poke56,31:clr
  4. 102 poke53281,6:print"[147]";:poke53280,1:poke53281,1:print"";:h=14736:c1=0:c2=0
  5. 103 fori=0to7:poke10240+(i*3),255:poke10241+(3*i),0:poke10242+(3*i),0:next
  6. 104 fori=10263to10303:pokei,0:next:poke53287,0:poke53275,1
  7. 105 poke53249,50:poke53248,24
  8. 106 sp=1:fr=1:br=0:fori=0to7:poke13680+i,0:poke13808+i,0:poke12656+i,0
  9. 107 poke12784+i,0:next:fori=0to3:poke13682+i,3:poke13810+i,192:next
  10. 108 poke53269,1:sys8192:poke2040,160
  11. 109 poke53248,24+(8*c2):poke53249,50+(8*c1)
  12. 110 geta$:ifa$=""then110
  13. 111 k=0:ifa$="*"then125
  14. 112 ifa$="_"then182
  15. 113 ifa$=""thenc2=c2+1:ifc2>16thenc2=16
  16. 114 ifa$=chr$(20)thenc2=c2-1:ifc2<0thenc2=0
  17. 115 ifa$=""thengosub163
  18. 116 ifa$="[145]"thengosub169
  19. 117 ifa$=chr$(13)thengosub175
  20. 118 ifa$="."ora$=" "ora$="-"thenk=1
  21. 119 if(a$>="0"anda$<="9")thenk=1
  22. 120 if(a$>="a"anda$<="z")thenk=1
  23. 121 ifk=0then109
  24. 122 a=asc(a$)and191:poke1024+(c1*40)+c2,a:poke55296+(c1*40)+c2,6
  25. 123 c2=c2+1:ifc2>16thenc2=16
  26. 124 goto109
  27. 125 rem
  28. 126 sys8204:poke53269,0
  29. 127 print"[147]":printtab(13);"display  title":printtab(12);"----------------"
  30. 128 print:print"speed [144]02":poke198,0
  31. 129 poke1191,sp+49
  32. 130 geta$:ifa$=chr$(13)then133
  33. 131 ifa$=""thenpoke198,0:sp=(sp+1)and1:poke1191,sp+49
  34. 132 goto130
  35. 133 print:print"foreground colour (ink) [144]01"
  36. 134 poke198,0
  37. 135 iffr<10thenpoke1288,48:poke1289,fr+48
  38. 136 iffr>10thenpoke1288,49:poke1289,fr+38
  39. 137 geta$:ifa$=chr$(13)then142
  40. 138 ifa$<>""then137
  41. 139 poke198,0:fr=(fr+1)and15:iffr<10thenpoke1288,48:poke1289,fr+48
  42. 140 iffr>9thenpoke1288,49:poke1289,fr+38
  43. 141 goto137
  44. 142 print:print"background colour (paper) [144]00"
  45. 143 poke198,0
  46. 144 ifbr<10thenpoke1370,48:poke1371,br+48
  47. 145 ifbr>10thenpoke1370,49:poke1371,br+38
  48. 146 geta$:ifa$=chr$(13)then151
  49. 147 ifa$<>""then146
  50. 148 poke198,0:br=(br+1)and15:ifbr<10thenpoke1370,48:poke1371,br+48
  51. 149 ifbr>9thenpoke1370,49:poke1371,br+38
  52. 150 goto146
  53. 151 poke254,sp:poke8211,fr:poke8225,br
  54. 152 poke53272,28:sys8201:poke53272,21
  55. 153 poke53280,1:poke53281,1
  56. 154 print"[147]a] re-enter titles"
  57. 155 print"b] re-roll  titles"
  58. 156 print"choose [a/b]":poke198,0
  59. 157 geta$:ifa$=""then157
  60. 158 ifa$="b"then127
  61. 159 ifa$<>"a"then157
  62. 160 poke53281,6:print"[147]";:poke53281,1:print"";
  63. 161 sys8207:poke53280,1:sys8198
  64. 162 poke53269,1:goto109
  65. 163 rem
  66. 164 c2=0:c1=c1+1:ifc1<25thenreturn
  67. 165 c1=24:ifh>39976thenreturn
  68. 166 sys59626:a=20-peek(h+1000):fori=1toa
  69. 167 poke1983+i,peek(h+1000+(2*i)):next:sys8198
  70. 168 h=h+40:return
  71. 169 rem
  72. 170 c2=0:c1=c1-1:ifc1>=0thenreturn
  73. 171 c1=0:ifh-40<14736thenreturn
  74. 172 sys8195:h=h-40:a=peek(h)
  75. 173 fori=0to16:poke1024+i,32:next
  76. 174 fori=1to(20-a):poke1023+i,peek(h+(i*2)):next:sys8198:return
  77. 175 rem
  78. 176 b=h+(c1*40):pokeb,20-c2:ifc2=0thenpokeb,19:pokeb+2,32:goto181
  79. 177 fori=1toc2:a=peek(1023+(c1*40)+i)
  80. 178 pokeh+(c1*40)+(i*2),a:next
  81. 179 fori=c2to16:poke1024+i+(c1*40),32:next
  82. 180 goto163
  83. 181 fori=0to16:poke1024+(c1*40)+i,32:next:goto163
  84. 182 sys8204:poke53269,0:poke198,0
  85. 183 print"[147]input/output"
  86. 184 print"------------"
  87. 185 print:print"1] load title data"
  88. 186 print:print"2] save title data"
  89. 187 print:print"3] create a demo title"
  90. 188 print:print"_] abort i/o and return to edit screen"
  91. 189 print:print:print"make your choice please"
  92. 190 geta$:ifa$=""then190
  93. 191 ifa$="_"andh2=26thenpoke198,0:goto231
  94. 192 ifa$="_"thenpoke53269,1:print"[147]";:sys8198:sys8207:poke198,0:goto109
  95. 193 ifa$="1"then215
  96. 194 ifa$="2"then197
  97. 195 ifa$="3"then235
  98. 196 goto190
  99. 197 poke198,0:ifdv>7thendv=0
  100. 198 print"[147]save title data"
  101. 199 print"---------------"
  102. 200 h1=h+(c1*40):h2=int(h1/256):h1=h1-(h2*256)
  103. 201 gosub251
  104. 202 gosub266
  105. 203 print
  106. 204 print"set your ";:ifdv=1thenprint"[144]tape"
  107. 205 ifdv<>1thenprint"[144]disk drive"
  108. 206 print:print"and press 'return'"
  109. 207 print:print"to save your title data"
  110. 208 print:print"with the name - [144]";fl$
  111. 209 poke198,0
  112. 210 geta$:ifa$<>chr$(13)then210
  113. 211 poke198,0:sys57812fl$,dv,1
  114. 212 poke251,0:poke252,57
  115. 213 poke780,251:poke781,h1:poke782,h2:sys65496
  116. 214 goto183
  117. 215 poke198,0:ifdv>7thendv=0
  118. 216 print"[147]load title data"
  119. 217 print"---------------"
  120. 218 gosub251
  121. 219 gosub266
  122. 220 print
  123. 221 print"set your ";:ifdv=1thenprint"[144]tape"
  124. 222 ifdv<>1thenprint"[144]disk drive"
  125. 223 print:print"and press 'return'"
  126. 224 print:print"to load your title data"
  127. 225 print:print"with the name - [144]";fl$
  128. 226 poke198,0
  129. 227 geta$:ifa$<>chr$(13)then227
  130. 228 poke198,0:sys8192
  131. 229 loadfl$,dv,1
  132. 230 h2=26:goto183
  133. 231 print"[147]":sys8198:h=14736:fori=0to24
  134. 232 h1=20-peek(h+(i*40)):forj=1toh1
  135. 233 poke1023+(i*40)+j,peek(h+(i*40)+(j*2)):nextj,i
  136. 234 poke53269,1:c1=0:c2=0:goto109
  137. 235 print"[147][129]create demo"
  138. 236 print"-----------"
  139. 237 ifdv>7thendv=0
  140. 238 gosub251:gosub266
  141. 239 h1=h+(c1*40):h2=int(h1/256):h1=h1-(h2*256):poke8709,h1:poke8713,h2
  142. 240 print:print"[129]set your ";:ifdv=1thenprint"[144]tape"
  143. 241 ifdv<>1thenprint"[144]disk drive"
  144. 242 print:print"[129]and press 'return'"
  145. 243 print:print"to save your title demo"
  146. 244 print:print"with the name - [144]";fl$
  147. 245 poke198,0:poke8734,h2
  148. 246 geta$:ifa$<>chr$(13)then246
  149. 247 poke198,0:sys57812fl$,dv,0
  150. 248 poke251,1:poke252,31:poke780,251:poke781,h1:poke782,h2:poke12287,sp
  151. 249 sys65496:poke8709,0:poke8713,56:poke8734,56
  152. 250 goto183
  153. 251 print"which device ? ";
  154. 252 ifdv=1thenprint"[144]tape"
  155. 253 ifdv=0thenprint"[144]disk"
  156. 254 geta$:ifa$=chr$(13)then257
  157. 255 ifa$<>""then254
  158. 256 poke198,0:dv=(dv+1)and1:goto251
  159. 257 ifdv=1then265
  160. 258 print"which device number ? ";:poke198,0
  161. 259 ifdn=0thenprint"[144]8"
  162. 260 ifdn=1thenprint"[144]9"
  163. 261 geta$:ifa$=chr$(13)then264
  164. 262 ifa$<>""then261
  165. 263 poke198,0:dn=(dn+1)and1:goto258
  166. 264 dv=8+dn
  167. 265 return
  168. 266 fl$="":poke53248,160:poke53249,114:poke53269,1
  169. 267 print"                                     "
  170. 268 print"enter filename - [144]";fl$:poke53248,160+(len(fl$)*8)
  171. 269 er=1
  172. 270 geta$:ifa$=""then270
  173. 271 if(a$>="a")and(a$<="z")thener=0
  174. 272 if(a$>="0")and(a$<="z")thener=0
  175. 273 ifa$=chr$(13)then281
  176. 274 ifa$=chr$(20)then278
  177. 275 iferthen270
  178. 276 iflen(fl$)<11thenfl$=fl$+a$:goto267
  179. 277 iflen(fl$)=11then269
  180. 278 iflen(fl$)=0then269
  181. 279 iflen(fl$)=1thenfl$="":goto267
  182. 280 fl$=left$(fl$,(len(fl$)-1)):goto267
  183. 281 iflen(fl$)=0then269
  184. 282 poke53269,0:return
  185.