home *** CD-ROM | disk | FTP | other *** search
/ Loadstar 191 / 191.d81 / telnyr (.txt) < prev    next >
Commodore BASIC  |  2022-08-26  |  11KB  |  386 lines

  1. 1 dv=peek(186):ifgg=20thengg=21:load"icchd8",dv,1
  2. 3 ifgg=21then625
  3. 5 ifgg=22thengg=23:load"chd4",dv,1
  4. 7 ifgg=23then341
  5. 9 ifgg=24thengg=25:load"icchd8",dv,1
  6. 11 ifgg=25then625
  7. 13 ongggoto15,17,19,21
  8. 15 gg=2:load"a",dv,1
  9. 17 gg=3:load"b",dv,1
  10. 19 gg=4:load"c",dv,1
  11. 21 gosub741
  12. 22 poke 808,225
  13. 23 sys49604:sys49500:sys49152:sys49800
  14. 25 poke720,0:poke721,0:poke722,0
  15. 27 poke646,14:print"[147]":gosub33
  16. 29 sa=51600:ea=52599:ns=1024:gosub753:e=22:f=1:gosub31:input nm$:goto341
  17. 31 poke781,e:poke782,f:poke783,0:sys65520:return
  18. 33 sys50400:v=53248:pokev+39,3:pokev+21,0:poke53276,0
  19. 35 hp=250:gl=30:fd=50:w$="no weapon":mc=1:xs=0:dp=0
  20. 37 e=781:f=782:g=783:h=65520:return
  21. 39 ra=int(rnd(1)*10+1)
  22. 41 ifdg=1then51
  23. 43 ifra<2then365
  24. 45 ifdg=0then53
  25. 47 ifdg=2then49
  26. 49 onragoto365,365,55,77,55,77,55,65,55,65
  27. 51 onragoto57,73,55,57,73,77,73,57,73,73
  28. 53 onragoto365,365,61,61,65,69,65,61,65,69
  29. 55 mt$="bat":ms=10:sa=40128:ea=40191:ns=896:gosub753:cs=12:goto81
  30. 57 mt$="ghost":ms=40:sa=40192:ea=40255:ns=896:gosub753
  31. 59 cs=0:poke53285,14:poke53286,0:goto83
  32. 61 mt$="rogue":ms=6:sa=40258:ea=40321:ns=896:gosub753
  33. 63 cs=5:poke53285,9:poke53286,8:goto83
  34. 65 mt$="orc":ms=6:sa=40322:ea=40385:ns=896:gosub753
  35. 67 cs=9:poke53285,8:poke53286,5:goto83
  36. 69 mt$="robber":ms=8:sa=40386:ea=40449:ns=896:gosub753
  37. 71 cs=11:poke53285,8:poke53286,3:goto83
  38. 73 mt$="demon":ms=80:sa=40450:ea=40513:ns=896:gosub753
  39. 75 cs=9:poke53285,3:poke53286,4:goto83
  40. 77 mt$="spider":ms=20:sa=40514:ea=40577:ns=896:gosub753
  41. 79 cs=5:poke53285,3:poke53286,11:goto83
  42. 81 poke53276,0
  43. 83 pokev+21,0:mt=ms:ms$="attacked !!!":yl=20:xl=14:gosub731
  44. 85 gosub299
  45. 87 print"[147]"
  46. 89 sa=25000:ea=25999:ns=55296:gosub753
  47. 91 sa=24000:ea=24999:ns=1024:gosub753
  48. 93 e=1:f=1:gosub31:printnm$;:print" w/";:printw$
  49. 95 e=1:f=31:gosub31:print"hp ";:printhp
  50. 97 e=20:f=13:gosub31:print"choose option"
  51. 99 poke 198,0:wait198,1:geta$:e=20:f=13:gosub31:print"              "
  52. 101 if a$="a"thenjj=1:goto113
  53. 103 if a$="m"thenjj=2:goto113
  54. 105 if a$="c"then159
  55. 107 if a$="r"then215
  56. 109 if a$="g"then227
  57. 111 goto97
  58. 113 ifjj=1thentl=500
  59. 115 ifjj=2thentl=1000
  60. 117 ra=int(rnd(1)*6+1)
  61. 119 if ra<>1then123
  62. 121 ms$="  you missed  ":yl=19:xl=13:gosub733:goto131
  63. 123 p=len(nm$):xl=int((28-p)/2):e=19:f=xl:gosub31
  64. 125 printnm$;:print" hits for ";:printws+ra+xs
  65. 127 yl=19:gosub735
  66. 129 ms=ms-(ws+ra+xs):ifms<0thenms=mt:goto251
  67. 131 ra=int(rnd(1)*6+1)
  68. 133 if ra>mcthen141
  69. 135 if mc=5 then ms$="enemy confused":goto139
  70. 137 ms$="attacker misses":yl=21::xl=12:gosub733:goto153
  71. 139 yl=21::xl=13:gosub733:goto153
  72. 141 p=len(mt$):xl=int((28-p)/2):e=21:f=xl:gosub31
  73. 143 printmt$;:print" hits for ";:printmt+ra
  74. 145 hp=hp-(mt+ra):ifhp<0thenyl=21:gosub735:goto321
  75. 147 e=1:f=34:gosub31:print"     "
  76. 149 e=1:f=34:gosub31:printhp
  77. 151 yl=21:gosub735
  78. 153 ifjj=2then97
  79. 155 ifpeek(197)=60then97
  80. 157 goto113
  81. 159 e=18:f=4:gosub31
  82. 161 print"choose spell:  ":print
  83. 163 printtab(4)"c  confuse ";:printdc;:print"    b  banish ";:printdb
  84. 165 printtab(4)"s  strength";:printds;:print"    n  none   "
  85. 167 printtab(4)"h  heal    ";:printdh
  86. 169 poke198,0:wait198,1:geta$
  87. 171 if a$="c"then183
  88. 173 if a$="s"then187
  89. 175 if a$="h"then191
  90. 177 if a$="b"then197
  91. 179 if a$="n"then203
  92. 181 goto169
  93. 183 dc=dc-1:ifdc<0thendc=dc+1:goto211
  94. 185 mc=5:goto203
  95. 187 ds=ds-1:ifds<0thends=ds+1:goto211
  96. 189 xs=xs+20:goto203
  97. 191 dh=dh-1:ifdh<0thendh=dh+1:goto211
  98. 193 e=1:f=31:gosub31:print"       ":hp=hp+50:fork=1to500:next
  99. 195 gosub31:print"hp ";:printhp:fork=1to500:next:goto203
  100. 197 db=db-1:yl=18:ifdb<0thendb=db+1:goto211
  101. 199 tl=1:gosub735:yl=yl+1:ifyl=23then271
  102. 201 goto199
  103. 203 yl=18
  104. 205 tl=1:gosub735:yl=yl+1:ifyl=23thenjj=2:goto113
  105. 207 goto205
  106. 209 print"[147]":pokev+21,1:xx=xx+1:yy=yy+1:goto341
  107. 211 e=18:f=4:gosub31
  108. 213 print"you have none!    ":fork=1to1000:next:goto159
  109. 215 ra=int(rnd(1)*10+1)
  110. 217 if ra>8 then225 
  111. 219 if ra>3 then223 
  112. 221 ms$="oh no you don't!!":yl=20:xl=12:gosub731:jj=2:goto113
  113. 223 ms$="no escape!":yl=20:xl=15:gosub731:jj=2:goto113
  114. 225 ms$="you have escaped!":yl=20:xl=12:gosub731:goto247
  115. 227 e=19:f=8:gosub31:print"give us ";
  116. 229 printmt*4;:print" gold!     y/n?"
  117. 231 poke198,0:wait198,1:getb$
  118. 233 ifb$="n"then245
  119. 235 ifb$="y"then239
  120. 237 goto231
  121. 239 gl=gl-(mt*4):ifgl<0thengl=gl+(mt*4):tl=1500:yl=19:gosub735:goto243
  122. 241 goto247
  123. 243 yl=19:xl=12:ms$="not enough gold !":gosub731:goto245
  124. 245 yl=19:xl=3:ms$="          then die pauper!       ":gosub731:jj=2:goto113
  125. 247 print"[147]":mc=1:xs=0
  126. 249 sys49604:sys49500:goto341:rem adj error*
  127. 251 nm=nm-1:ifnm=0then271
  128. 253 ifnm=5thenpokev+21,62
  129. 255 ifnm=4thenpokev+21,30
  130. 257 ifnm=3thenpokev+21,14
  131. 259 ifnm=2thenpokev+21,6
  132. 261 ifnm=1thenpokev+21,2
  133. 263 ms$="assailant dies":yl=21:xl=13:gosub733
  134. 265 tl=600:yl=21:gosub735:ifjj=2then97
  135. 267 ifpeek(197)=60then97
  136. 269 goto113
  137. 271 v=53248:p=0:forj=1to15:fork=40to46:pokev+k,p:p=p+1:next:next: pokev+21,0
  138. 273 ms$="attackers defeated!":yl=21:tl=1500:xl=10:gosub733
  139. 275 yl=21:gosub735
  140. 277 ra=int(rnd(1)*15+1):ifra>10then287
  141. 279 ra=mt+(int(rnd(1)*20+1)):gl=gl+ra
  142. 281 e=20:f=7:gosub31
  143. 283 print" you have found ";:printra;:print" gold"
  144. 285 yl=19:tl=1500:gosub735:goto247
  145. 287 e=20:f=3:gosub31
  146. 289 ifra=11thenprint" you have found a confuse spell":dc=dc+1:goto285
  147. 291 ifra=12thenprint" you have found a strength spell":ds=ds+1:goto285
  148. 293 ifra=13thenprint" you have found a healing spell":dh=dh+1:goto285
  149. 295 ifra=14thenprint" you have found a banish spell":db=db+1:goto285
  150. 297 ifra=15thene=20:f=11:gosub31:print"you found +20 food":fd=fd+20:goto285
  151. 299 v=53248
  152. 301 fork=40to46:pokev+k,cs:next
  153. 303 ra=int(rnd(1)*6+1):nm=ra
  154. 305 on ra goto307 ,309,311,313,315,317
  155. 307 pokev+21,2:goto319
  156. 309 pokev+21,6:goto319
  157. 311 pokev+21,14:goto319
  158. 313 pokev+21,30:goto319
  159. 315 pokev+21,62:goto319
  160. 317 pokev+21,126:goto319
  161. 319 return
  162. 321 ms$="  you have died!  ":yl=19:xl=12:gosub731
  163. 323 print"[147]":fork=1to15:print:next:printnm$;:print" has died":print
  164. 325 print" a  resurrect":print" b  begin new game":print" c  quit"
  165. 327 poke198,0:wait198,1:geta$
  166. 329 if a$="a"thengosub339:goto335
  167. 331 if a$="b"thengosub339:pokev+21,0:clr:goto1
  168. 333 if a$="c"thensys64738
  169. 335 dg=0:poke720,0:poke721,0:gg=22:dp=0:hp=100:poke53276,0:iffd<0thenfd=20
  170. 337 pokev+21,0:load"gmmapb",dv,1
  171. 339 print:print:print" loading...please wait...":fork=1to1500:next:return
  172. 341 pokev+21,0:poke53265,peek(53265)and239
  173. 343 sa=22000:ea=22999:ns=1024:gosub753
  174. 345 sa=23000:ea=23999:ns=55296:gosub753
  175. 347 forp=1024to1062:pokep,160:pokep+54272,14:next
  176. 349 forp=1604to1619:pokep,32:next
  177. 351 poke646,12: e=3:f=20:gosub31:printnm$
  178. 353 e=15:f=20:gosub31:printw$
  179. 355 e=5:f=29:gosub31:printhp
  180. 357 e=7:f=29:gosub31:printgl
  181. 359 e=9:f=29:gosub31:printfd
  182. 361 poke53265,peek(53265)or16:pokev+21,1:poke53276,255:poke53285,0:poke53286,1
  183. 363 sys49678:sys49553:sys49152:sys49800
  184. 365 sys50100:xx=peek(720):yy=peek(721)
  185. 367 if peek(56320)=111then421
  186. 369 ifdg=1ordg=2then377
  187. 371 ifsx<>1then377
  188. 373 e=11:f=29:gosub31:printxx;:ifxx<10thenprint"[157] "
  189. 375 e=13:f=29:gosub31:printyy;:ifyy<10thenprint"[157] "
  190. 377 ef=peek(722)
  191. 379 ifef=30thenpoke722,31:goto39
  192. 381 ifef=80thenpoke722,81:goto39
  193. 383 ifef=99then409
  194. 385 if dg=1ordg=2then389
  195. 387 goto365
  196. 389 if ef=50 thenpoke722,51:goto395
  197. 391 if ef=94thenpoke722,95:goto395 
  198. 393 goto365
  199. 395 if dp<>0then365
  200. 397 if dg=2then405
  201. 399 ra=int(rnd(1)*3+1)
  202. 401 on ra goto403 ,405,407
  203. 403 dp=1:sa=15136:ea=15167:ns=14944:gosub753:goto365
  204. 405 dp=2:sa=15168:ea=15199:ns=14976:gosub753:goto365
  205. 407 dp=3:sa=15200:ea=15231:ns=15008:gosub753:goto365
  206. 409 poke722,0:fd=fd-10:iffd>20then417
  207. 411 iffd<0then415
  208. 413 ms$="food low!":yl=20:xl=14:gosub731:goto417
  209. 415 ms$="died of starvation!":yl=20:xl=10:gosub731:goto323
  210. 417 e=9:f=29:gosub31:print"    ";
  211. 419 print"[157][157][157][157]";:printfd:goto385
  212. 421 if dg=1ordg=2then635 
  213. 423 if xx=2andyy=6then465
  214. 425 if xx=32andyy=18then579
  215. 427 if xx=6andyy=38then621
  216. 429 if xx=46andyy=38then437
  217. 431 if xx=44andyy=4then447
  218. 433 if xx=2andyy=28then457
  219. 435 goto365
  220. 437 ifta=1then365
  221. 439 ta=1:xl=4:yl=20:ms$="dig.....dig......sweat......groan":gosub731
  222. 441 xl=5:yl=20:ms$="you find 100g and a heal spell":gosub731
  223. 443 gl=gl+100:dh=dh+1:
  224. 445 e=7:f=29:gosub31:printgl:goto365
  225. 447 iftb=1then365
  226. 449 tb=1:xl=4:yl=20:ms$="dig.....dig......sweat....crash!!":gosub731
  227. 451 pokev+21,0:print"[147]":print" you have fallen into a disused mine."
  228. 453 print:print" there mu