home *** CD-ROM | disk | FTP | other *** search
- 2 printchr$(147)"would you like instructions (y/n)?
- 4 [161] a$: [139] a$[179][177] "y" [175] a$[179][177]"n" [167] 4
- 6 [139] a$[178]"n" [167] 92
- 8 [153]"instructions on screen or printer (s/p)?
- 10 get b$: if b$<> "s" and b$<>"p" then 10
- 12 if b$="s"then d=3
- 14 if b$="p" then d=4
- 16 open d,d
- 18 print#d,"
- 20 [152]d,"duo by robert cook
- 22 print#d,"run it right: c-64; joystick optional
- 24 [152]d,"
- 26 print#d,"the object of duo, adapted from the
- 28 [152]d,"popular game uno, is to score 100
- 30 print#d,"points. the playing deck has 100 cards;
- 32 [152]d,"eight each of 0 to 9 worth face value,
- 34 print#d,"skip a turn and draw 2 cards for 20
- 36 [152]d,"points each, plus four wild cards (50
- 38 print#d,"points) all but the wildcards are
- 40 [152]d,"colored.
- 42 print#d,"initially, each player gets six cards,
- 44 [152]d,"with one in the discard pile. to draw,
- 46 print#d,"move the pointer using the joystick or
- 48 [152]d,"the arrow keys. you must discard each
- 50 print#d,"turn. enter every play with the fire
- 52 [152]d,"button or the return key.":[139] d[178]4 [167] 64
- 54 [152]d,"
- 56 print"press a key to continue"
- 58 get dd$:if dd$="" then 58
- 60 print#d,"
- 62 [152]d,"
- 64 print#d,"
- 66 [152]d,"a discard must match the top card on
- 68 print#d,"the pile in color, number or action.
- 70 [152]d,"pick a color for a wildcard with any
- 72 print#d,"cursor key or joystick direction.
- 74 [152]d,"
- 76 print#d,"if you empty your hand, you score the
- 78 [152]d,"total of the computer's hand. if the
- 80 print#d,"computer accumulates 18 cards, you
- 82 [152]d,"score the difference between the values
- 84 print#d,"of the hands, yours being smaller. the
- 86 [152]d,"winner gets ten extra points. if the
- 88 print#d,"deck runs out, the hand ends with no
- 90 [152]d,"winner.":[160]d
- 92 [153]"press any key to begin the program..."
- 94 [161] e$:[139] e$[178]"" [167] 94
- 96 [156]
- 98 [143] * * duo 64 * * * v 1.0 * * * * * robert b. cook * * *
- 100 [151]53280,11:[151]53281,1:[151]53265,11
- 102 [141]456:[141]544:[151]53265,27
- 104 [141]328
- 106 [151]646,4[171](pu[178]2)[172]4:[153]el$:[145]pu[141]116,210:[151]sp,0
- 108 [139]yc[178]0[176]mc[178]0[176]yc[177]17[176]mc[177]17[167][141]370:[137]104
- 110 [139]dp[178]100[167][141]300:[137]104
- 112 pu[178]3[171]pu:[137]106
- 114 :: you ::
- 116 [151]sx,30:[151]sy,218:[151]sp,1:mv[178]1:sk[178]0:[151]sb,0
- 118 [153][200](cr$,7)"clr(NULL)lay a card or str$raw the from deckwait":[141]310
- 120 [161]g$:js[178][194](56320)[175]31:[139]g$[178]""[175]js[178]31[167]120
- 122 [139]g$[178]"^"[176]js[178]30[167][151]sx,150:[151]sy,170:[151]sb,0:[137]120
- 124 [139]g$[178]""[176]js[178]23[167]mv[178]mv[170]1:[139]mv[177]yc[167]mv[178]1
- 126 [139]g$[178]""[176]js[178]27[167]mv[178]mv[171]1:[139]mv[179]1[167]mv[178]yc
- 128 [129]l[178]1[164]50:[130]:t[178]14[170]mv[172]16:t1[178]0:[139]t[177]255[167]t[178]t[171]255:t1[178]1
- 130 [139]g$[179][177][199](13)[175]js[179][177]15[167][151]sx,t:[151]sy,218:[151]sb,t1:[137]120
- 132 [153]el$
- 134 [139][194](sy)[178]170[167]yc[178]yc[170]1:yc(yc)[178]dk(dp):dp[178]dp[170]1:[141]164:[142]
- 136 [139]cv(yc(mv))[179][177]12[175]cv(yc(mv))[179][177]cv(uc)[175]cc$(yc(mv))[179][177]cc$(uc)[167]156
- 138 [153][200](cr$,15)[163]21)""[170]cd$(yc(mv))
- 140 [153][200](cr$,15)[163]21)cc$(yc(mv))[170]cd$(yc(mv))
- 142 uc[178]yc(mv):yc[178]yc[171]1:[139]yc[167][141]162:[137]146
- 144 [153][200](cr$,25)ec$;
- 146 [139]cv(uc)[178]12[175]yc[167][141]182
- 148 [139]cv(uc)[178]11[167][141]196
- 150 [139]cv(uc)[178]10[175]yc[167][141]202
- 152 [139]sk[178]1[175]yc[177]0[175]mc[179]18[175]dp[179]100[167]116
- 154 [142]
- 156 [153][200](cr$,7),"clrlenhoose another cardwait":[141]322
- 158 [129]l[178]0[164]999:[130]:[137]116
- 160 :: card ::
- 162 [129]l[178]mv[164]yc[170]1:yc(l)[178]yc(l[170]1):[130]:[137]170
- 164 [129]l[178]1[164]yc[171]1:[129]k[178]l[170]1[164]yc
- 166 [139]cv(yc(l))[179]cv(yc(k))[167]t[178]yc(l):yc(l)[178]yc(k):yc(k)[178]t
- 168 [130]:[130]
- 170 t[178]0:[129]l[178]1[164]yc
- 172 [139]l[179]19[167][153][200](cr$,21)[163](l[171]1)[172]2)cl$(t)[170]cc$(yc(l))[170]cd$(yc(l));
- 174 t[178]1:[130]:[139]yc[179]18[167][153]ee$;
- 176 [139]yc[178]19[167][153][200](cr$,15)[163]34)cc$(yc(19))[170]cd$(yc(19));
- 178 [142]
- 180 :: wild ::
- 182 [151]sp,0:t[178]0:[153][200](cr$,7)[163]13)"clrlenhoose a colorwait":[141]310
- 184 [161]g$:js[178][194](56320)[175]31:[139]g$[178]""[175]js[178]31[167]184
- 186 [139](g$[178][199](13)[176]js[178]15)[175]t[177]0[167][153]"clr"el$:[137]192
- 188 t[178]t[170]1[170](t[178]4)[172]4:t$[178][202]("defcontsys",t,1):wc$[178]t$:[153][200](cr$,15)[163]21)t$cd$(uc)
- 190 cc$(uc)[178]t$:[141]310:[137]184
- 192 [146]56320,16:[146]197,64:[142]
- 194 :: draw2 ::
- 196 [153][200](cr$,7)[163]12)"clrright$ take two cardswait":[141]310:[129]s[178]0[164]999:[130]
- 198 [129]j[178]1[164]2:[139]dp[179]100[167]mc[178]mc[170]1:mc(mc)[178]dk(dp):dp[178]dp[170]1:[141]262:[130]
- 200 [143]:: skip ::
- 202 [139]yc[178]0[176]mc[177]17[176]dp[177]99[167]206
- 204 [153][200](cr$,7),"clr(NULL)ou get another turnwait":[141]310:[129]s[178]0[164]999:[130]
- 206 sk[178][171](dp[179]100):[142]
- 208 :: computer ::
- 210 [153][200](cr$,7)[163]14)"forright$t's my turnwait":[141]316:[129]s[178]0[164]999:[130]
- 212 sk[178]0:mv[178]1:t[178]1
- 214 [129]l[178]1[164]mc:[139]cv(mc(l))[179]10[167]224
- 216 [139]cv(mc(l))[179][177]cv(uc)[175]cc$(mc(l))[179][177]cc$(uc)[176]cv(mc(l))[178]12[167]222
- 218 [129]k[178]l[170]1[164]mc:[139]cc$(mc(k))[178]cc$(mc(l))[176]cv(mc(k))[178]cv(mc(l))[167]mv[178]l:[137]236
- 220 [130]
- 222 t[178]l[170]1:[130]:[139]yc[179]3[167]t[178]1
- 224 [129]l[178]t[164]mc:[139]cv(mc(l))[178]cv(uc)[175]cv(mc(l))[179][177]12[175]mc(l)[167]mv[178]l:[137]236
- 226 [139]cc$(mc(l))[178]cc$(uc)[167]mv[178]l:[137]236
- 228 [130]:[139]t[179][177]1[167]t[178]1:[137]224
- 230 [139]cv(mc(1))[178]12[167]mv[178]1:[137]236
- 232 [153][200](cr$,7)[163]11)"for right$'ll draw a card wait":[141]316:[129]s[178]0[164]999:[130]
- 234 mc[178]mc[170]1:mc(mc)[178]dk(dp):dp[178]dp[170]1:[141]262:[142]
- 236 [153][200](cr$,7)[163]11)"for right$'ll play a card wait":[141]316:[129]s[178]0[164]999:[130]
- 238 [139]yc[178]1[175]cv(mc(1))[178]12[167]mv[178]1
- 240 [153][200](cr$,15)[163]21)""[170]cd$(mc(mv));
- 242 [153][200](cr$,15)[163]21)cc$(mc(mv))[170]cd$(mc(mv));
- 244 uc[178]mc(mv):mc[178]mc[171]1:[139]mc[167][141]260:[137]248
- 246 [153][200](cr$,13)ec$
- 248 [139]cv(uc)[178]12[175]mc[167][141]274
- 250 [139]cv(uc)[178]11[167][141]286
- 252 [139]cv(uc)[178]10[175]yc[167][141]292
- 254 [139]sk[178]1[175]mc[177]0[175]yc[179]18[175]dp[179]100[167]212
- 256 [142]
- 258 :: card ::
- 260 [129]l[178]mv[164]mc[170]1:mc(l)[178]mc(l[170]1):[130]:[137]268
- 262 [129]l[178]1[164]mc[171]1:[129]k[178]l[170]1[164]mc
- 264 [139]cv(mc(l))[179]cv(mc(k))[167]t[178]mc(l):mc(l)[178]mc(k):mc(k)[178]t
- 266 [130]:[130]
- 268 [139]mc[179]19[167][153][200](cr$,9)[163](mc[171]1)[172]2)bk$;:[139]mc[179]18[167][153]ee$;
- 270 [142]
- 272 :: wild ::
- 274 t1[178]0:t$[178]"":[129]l[178]1[164]4:t[178]0:[129]k[178]1[164]mc
- 276 [139]cc$(mc(k))[178][202]("defcontsys",l,1)[167]t[178]t[170]1
- 278 [130]:[139]t[177]t1[167]t1[178]t:t$[178][202]("defcontsys",l,1)
- 280 [130]:[139]t$[178]""[167]t$[178][202]("defcontsys",[181]([187](1)[172]4[170]1),1)
- 282 [153][200](cr$,15)[163]21)t$[170]cd$(uc):cc$(uc)[178]t$:[142]
- 284 :: draw2 ::
- 286 [153][200](cr$,7)[163]11)"for(NULL)ou take two cardswait":[141]316:[129]s[178]0[164]999:[130]
- 288 [129]j[178]1[164]2:[139]dp[179]100[167]yc[178]yc[170]1:yc(yc)[178]dk(dp):dp[178]dp[170]1:[141]164:[130]
- 290 [143]:: skip ::
- 292 [139]mc[178]0[176]yc[177]17[176]dp[177]99[167]296
- 294 [153][200](cr$,7)[163]11)"forright$ get another turnwait":[141]316:[129]s[178]0[164]999:[130]
- 296 sk[178][171](dp[179]100):[142]
- 298 :: [128] deck ::
- 300 [153][200](cr$,19)[163]14)ec$:[153][200](cr$,7)"open"el$
- 302 [153][200](cr$,7)[163]7)"(NULL)o more cards, hand dumped"
- 304 [129]l[178]1[164]6:[141]316:[141]310:[130]
- 306 [141]416:[142]
- 308 :: beep ::
- 310 [151]sr,240:[151]wv,17:[151]hf,50:[151]lf,35:[151]at,0
- 312 [129]s[178]1[164]99:[130]:[151]wv,16:[151]sr,0:[142]
- 314 :: boop ::
- 316 [151]vl,15:[151]at,0:[151]sr,225:[151]wv,17:[151]hf,33:[151]lf,33
- 318 [129]s[178]1[164]99:[130]:[151]wv,16:[142]
- 320 :: buzz ::
- 322 [151]hf,5:[151]at,0:[151]sr,240:[151]wv,33
- 324 [129]s[178]1[164]500:[130]:[151]wv,32:[142]
- 326 :: deal ::
- 328 t[178][187]([171]ti):[158]900
- 330 [153][200](cr$,7)"open"el$:[153][200](cr$,7)[163]11)"(NULL)huffling the deckwait"
- 332 [141]310:[141]316
- 334 [129]l[178]1[164]100:t[178][181]([187](1)[172]100[170]1):t1[178]dk(l):dk(l)[178]dk(t):dk(t)[178]t1:[130]
- 336 [129]l[178]1[164]19:yc(l)[178]0:mc(l)[178]0:[130]
- 338 t[178]0:[129]l[178]1[164]12[169]2:t[178]t[170]1:yc(t)[178]dk(l):mc(t)[178]dk(l[170]1):[130]
- 340 [129]l[178]1[164]5:[129]k[178]l[170]1[164]6
- 342 [139]cv(yc(l))[179]cv(yc(k))[167]t[178]yc(l):yc(l)[178]yc(k):yc(k)[178]t
- 344 [139]cv(mc(l))[179]cv(mc(k))[167]t[178]mc(l):mc(l)[178]mc(k):mc(k)[178]t
- 346 [130]:[130]:[153][200](cr$,7)"open"el$
- 348 t[178]0:[129]l[178]1[164]6
- 350 [153][200](cr$,21)[163](l[171]1)[172]2)cl$(t)[170]cc$(yc(l))[170]cd$(yc(l));
- 352 [153][200](cr$,9)[163](l[171]1)[172]2)bk$
- 354 t[178]1:[130]
- 356 [139]cv(dk(13))[179]10[167]360
- 358 t1[178][181]([187](1)[172]85[170]16):t[178]dk(13):dk(13)[178]dk(t1):dk(t1)[178]t:[137]356
- 360 [153][200](cr$,15)[163]14)bk$
- 362 [153][200](cr$,15)[163]21)cc$(dk(13))[170]cd$(dk(13))
- 364 mc[178]6:yc[178]6:uc[178]dk(13):dp[178]14
- 366 [142]
- 368 :: win ::
- 370 [139]mc[178]0[167]378
- 372 t[178]0:[129]l[178]1[164]mc
- 374 [139]l[179]19[167][153][200](cr$,9)[163](l[171]1)[172]2)cl$(t)[170]cc$(mc(l))[170]cd$(mc(l))
- 376 t[178]1:[130]
- 378 [151]646,4[171](mc[178]0[176]yc[177]17)[172]4:[153][200](cr$,7)[163]2)el$
- 380 t[178]0:[129]l[178]0[164]yc:t1[178]cv(yc(l))
- 382 [139]t1[179]10[167]t[178]t[170]t1
- 384 [139]t1[178]10[176]t1[178]11[167]t[178]t[170]20
- 386 [139]t1[178]12[167]t[178]t[170]50
- 388 [130]:yt[178]t
- 390 t[178]0:[129]l[178]0[164]mc:t1[178]cv(mc(l))
- 392 [139]t1[179]10[167]t[178]t[170]t1
- 394 [139]t1[178]10[176]t1[178]11[167]t[178]t[170]20
- 396 [139]t1[178]12[167]t[178]t[170]50
- 398 [130]:mt[178]t
- 400 [139]yc[177]17[167]yt[178]yt[171]mt:[139]mt[179]0[167]mt[178]0
- 402 [139]mc[177]17[167]mt[178]mt[171]yt:[139]yt[179]0[167]yt[178]0
- 404 [139]yc[177]0[175]mc[179]18[167]412
- 406 [153][200](cr$,7)[163]10)"(NULL)ou score"mt[170]10"points":[141]310:[141]310
- 408 ys[178]ys[170]mt[170]10:pu[178]2:[139]ys[177]99[167]yg[178]yg[170]1
- 410 [139]mc[177]0[175]yc[179]18[167]416
- 412 [153][200](cr$,7)[163]11)"right$ score"yt[170]10"points":[141]316:[141]316
- 414 ms[178]ms[170]yt[170]10:pu[178]1:[139]ms[177]99[167]mg[178]mg[170]1
- 416 [129]l[178]0[164]2999:[130]:[129]l[178]97[164]100:cc$(l)[178]"stop":[130]:sk[178]0:[141]448
- 418 [151]198,0:[139]ms[177]99[176]ys[177]99[167]428
- 420 [153][200](cr$,7)"open"el$:[153][200](cr$,7)[163]10)"(NULL)ress ascright$(NULL)val or (NULL)val(NULL)(NULL)(NULL)(NULL)"
- 422 [141]310:[141]316
- 424 [161]g$:js[178][194](56320)[175]31:[139]g$[179][177][199](13)[175]js[179][177]15[167]424
- 426 [142]
- 428 [139]ys[177]ms[167][153][200](cr$,7)[163]4)"clr(NULL) o u w i n t h e g a m e!"
- 430 [139]ms[177]ys[167][153][200](cr$,7)[163]6)"forright$ w i n t h e g a m e!"
- 432 [151]896,mg:[151]897,yg:[151]898,pu:[141]446
- 434 [129]l[178]1[164]10:[141]310:[141]316:[130]:[129]l[178]0[164]3999:[130]
- 436 [153][200](cr$,7)"open"el$:[153][200](cr$,7)[163]11)"(NULL)lay again? [y/n]"
- 438 [141]310:[141]316
- 440 [151]198,0:[146]198,1:[161]g$:[139]g$[179][177]"n"[167][138]
- 442 [128]:game
- 444 :: sc[176]ing ::
- 446 mg[178][194](896):yg[178][194](897):pu[178][194](898)
- 448 [153][200](cr$,3)[163]27)"poke"[201](" "[170][196](ms),3)[163]34)mg
- 450 [153][200](cr$,4)[163]67)"poke"[201](" "[170][196](ys),3)[163]74)yg
- 452 [142]
- 454 :: initialize ::
- 456 [134] t,t1,t2,l,k,j,dp,mc,yc,mt,yt,ms,ys,mg,yg,pu,mv,js,sk,g$,t$,wc$
- 458 [134] cd$(100),cc$(100),cv(100),dk(100),mc(20),yc(20)
- 460 bk$[178]"openortantantan^cmdcmdcmdcmdcmd(NULL)str$step(NULL)wait(NULL)cmdcmdcmdcmdcmd(NULL)step(NULL)stepwait(NULL)cmdcmdcmdcmdcmd(NULL)(NULL)step(NULL)wait(NULL)cmdcmdcmdcmdcmd/tantantanexp"
- 462 ee$[178]"poke cmdcmdon cmdcmdon cmdcmdon cmdcmdon wait"
- 464 ec$[178]"poke cmdcmdcmdcmdcmdon cmdcmdcmdcmdcmdon cmdcmdcmdcmdcmdon cmdcmdcmdcmdcmdon wait"
- 466 el$[178]" wait"
- 468 cl$(1)[178]"print#cmd+cmd+cmd+cmd+cmd+onononon"
- 470 e$[178]"cmdcmdcmdcmdcmd":cr$[178]""
- 472 lf[178]54272:hf[178]54273:wv[178]54276:at[178]54277:sr[178]54278
- 474 sp[178]53269:sx[178]53248:sy[178]53249:sb[178]53264
- 476 [151]54296,15:[151]2040,13:[151]53287,0:[151]sp,0
- 478 [151]53276,1:[151]53285,3:[151]53277,0:[151]53271,1
- 480 [129]l[178]1[164]96[169]8:c$[178]"":[129]k[178]1[164]4:[135]d$:c$[178]c$[170]d$[170]e$:[130]:[135]d$
- 482 [129]k[178]0[164]7:cd$(l[170]k)[178]c$[170]d$:cc$(l[170]k)[178][202]("defdefcontcontsyssys",k[170]1,1):cv(l[170]k)[178]t
- 484 [130]:t[178]t[170]1:[130]
- 486 c$[178]"":[129]k[178]1[164]4:[135]d$:c$[178]c$[170]d$[170]e$:[130]:[135]d$
- 488 [129]l[178]97[164]100:cd$(l)[178]c$[170]d$:cc$(l)[178]"stop":cv(l)[178]12:[130]
- 490 [129]l[178]1[164]100:dk(l)[178]l:[130]
- 492 [139][194](1024)[178]160[167]500
- 494 [129]l[178]832[164]897:[135]k:[151]l,k:[130]
- 496 [129]l[178]900[164]933:[135]k:[151]l,k:[130]
- 498 pu[178]1:[151]898,1
- 500 [142]
- 502 [131] "0 0"," cos logwait "," wait wait "," rnd *wait ","0 0"
- 504 [131] "1 1"," * wait "," wait "," * waitrnd ","1 1"
- 506 [131] "2 2"," cosposlogwait "," frefre*wait "," frefrewait ","2 2"
- 508 [131] "3 3"," cosposlogwait "," tantanwait "," rndfre*wait ","3 3"
- 510 [131] "4 4"," usrgetwaitget "," coslogwait "," getwaitget ","4 4"
- 512 [131] "5 5"," andandwait "," andandlogwait "," rndusr*wait ","5 5"
- 514 [131] "6 6"," cosposlogwait "," waittanfrewait "," rndusr*wait ","6 6"
- 516 [131] "7 7"," topos wait "," getwaitget "," wait ","7 7"
- 518 [131] "8 8"," cosposlogwait "," tanwaittantanwait "," rndfre*wait ","8 8"
- 520 [131] "9 9"," cosposlogwait "," poswaittan wait "," rndfre*wait ","9 9"
- 522 [131] "(NULL) ","kcosandtowait(NULL)","irndatnlogwaitu","ptab(usr*waitr"," n"
- 524 [131] "str$ len","r newlogwaita","a wait waitr","w waitnew*waitd","2 s"
- 526 [131] "(NULL) ","i wait waitlen","lfnwait(NULL)thenwaita","dint(NULL)abswaitr"," d"
- 528 :: arrow ::
- 530 [131] 170,170,128,149,085,128,149,106,128,149,106,128,149,090,000,149
- 532 [131] 086,128,153,085,160,154,085,104,154,149,090,170,165,090,168,169
- 534 [131] 106,000,042,168,000,010,160,000,002,128,000,000,000,000,000,000
- 536 [131] 000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000
- 538 :: screen ::
- 540 [131] 162,170,169,11,157,63,217,157,233,217,157,147,218,157,61,219,169
- 542 [131] 160,157,63,5,157,233,5,157,147,6,157,61,7,202,208,225,96
- 544 [153]"loadpoke ortantantantantantantantantantantantantantantantantantantantan^";
- 546 [153]"waitrnd*newnewlog waitcosnewnewnewlog (NULL) (NULL)core chr$ames (NULL)";
- 548 [153]"waitgetget (NULL) lenomp: (NULL)";
- 550 [153]"waitcoslognewnewwait* waitrndnewnewnewwait* waitrndnewnewnewwait* (NULL) (NULL)ou: (NULL)";
- 552 [153]" /tantantantantantantantantantantantantantantantantantantantanexp";
- 554 [153]" totototototototototototototototototototototototototototototototototototo ";
- 556 [153]" then fn ";
- 558 [153]" tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab(tab( "
- 560 [141]446:[158]900:[142]
-