Home » Personal collection » Acorn tapes » Electron_User » Electron_User_tape25a_acorn_eu_1991_july.wav » ScrSoft

ScrSoft

This website contains an archive of files for the Acorn Electron, BBC Micro, Acorn Archimedes, Commodore 16 and Commodore 64 computers, which Dominic Ford has rescued from his private collection of floppy disks and cassettes.

Some of these files were originally commercial releases in the 1980s and 1990s, but they are now widely available online. I assume that copyright over them is no longer being asserted. If you own the copyright and would like files to be removed, please contact me.

Tape/disk: Home » Personal collection » Acorn tapes » Electron_User » Electron_User_tape25a_acorn_eu_1991_july.wav
Filename: ScrSoft
Read OK:
File size: 2D5C bytes
Load address: FFFF1A00
Exec address: FFFF8023
Duplicates

There are 2 duplicate copies of this file in the archive:

File contents
   10REM Software Scroller
   20REM by Paul Bedworth
   30REM (c) The Micro User
   40REM Save this program before
   50REM running it.
   60cheat=&84
   70?cheat=FALSE
   80*TV 255
   90MapDepth=6
  100MapWidth=7
  110MapTopGap=1
  120MapLeftGap=1
  130SprWidth=4
  140SprDepth=32
  150IncNr=&140*SprWidth
  160IncNc=8*SprWidth
  170osbyte=&FFF4
  180oswrch=&FFEE
  190:
  200AL1=MapTopGap*IncNr
  210AL2=MapLeftGap*IncNc
  220ALIGN=AL1+AL2
  230:
  240REM screen start addresses
  250REM - screen 1 must be lower
  260REM than screen 2 -
  270screen1=&3000
  280screen2=&5800
  290:
  300REM zero page pointers
  310addr=&80
  320topaddr=&82
  330data=&76
  340:
  350FOR P=0 TO 2 STEP 2
  360P%=&1100
  370[OPT P
  380 JMP scroll
  390.xydata
  400 OPT FNxydata
  410.calc LDY y:LDA xydata,Y
  420 STA a:LDA xydata+32,Y
  430 STA a+1
  440 LDA x:BEQ endit:TAY
  450.cl LDA a:CLC:ADC #8:STA a
  460 LDA a+1:ADC #0:STA a+1:DEY:BNE cl
  470.endit
  480 LDA sn:CMP #2:BNE endit2
  490 LDA a:SEC:SBC #&2800 MOD 256
  500 STA a
  510 LDA a+1:SBC #&2800 DIV 256
  520 STA a+1
  530.endit2
  540 RTS
  550.demo
  560 LDA cheat
  570 BNE cheaton
  580 LDA deathflag
  590 BNE dead
  600.cheaton
  610 LDX #&9E:JSR key
  620 BNE notleft
  630 LDA x:CMP #5:BCC notleft
  640 DEC x
  650.notleft
  660 LDX #&BD:JSR key
  670 BNE notright
  680 LDA x:CMP #24:BCS notright
  690 INC x
  700.notright
  710 LDX #&97:JSR key
  720 BNE notdown
  730 LDA y:CMP #25:BCS notdown
  740 INC y
  750.notdown
  760 LDX #&B7:JSR key
  770 BNE notup
  780 LDA y:CMP #5:BCC notup
  790 DEC y
  800.notup
  810 LDA #ASC("P")
  820 JSR schoose
  830 JSR calc
  840 LDA #4:STA cols
  850 JSR plot
  860 RTS
  870.dead
  880 LDA deathflag:CMP #1:BNE novdus
  890 LDY #255
  900.vl
  910 LDX #2
  920.v19l
  930 LDA #19:JSR oswrch
  940 LDA #0:JSR oswrch
  950 TXA:JSR oswrch
  960 LDA #0:JSR oswrch
  970 JSR oswrch:JSR oswrch
  980 DEX
  990 BNE v19l
 1000 DEY:BNE vl
 1010.novdus
 1020 INC deathflag
 1030 JSR wait
 1040 RTS
 1050.key
 1060 LDA #129
 1070 LDY #255
 1080 JSR osbyte
 1090 CPY #255
 1100 RTS
 1110.welldone
 1120 JSR wait
 1130 LDX #0
 1140.msg
 1150 LDA text,X
 1160 JSR oswrch
 1170 INX
 1180 CMP #0
 1190 BNE msg
 1200 LDA #21
 1210 LDX #0
 1220 JSR osbyte
 1230 RTS
 1240.wait
 1250 LDX #255
 1260.w1 LDY #255
 1270.w2 NOP:NOP:NOP:NOP:NOP:NOP
 1280 DEY
 1290 BNE w2
 1300 DEX
 1310 BNE w1
 1320 RTS
 1330.text
 1340 OPT FNequb(22)
 1350 OPT FNequb(5)
 1360 OPT FNequb(31)
 1370 OPT FNequb(2)
 1380 OPT FNequb(4)
 1390 OPT FNequs("Well Done!")
 1400 OPT FNequb(31)
 1410 OPT FNequb(2)
 1420 OPT FNequb(6)
 1430 OPT FNequs("Level 1 Completed!")
 1440 BRK
 1450.plot LDA addr:PHA:LDA addr+1:PHA
 1460 LDA a:STA addr:LDA a+1:STA addr+1
 1470 JSR eorsplot
 1480 PLA:STA addr+1:PLA STA addr
 1490 RTS
 1500.splot       \ plot sprite
 1510 LDA addr
 1520 PHA
 1530 STA tcaddr
 1540 LDA addr+1
 1550 PHA
 1560 STA tcaddr+1
 1570.l1
 1580 LDY #0
 1590 LDX #4
 1600.l2
 1610 LDA (data),Y \ This is not
 1620 STA (addr),Y \ bad programming!
 1630 INY          \ Makes it faster
 1640 LDA (data),Y
 1650 STA (addr),Y
 1660 INY
 1670 LDA (data),Y
 1680 STA (addr),Y
 1690 INY
 1700 LDA (data),Y
 1710 STA (addr),Y
 1720 INY
 1730 LDA (data),Y
 1740 STA (addr),Y
 1750 INY
 1760 LDA (data),Y
 1770 STA (addr),Y
 1780 INY
 1790 LDA (data),Y
 1800 STA (addr),Y
 1810 INY
 1820 LDA (data),Y
 1830 STA (addr),Y
 1840 INY
 1850 LDA addr
 1860 CLC
 1870 ADC #&38
 1880 STA addr
 1890 LDA addr+1
 1900 ADC #1
 1910 STA addr+1
 1920 DEX
 1930 BNE l2
 1940 LDA data
 1950 CLC
 1960 ADC #SprDepth
 1970 STA data
 1980 LDA data+1
 1990 ADC #0
 2000 STA data+1
 2010 LDA tcaddr
 2020 ADC #8
 2030 STA addr
 2040 STA tcaddr
 2050 LDA tcaddr+1
 2060 ADC #0
 2070 STA tcaddr+1
 2080 STA addr+1
 2090 DEC cols
 2100 BNE l1
 2110 PLA
 2120 STA addr+1
 2130 PLA
 2140 STA addr
 2150 RTS
 2160.splot2        \ to enable
 2170 LDA #SprWidth \ reverse
 2180 SEC           \ sprite-clipping
 2190 SBC cols
 2200 TAY
 2210 BEQ dosplot
 2220.s2l
 2230 LDA data
 2240 CLC
 2250 ADC #SprDepth
 2260 STA data
 2270 LDA data+1
 2280 ADC #0
 2290 STA data+1
 2300 DEY
 2310 BNE s2l
 2320.dosplot
 2330 JMP splot
 2340.eorsplot
 2350 LDA addr
 2360 PHA
 2370 STA tcaddr
 2380 LDA addr+1
 2390 PHA
 2400 STA tcaddr+1
 2410.el1
 2420 LDY #0
 2430 LDX #4:STX cd
 2440.eel2 LDX #8
 2450.el2
 2460 LDA (data),Y:BEQ black
 2470 PHA:LDA (addr),Y:BEQ nohit
 2480 LDA #1:STA deathflag
 2490.nohit
 2500 PLA
 2510.black
 2520 EOR (addr),Y:STA (addr),Y:INY
 2530 DEX:BNE el2
 2540 LDA addr:CLC:ADC #&38:STA addr
 2550 LDA addr+1:ADC #1:STA addr+1
 2560 DEC cd
 2570 BNE eel2
 2580 LDA data
 2590 CLC:ADC #SprDepth:STA data
 2600 LDA data+1:ADC #0:STA data+1
 2610 LDA tcaddr:ADC #8:STA addr
 2620 STA tcaddr
 2630 LDA tcaddr+1:ADC #0:STA tcaddr+1
 2640 STA addr+1
 2650 DEC cols
 2660 BNE el1
 2670 PLA:STA addr+1
 2680 PLA:STA addr
 2690 RTS
 2700.switch1    \ change screen 
 2710 LDA #19    \ start address
 2720 JSR osbyte \ to screen 1
 2730 LDA #13
 2740 STA &FE00
 2750 LDA #(screen1 MOD 2048 DIV 8)
 2760 STA &FE01
 2770 LDA #12
 2780 STA &FE00
 2790 LDA #(screen1 DIV 2048)
 2800 STA &FE01
 2810 LDA #1:STA sn
 2820 RTS
 2830.switch2
 2840 LDA #19    \ change screen
 2850 JSR osbyte \ start address
 2860 LDA #13    \ to screen 2
 2870 STA &FE00
 2880 LDA #(screen2 MOD 2048 DIV 8)
 2890 STA &FE01
 2900 LDA #12
 2910 STA &FE00
 2920 LDA #(screen2 DIV 2048)
 2930 STA &FE01
 2940 LDA #2:STA sn
 2950 RTS
 2960.scroll
 2970 LDA #22
 2980 JSR oswrch
 2990 LDA #5
 3000 JSR oswrch
 3010 LDA #23:JSR oswrch
 3020 LDA #0:JSR oswrch
 3030 LDA #10:JSR oswrch
 3040 LDA #32:JSR oswrch
 3050 LDA #0:JSR oswrch:JSR oswrch
 3060 JSR oswrch:JSR oswrch
 3070 JSR oswrch:JSR oswrch
 3080 LDA #0  \ clear break flag
 3090 STA &FF
 3100 STA deathflag
 3110 LDY #0
 3120 LDA #&3000 MOD 256
 3130 STA &90
 3140 LDA #&3000 DIV 256
 3150 STA &91
 3160.bloop
 3170 LDA #0
 3180 STA (&90),Y \ clear both
 3190 LDA &90     \ of the screens
 3200 CLC         \ -NB- this will
 3210 ADC #1      \ clear from the
 3220 STA &90     \ start of screen1
 3230 BCC nc      \ all the way to
 3240 INC &91     \ &7FFF
 3250.nc
 3260 LDA &90
 3270 CMP #&8000 MOD 256
 3280 BNE bloop
 3290 LDA &91
 3300 CMP #&8000 DIV 256
 3310 BNE bloop
 3320 LDA #map MOD 256 \ initialise
 3330 STA &70          \ pointers to
 3340 LDA #map DIV 256 \ map data
 3350 STA &71
 3360.scrloop      \ control loop
 3370 JSR demo
 3380 JSR switch1  \ switch to screen 1
 3390 CMP #&EA
 3400 LDA #screen2 MOD 256
 3410 CLC
 3420 ADC #ALIGN MOD 256
 3430 STA maptop
 3440 LDA #screen2 DIV 256
 3450 ADC #ALIGN DIV 256
 3460 STA maptop+1
 3470 JSR plotmap \ plot map over scr 2
 3480 CMP #&EA
 3490 BNE cont1
 3500 JSR welldone
 3510 RTS
 3520.cont1
 3530 JSR demo
 3540 JSR switch2 \ reveal map on scr 2
 3550 LDA #screen1 MOD 256
 3560 CLC
 3570 ADC #ALIGN MOD 256
 3580 STA maptop
 3590 LDA #screen1 DIV 256
 3600 ADC #ALIGN DIV 256
 3610 STA maptop+1
 3620 JSR plotmap \ plot map over scr 1
 3630 CMP #&EA
 3640 BNE cont2
 3650 JSR welldone
 3660 RTS
 3670.cont2
 3680 LDA deathflag
 3690 CMP #2
 3700 BCC notdeadyet
 3710 JMP scroll
 3720.notdeadyet
 3730 BIT &FF     \ test for break
 3740 BEQ scrloop
 3750 BRK
 3760 OPT FNequb(27)
 3770 OPT FNequs("Escape")
 3780 BRK
 3790.plotmap      \ plot a screen
 3800 INC counter  \ from the map data
 3810 LDA &70
 3820 STA old70
 3830 LDA &71
 3840 STA old70+1
 3850 LDY #0
 3860 STY mcol
 3870 LDA maptop
 3880 STA addr
 3890 LDA maptop+1
 3900 STA addr+1
 3910.ml
 3920 LDY #0
 3930 LDA addr
 3940 STA topaddr
 3950 LDA addr+1
 3960 STA topaddr+1
 3970.pml
 3980 LDA (&70),Y   \ load map symbol
 3990 CMP #&EA
 4000 BNE noteod
 4010 RTS
 4020.noteod
 4030 JSR schoose   \ and choose the 
 4040 LDA mcol      \ corresponding
 4050 BEQ doclip    \ sprite
 4060 LDA #SprWidth
 4070 STA cols
 4080 JMP overdoclip
 4090.doclip        
 4100 LDA ncols     \ only print
 4110 STA cols      \ 'ncols' columns
 4120.overdoclip    \ of the sprite
 4130 STY ystore
 4140 LDA mcol        \ if not last
 4150 CMP #MapWidth-1 \ column then do
 4160 BNE dosplot2    \ a reverse clip
 4170 LDA #SprWidth
 4180 SEC
 4190 SBC ncols
 4200 BNE goon
 4210 LDA #SprWidth
 4220.goon STA cols
 4230 JSR splot      \ do the clip the 
 4240 JMP oversplot2 \ other way around
 4250.dosplot2
 4260 JSR splot2
 4270.oversplot2
 4280 LDY ystore     \ go on to next
 4290 LDA addr       \ map row
 4300 CLC
 4310 ADC #IncNr MOD 256
 4320 STA addr
 4330 LDA addr+1
 4340 ADC #IncNr DIV 256
 4350 STA addr+1
 4360 INY
 4370 CPY #MapDepth
 4380 BNE pml
 4390 LDA mcol
 4400 BNE ok
 4410 LDA #4
 4420 SEC
 4430 SBC ncols
 4440 BEQ ndec
 4450 TAY
 4460.decl
 4470 LDA topaddr
 4480 SEC
 4490 SBC #8
 4500 STA topaddr
 4510 LDA topaddr+1
 4520 SBC #0
 4530 STA topaddr+1
 4540 DEY
 4550 BNE decl
 4560.ndec
 4570 DEC ncols
 4580 BNE ok
 4590 LDA #SprWidth
 4600 STA ncols
 4610.ok
 4620 INC mcol
 4630 LDA &70
 4640 CLC
 4650 ADC #MapDepth
 4660 STA &70
 4670 LDA &71
 4680 ADC #0
 4690 STA &71
 4700 LDA topaddr         \ go on to
 4710 CLC                 \ next map
 4720 ADC #IncNc MOD 256  \ column
 4730 STA addr
 4740 LDA topaddr+1
 4750 ADC #IncNc DIV 256
 4760 STA addr+1
 4770 LDA mcol
 4780 CMP #MapWidth
 4790 BEQ nml
 4800 JMP ml
 4810.nml
 4820 LDA counter    \ decide whether
 4830 CMP #4         \ to go onto next
 4840 BNE notc4      \ column of data
 4850 LDA old70      \ or to keep
 4860 CLC            \ scrolling
 4870 ADC #MapDepth  \ current data
 4880 STA &70
 4890 LDA old70+1
 4900 ADC #0
 4910 STA &71
 4920 LDA #0
 4930 STA counter
 4940 JMP overnotc4
 4950.notc4
 4960 LDA old70
 4970 STA &70
 4980 LDA old70+1
 4990 STA &71
 5000.overnotc4
 5010 RTS
 5020 :
 5030.schoose
 5040 STA symbol
 5050 STY ystore
 5060 LDY #0
 5070.searchl
 5080 LDA sptable,Y
 5090 BEQ notfound
 5100 CMP symbol
 5110 BEQ foundit
 5120 INY:INY
 5130 INY
 5140 JMP searchl
 5150.foundit
 5160 LDA sptable+1,Y
 5170 STA data
 5180 LDA sptable+2,Y
 5190 STA data+1
 5200 LDY ystore
 5210 RTS
 5220.notfound
 5230 LDA sptable+1
 5240 STA data
 5250 LDA sptable+2
 5260 STA data+1
 5270 LDY ystore
 5280 RTS
 5290.cols      BRK
 5300.tcaddr    BRK:BRK
 5310.maptop    BRK:BRK
 5320.ncols     OPT FNequb(SprWidth)
 5330.ystore    BRK
 5340.mcol      BRK
 5350.counter   BRK
 5360.old70     BRK:BRK
 5370.symbol    BRK
 5380.sn        OPT FNequb(1)
 5390.cd        BRK
 5400.deathflag BRK
 5410.x OPT FNequb(10)
 5420.y OPT FNequb(10)
 5430.a BRK:BRK
 5440.map
 5450 OPT FNequs("0     ")
 5460 OPT FNequs("0     ")
 5470 OPT FNequs("0     ")
 5480 OPT FNequs("0     ")
 5490 OPT FNequs("0     ")
 5500 OPT FNequs("0     ")
 5510 OPT FNequs("0000 0")
 5520 OPT FNequs("0000 0")
 5530 OPT FNequs("0000 0")
 5540 OPT FNequs("0000 0")
 5550 OPT FNequs("0000 0")
 5560 OPT FNequs("0000 0")
 5570 OPT FNequs("000  0")
 5580 OPT FNequs("0    0")
 5590 OPT FNequs("0  000")
 5600 OPT FNequs("0 0   ")
 5610 OPT FNequs("0 0000")
 5620 OPT FNequs("0    0")
 5630 OPT FNequs("0    0")
 5640 OPT FNequs("0000 0")
 5650 OPT FNequs("0000 0")
 5660 OPT FNequs("00   0")
 5670 OPT FNequs("00  00")
 5680 OPT FNequs("0  000")
 5690 OPT FNequs("0  000")
 5700 OPT FNequs("00  00")
 5710 OPT FNequs("00   0")
 5720 OPT FNequs("0000 0")
 5730 OPT FNequs("0000 0")
 5740 OPT FNequs("0    0")
 5750 OPT FNequs("0 00 0")
 5760 OPT FNequs("0 00 0")
 5770 OPT FNequs("0 00 0")
 5780 OPT FNequs("0 00 0")
 5790 OPT FNequs("0 00 0")
 5800 OPT FNequs("  00  ")
 5810 OPT FNequs("  00  ")
 5820 OPT FNequs(" 0000 ")
 5830 OPT FNequs("      ")
 5840 OPT FNequs("00  00")
 5850 OPT FNequs("00  00")
 5860 OPT FNequs("      ")
 5870 OPT FNequs("      ")
 5880 OPT FNequs("      ")
 5890 NOP
 5900.sptable
 5910 OPT FNequs(" ")
 5920 OPT FNequw(blankdata)
 5930 OPT FNequs("P")
 5940 OPT FNequw(blockdata)
 5950 OPT FNequs("0")
 5960 OPT FNequw(blockdata+32*4)
 5970 BRK
 5980.blockdata
 5990 OPT FNsdata
 6000.blankdata
 6010 OPT FNequs(STRING$(4*32,CHR$(0)))
 6020]:NEXT
 6030PROCexecute
 6040END
 6050:
 6060DEFFNsdata
 6070RESTORE
 6080FOR I%=1 TO ((SprWidth*SprDepth)/4)*2
 6090READ d$
 6100[OPT P:OPT FNequd(EVAL("&"+d$))
 6110]:NEXT:=P
 6120:
 6130DEFFNxydata
 6140RESTORE 6240
 6150FOR I%=1 TO 64/4
 6160READ d$
 6170[OPT P:OPT FNequd(EVAL("&"+d$)):]
 6180NEXT:=P
 6190:
 6200DATA 0,E0C0C08,F0F0F0E,10100206,3030,0,0,0,0,0,F0F00,C0E0F0F0,80,0,0,0,0,E0600000,70E0F00,383,0,0,0,0,0,0,3060C00,F0F,0,0,0,0
 6210DATA 3C7F7FFF,2C3C1C2C,1C2C3C1C,3C1C2C3C,2C3C1C2C,1C2C3C1C,3C1C2C3C,F0F0F2C,60FFFFFF,D060B0D0,B0D060B0,60B0D060,D060B0D0,B0D060B0,60B0D060,F0F0FD0,D0FFFFFF,B0D060B0,60B0D060,D060B0D0,B0D060B0,60B0D060,D060B0D0,F0F0FB0,B3FFFFFF
 6220DATA73B3F373,F373B3F3,B3F373B3,73B3F373,F373B3F3,B3F373B3,1F1F3F73
 6230:
 6240DATA C0804000,C0804000,C0804000,C0804000,C0804000,C0804000,C0804000,C0804000,5B5A5958,605F5E5D,65646362,6A696867,6F6E6D6C,74737271,79787776,7E7D7C7B
 6250:
 6260DEFFNequs(s$)$P%=s$:P%=P%+LENs$:=P
 6270DEFFNequb(B%)?P%=B%:P%=P%+1:=P
 6280DEFFNequw(W%)!P%=W%:P%=P%+2:=P
 6290DEFFNequd(D%)!P%=D%:P%=P%+4:=P
 6300:
 6310DEFPROCexecute
 6320s$="CALL scroll"+CHR$(13)
 6330FOR L=1 TO LEN(s$)
 6340X%=0:Y%=ASCMID$(s$,L)
 6350A%=138:CALL osbyte
 6360NEXT:ENDPROC

� Software Scroller
� by Paul Bedworth
� (c) The Micro User
(� Save this program before
2� running it.
<
cheat=&84
F?cheat=�
P*TV 255
ZMapDepth=6
dMapWidth=7
nMapTopGap=1
xMapLeftGap=1
�SprWidth=4
�SprDepth=32
�IncNr=&140*SprWidth
�IncNc=8*SprWidth
�osbyte=&FFF4
�oswrch=&FFEE
�:
�AL1=MapTopGap*IncNr
�AL2=MapLeftGap*IncNc
�ALIGN=AL1+AL2
�:
�� screen start addresses
�� - screen 1 must be lower
� than screen 2 -
screen1=&3000
screen2=&5800
":
,� zero page pointers
6addr=&80
@topaddr=&82
Jdata=&76
T:
^� P=0 � 2 � 2
hP%=&1100
r
[OPT P
| JMP scroll
�.xydata
� OPT �xydata
�.calc LDY y:LDA xydata,Y
� STA a:LDA xydata+32,Y
� STA a+1
� LDA x:BEQ endit:TAY
�.cl LDA a:CLC:ADC #8:STA a
�& LDA a+1:ADC #0:STA a+1:DEY:BNE cl
�
.endit
� LDA sn:CMP #2:BNE endit2
� LDA a:SEC:SBC #&2800 � 256
�
 STA a
� LDA a+1:SBC #&2800 � 256
 STA a+1
.endit2
 RTS
&	.demo
0 LDA cheat
: BNE cheaton
D LDA deathflag
N
 BNE dead
X.cheaton
b LDX #&9E:JSR key
l BNE notleft
v LDA x:CMP #5:BCC notleft
�
 DEC x
�.notleft
� LDX #&BD:JSR key
� BNE notright
� LDA x:CMP #24:BCS notright
�
 INC x
�
.notright
� LDX #&97:JSR key
� BNE notdown
� LDA y:CMP #25:BCS notdown
�
 INC y
�.notdown
� LDX #&B7:JSR key
 BNE notup
 LDA y:CMP #5:BCC notup

 DEC y
 
.notup
* LDA #�("P")
4 JSR schoose
>
 JSR calc
H LDA #4:STA cols
R
 JSR plot
\ RTS
f	.dead
p$ LDA deathflag:CMP #1:BNE novdus
z
 LDY #255
�.vl
� LDX #2
�	.v19l
� LDA #19:JSR oswrch
� LDA #0:JSR oswrch
� TXA:JSR oswrch
� LDA #0:JSR oswrch
� JSR oswrch:JSR oswrch
� DEX
�
 BNE v19l
� DEY:BNE vl
�.novdus
� INC deathflag

 JSR wait
 RTS
.key
$
 LDA #129
.
 LDY #255
8 JSR osbyte
B
 CPY #255
L RTS
V
.welldone
`
 JSR wait
j LDX #0
t.msg
~ LDA text,X
� JSR oswrch
� INX
� CMP #0
� BNE msg
� LDA #21
� LDX #0
� JSR osbyte
� RTS
�	.wait
�
 LDX #255
�.w1 LDY #255
�.w2 NOP:NOP:NOP:NOP:NOP:NOP
 DEY

 BNE w2
 DEX
 BNE w1
( RTS
2	.text
< OPT �equb(22)
F OPT �equb(5)
P OPT �equb(31)
Z OPT �equb(2)
d OPT �equb(4)
n OPT �equs("Well Done!")
x OPT �equb(31)
� OPT �equb(2)
� OPT �equb(6)
�$ OPT �equs("Level 1 Completed!")
� BRK
�%.plot LDA addr:PHA:LDA addr+1:PHA
�& LDA a:STA addr:LDA a+1:STA addr+1
� JSR eorsplot
�  PLA:STA addr+1:PLA STA addr
� RTS
�.splot       \ plot sprite
�
 LDA addr
� PHA
� STA tcaddr
 LDA addr+1
 PHA
 STA tcaddr+1
".l1
, LDY #0
6 LDX #4
@.l2
J LDA (data),Y \ This is not
T$ STA (addr),Y \ bad programming!
^# INY          \ Makes it faster
h LDA (data),Y
r STA (addr),Y
| INY
� LDA (data),Y
� STA (addr),Y
� INY
� LDA (data),Y
� STA (addr),Y
� INY
� LDA (data),Y
� STA (addr),Y
� INY
� LDA (data),Y
� STA (addr),Y
� INY
� LDA (data),Y
 STA (addr),Y
 INY
 LDA (data),Y
& STA (addr),Y
0 INY
:
 LDA addr
D CLC
N
 ADC #&38
X
 STA addr
b LDA addr+1
l ADC #1
v STA addr+1
� DEX
� BNE l2
�
 LDA data
� CLC
� ADC #SprDepth
�
 STA data
� LDA data+1
� ADC #0
� STA data+1
� LDA tcaddr
� ADC #8
�
 STA addr
� STA tcaddr
 LDA tcaddr+1
 ADC #0
 STA tcaddr+1
  STA addr+1
*
 DEC cols
4 BNE l1
> PLA
H STA addr+1
R PLA
\
 STA addr
f RTS
p.splot2        \ to enable
z LDA #SprWidth \ reverse
�$ SEC           \ sprite-clipping
�
 SBC cols
� TAY
� BEQ dosplot
�.s2l
�
 LDA data
� CLC
� ADC #SprDepth
�
 STA data
� LDA data+1
� ADC #0
� STA data+1
� DEY
	 BNE s2l
	.dosplot
	 JMP splot
	$
.eorsplot
	.
 LDA addr
	8 PHA
	B STA tcaddr
	L LDA addr+1
	V PHA
	` STA tcaddr+1
	j.el1
	t LDY #0
	~ LDX #4:STX cd
	�.eel2 LDX #8
	�.el2
	� LDA (data),Y:BEQ black
	� PHA:LDA (addr),Y:BEQ nohit
	� LDA #1:STA deathflag
	�
.nohit
	� PLA
	�
.black
	�  � (addr),Y:STA (addr),Y:INY
	� DEX:BNE el2
	�# LDA addr:CLC:ADC #&38:STA addr
	�! LDA addr+1:ADC #1:STA addr+1
 DEC cd


 BNE eel2

 LDA data
 CLC:ADC #SprDepth:STA data
(! LDA data+1:ADC #0:STA data+1
2 LDA tcaddr:ADC #8:STA addr
< STA tcaddr
F% LDA tcaddr+1:ADC #0:STA tcaddr+1
P STA addr+1
Z
 DEC cols
d BNE el1
n PLA:STA addr+1
x PLA:STA addr
� RTS
� .switch1    \ change screen 
� LDA #19    \ start address
� JSR osbyte \ to screen 1
� LDA #13
� STA &FE00
� LDA #(screen1 � 2048 � 8)
� STA &FE01
� LDA #12
� STA &FE00
� LDA #(screen1 � 2048)
� STA &FE01
� LDA #1:STA sn
 RTS
.switch2
 LDA #19    \ change screen
" JSR osbyte \ start address
, LDA #13    \ to screen 2
6 STA &FE00
@ LDA #(screen2 � 2048 � 8)
J STA &FE01
T LDA #12
^ STA &FE00
h LDA #(screen2 � 2048)
r STA &FE01
| LDA #2:STA sn
� RTS
�.scroll
� LDA #22
� JSR oswrch
� LDA #5
� JSR oswrch
� LDA #23:JSR oswrch
� LDA #0:JSR oswrch
� LDA #10:JSR oswrch
� LDA #32:JSR oswrch
�! LDA #0:JSR oswrch:JSR oswrch
� JSR oswrch:JSR oswrch
� JSR oswrch:JSR oswrch
 LDA #0  \ clear break flag
 STA &FF
 STA deathflag
& LDY #0
0 LDA #&3000 � 256
: STA &90
D LDA #&3000 � 256
N STA &91
X
.bloop
b LDA #0
l STA (&90),Y \ clear both
v! LDA &90     \ of the screens
�! CLC         \ -NB- this will
�! ADC #1      \ clear from the
�# STA &90     \ start of screen1
�! BCC nc      \ all the way to
� INC &91     \ &7FFF
�.nc
� LDA &90
� CMP #&8000 � 256
� BNE bloop
� LDA &91
� CMP #&8000 � 256
� BNE bloop
�  LDA #map � 256 \ initialise

# STA &70          \ pointers to

 LDA #map � 256 \ map data

 STA &71

  .scrloop      \ control loop

*
 JSR demo

4& JSR switch1  \ switch to screen 1

>
 CMP #&EA

H LDA #screen2 � 256

R CLC

\ ADC #ALIGN � 256

f STA maptop

p LDA #screen2 � 256

z ADC #ALIGN � 256

� STA maptop+1

�& JSR plotmap \ plot map over scr 2

�
 CMP #&EA

� BNE cont1

� JSR welldone

� RTS

�
.cont1

�
 JSR demo

�& JSR switch2 \ reveal map on scr 2

� LDA #screen1 � 256

� CLC

� ADC #ALIGN � 256

� STA maptop
 LDA #screen1 � 256
 ADC #ALIGN � 256
 STA maptop+1
$& JSR plotmap \ plot map over scr 1
.
 CMP #&EA
8 BNE cont2
B JSR welldone
L RTS
V
.cont2
` LDA deathflag
j CMP #2
t BCC notdeadyet
~ JMP scroll
�.notdeadyet
�! BIT &FF     \ test for break
� BEQ scrloop
� BRK
� OPT �equb(27)
� OPT �equs("Escape")
� BRK
�!.plotmap      \ plot a screen
�% INC counter  \ from the map data
� LDA &70
� STA old70
� LDA &71
 STA old70+1

 LDY #0

 STY mcol
 LDA maptop
(
 STA addr
2 LDA maptop+1
< STA addr+1
F.ml
P LDY #0
Z
 LDA addr
d STA topaddr
n LDA addr+1
x STA topaddr+1
�.pml
�$ LDA (&70),Y   \ load map symbol
�
 CMP #&EA
� BNE noteod
� RTS
�.noteod
�$ JSR schoose   \ and choose the 
�" LDA mcol      \ corresponding
� BEQ doclip    \ sprite
� LDA #SprWidth
�
 STA cols
� JMP overdoclip
�.doclip        
 LDA ncols     \ only print
$ STA cols      \ 'ncols' columns
".overdoclip    \ of the sprite
" STY ystore
," LDA mcol        \ if not last
6% CMP #MapWidth-1 \ column then do
@% BNE dosplot2    \ a reverse clip
J LDA #SprWidth
T SEC
^ SBC ncols
h
 BNE goon
r LDA #SprWidth
|.goon STA cols
�& JSR splot      \ do the clip the 
�& JMP oversplot2 \ other way around
�
.dosplot2
� JSR splot2
�.oversplot2
�# LDY ystore     \ go on to next
� LDA addr       \ map row
� CLC
� ADC #IncNr � 256
�
 STA addr
� LDA addr+1
� ADC #IncNr � 256
� STA addr+1
 INY
 CPY #MapDepth
 BNE pml
&
 LDA mcol
0 BNE ok
: LDA #4
D SEC
N SBC ncols
X
 BEQ ndec
b TAY
l	.decl
v LDA topaddr
� SEC
� SBC #8
� STA topaddr
� LDA topaddr+1
� SBC #0
� STA topaddr+1
� DEY
�
 BNE decl
�	.ndec
� DEC ncols
� BNE ok
� LDA #SprWidth
� STA ncols
.ok

 INC mcol
 LDA &70
  CLC
* ADC #MapDepth
4 STA &70
> LDA &71
H ADC #0
R STA &71
\# LDA topaddr         \ go on to
f# CLC                 \ next map
p ADC #IncNc � 256  \ column
z
 STA addr
� LDA topaddr+1
� ADC #IncNc � 256
� STA addr+1
�
 LDA mcol
� CMP #MapWidth
� BEQ nml
� JMP ml
�.nml
�$ LDA counter    \ decide whether
�% CMP #4         \ to go onto next
�$ BNE notc4      \ column of data
�  LDA old70      \ or to keep
� CLC            \ scrolling
" ADC #MapDepth  \ current data
 STA &70
 LDA old70+1
$ ADC #0
. STA &71
8 LDA #0
B STA counter
L JMP overnotc4
V
.notc4
` LDA old70
j STA &70
t LDA old70+1
~ STA &71
�.overnotc4
� RTS
� :
�.schoose
� STA symbol
� STY ystore
� LDY #0
�.searchl
� LDA sptable,Y
� BEQ notfound
� CMP symbol
� BEQ foundit
 INY:INY

 INY
 JMP searchl
.foundit
( LDA sptable+1,Y
2
 STA data
< LDA sptable+2,Y
F STA data+1
P LDY ystore
Z RTS
d
.notfound
n LDA sptable+1
x
 STA data
� LDA sptable+2
� STA data+1
� LDY ystore
� RTS
�.cols      BRK
�.tcaddr    BRK:BRK
�.maptop    BRK:BRK
�".ncols     OPT �equb(SprWidth)
�.ystore    BRK
�.mcol      BRK
�.counter   BRK
�.old70     BRK:BRK
�.symbol    BRK
.sn        OPT �equb(1)
.cd        BRK
.deathflag BRK
".x OPT �equb(10)
,.y OPT �equb(10)
6.a BRK:BRK
@.map
J OPT �equs("0     ")
T OPT �equs("0     ")
^ OPT �equs("0     ")
h OPT �equs("0     ")
r OPT �equs("0     ")
| OPT �equs("0     ")
� OPT �equs("0000 0")
� OPT �equs("0000 0")
� OPT �equs("0000 0")
� OPT �equs("0000 0")
� OPT �equs("0000 0")
� OPT �equs("0000 0")
� OPT �equs("000  0")
� OPT �equs("0    0")
� OPT �equs("0  000")
� OPT �equs("0 0   ")
� OPT �equs("0 0000")
� OPT �equs("0    0")
� OPT �equs("0    0")
 OPT �equs("0000 0")
 OPT �equs("0000 0")
 OPT �equs("00   0")
& OPT �equs("00  00")
0 OPT �equs("0  000")
: OPT �equs("0  000")
D OPT �equs("00  00")
N OPT �equs("00   0")
X OPT �equs("0000 0")
b OPT �equs("0000 0")
l OPT �equs("0    0")
v OPT �equs("0 00 0")
� OPT �equs("0 00 0")
� OPT �equs("0 00 0")
� OPT �equs("0 00 0")
� OPT �equs("0 00 0")
� OPT �equs("  00  ")
� OPT �equs("  00  ")
� OPT �equs(" 0000 ")
� OPT �equs("      ")
� OPT �equs("00  00")
� OPT �equs("00  00")
� OPT �equs("      ")
� OPT �equs("      ")
� OPT �equs("      ")
 NOP
.sptable
 OPT �equs(" ")
  OPT �equw(blankdata)
* OPT �equs("P")
4 OPT �equw(blockdata)
> OPT �equs("0")
H OPT �equw(blockdata+32*4)
R BRK
\.blockdata
f OPT �sdata
p.blankdata
z OPT �equs(�4*32,�(0)))
�]:�
��execute
��
�:
�ݤsdata
��
�&� I%=1 � ((SprWidth*SprDepth)/4)*2
�� d$
�[OPT P:OPT �equd(�("&"+d$))
�
]:�:=P
�:
�ݤxydata
�
� �D`X
� I%=1 � 64/4
� d$
![OPT P:OPT �equd(�("&"+d$)):]
$�:=P
.:
8~� 0,E0C0C08,F0F0F0E,10100206,3030,0,0,0,0,0,F0F00,C0E0F0F0,80,0,0,0,0,E0600000,70E0F00,383,0,0,0,0,0,0,3060C00,F0F,0,0,0,0
B�� 3C7F7FFF,2C3C1C2C,1C2C3C1C,3C1C2C3C,2C3C1C2C,1C2C3C1C,3C1C2C3C,F0F0F2C,60FFFFFF,D060B0D0,B0D060B0,60B0D060,D060B0D0,B0D060B0,60B0D060,F0F0FD0,D0FFFFFF,B0D060B0,60B0D060,D060B0D0,B0D060B0,60B0D060,D060B0D0,F0F0FB0,B3FFFFFF
LC�73B3F373,F373B3F3,B3F373B3,73B3F373,F373B3F3,B3F373B3,1F1F3F73
V:
`�� C0804000,C0804000,C0804000,C0804000,C0804000,C0804000,C0804000,C0804000,5B5A5958,605F5E5D,65646362,6A696867,6F6E6D6C,74737271,79787776,7E7D7C7B
j:
t!ݤequs(s$)$P%=s$:P%=P%+�s$:=P
~ݤequb(B%)?P%=B%:P%=P%+1:=P
�ݤequw(W%)!P%=W%:P%=P%+2:=P
�ݤequd(D%)!P%=D%:P%=P%+4:=P
�:
�
��execute
�s$="CALL scroll"+�(13)
�� L=1 � �(s$)
�X%=0:Y%=��s$,L)
�A%=138:� osbyte
��:�
�
00000000  0d 00 0a 17 f4 20 53 6f  66 74 77 61 72 65 20 53  |..... Software S|
00000010  63 72 6f 6c 6c 65 72 0d  00 14 16 f4 20 62 79 20  |croller..... by |
00000020  50 61 75 6c 20 42 65 64  77 6f 72 74 68 0d 00 1e  |Paul Bedworth...|
00000030  18 f4 20 28 63 29 20 54  68 65 20 4d 69 63 72 6f  |.. (c) The Micro|
00000040  20 55 73 65 72 0d 00 28  1e f4 20 53 61 76 65 20  | User..(.. Save |
00000050  74 68 69 73 20 70 72 6f  67 72 61 6d 20 62 65 66  |this program bef|
00000060  6f 72 65 0d 00 32 11 f4  20 72 75 6e 6e 69 6e 67  |ore..2.. running|
00000070  20 69 74 2e 0d 00 3c 0d  63 68 65 61 74 3d 26 38  | it...<.cheat=&8|
00000080  34 0d 00 46 0c 3f 63 68  65 61 74 3d a3 0d 00 50  |4..F.?cheat=...P|
00000090  0b 2a 54 56 20 32 35 35  0d 00 5a 0e 4d 61 70 44  |.*TV 255..Z.MapD|
000000a0  65 70 74 68 3d 36 0d 00  64 0e 4d 61 70 57 69 64  |epth=6..d.MapWid|
000000b0  74 68 3d 37 0d 00 6e 0f  4d 61 70 54 6f 70 47 61  |th=7..n.MapTopGa|
000000c0  70 3d 31 0d 00 78 10 4d  61 70 4c 65 66 74 47 61  |p=1..x.MapLeftGa|
000000d0  70 3d 31 0d 00 82 0e 53  70 72 57 69 64 74 68 3d  |p=1....SprWidth=|
000000e0  34 0d 00 8c 0f 53 70 72  44 65 70 74 68 3d 33 32  |4....SprDepth=32|
000000f0  0d 00 96 17 49 6e 63 4e  72 3d 26 31 34 30 2a 53  |....IncNr=&140*S|
00000100  70 72 57 69 64 74 68 0d  00 a0 14 49 6e 63 4e 63  |prWidth....IncNc|
00000110  3d 38 2a 53 70 72 57 69  64 74 68 0d 00 aa 10 6f  |=8*SprWidth....o|
00000120  73 62 79 74 65 3d 26 46  46 46 34 0d 00 b4 10 6f  |sbyte=&FFF4....o|
00000130  73 77 72 63 68 3d 26 46  46 45 45 0d 00 be 05 3a  |swrch=&FFEE....:|
00000140  0d 00 c8 17 41 4c 31 3d  4d 61 70 54 6f 70 47 61  |....AL1=MapTopGa|
00000150  70 2a 49 6e 63 4e 72 0d  00 d2 18 41 4c 32 3d 4d  |p*IncNr....AL2=M|
00000160  61 70 4c 65 66 74 47 61  70 2a 49 6e 63 4e 63 0d  |apLeftGap*IncNc.|
00000170  00 dc 11 41 4c 49 47 4e  3d 41 4c 31 2b 41 4c 32  |...ALIGN=AL1+AL2|
00000180  0d 00 e6 05 3a 0d 00 f0  1c f4 20 73 63 72 65 65  |....:..... scree|
00000190  6e 20 73 74 61 72 74 20  61 64 64 72 65 73 73 65  |n start addresse|
000001a0  73 0d 00 fa 1e f4 20 2d  20 73 63 72 65 65 6e 20  |s..... - screen |
000001b0  31 20 6d 75 73 74 20 62  65 20 6c 6f 77 65 72 0d  |1 must be lower.|
000001c0  01 04 15 f4 20 74 68 61  6e 20 73 63 72 65 65 6e  |.... than screen|
000001d0  20 32 20 2d 0d 01 0e 11  73 63 72 65 65 6e 31 3d  | 2 -....screen1=|
000001e0  26 33 30 30 30 0d 01 18  11 73 63 72 65 65 6e 32  |&3000....screen2|
000001f0  3d 26 35 38 30 30 0d 01  22 05 3a 0d 01 2c 18 f4  |=&5800..".:..,..|
00000200  20 7a 65 72 6f 20 70 61  67 65 20 70 6f 69 6e 74  | zero page point|
00000210  65 72 73 0d 01 36 0c 61  64 64 72 3d 26 38 30 0d  |ers..6.addr=&80.|
00000220  01 40 0f 74 6f 70 61 64  64 72 3d 26 38 32 0d 01  |.@.topaddr=&82..|
00000230  4a 0c 64 61 74 61 3d 26  37 36 0d 01 54 05 3a 0d  |J.data=&76..T.:.|
00000240  01 5e 11 e3 20 50 3d 30  20 b8 20 32 20 88 20 32  |.^.. P=0 . 2 . 2|
00000250  0d 01 68 0c 50 25 3d 26  31 31 30 30 0d 01 72 0a  |..h.P%=&1100..r.|
00000260  5b 4f 50 54 20 50 0d 01  7c 0f 20 4a 4d 50 20 73  |[OPT P..|. JMP s|
00000270  63 72 6f 6c 6c 0d 01 86  0b 2e 78 79 64 61 74 61  |croll.....xydata|
00000280  0d 01 90 10 20 4f 50 54  20 a4 78 79 64 61 74 61  |.... OPT .xydata|
00000290  0d 01 9a 1c 2e 63 61 6c  63 20 4c 44 59 20 79 3a  |.....calc LDY y:|
000002a0  4c 44 41 20 78 79 64 61  74 61 2c 59 0d 01 a4 1a  |LDA xydata,Y....|
000002b0  20 53 54 41 20 61 3a 4c  44 41 20 78 79 64 61 74  | STA a:LDA xydat|
000002c0  61 2b 33 32 2c 59 0d 01  ae 0c 20 53 54 41 20 61  |a+32,Y.... STA a|
000002d0  2b 31 0d 01 b8 18 20 4c  44 41 20 78 3a 42 45 51  |+1.... LDA x:BEQ|
000002e0  20 65 6e 64 69 74 3a 54  41 59 0d 01 c2 1e 2e 63  | endit:TAY.....c|
000002f0  6c 20 4c 44 41 20 61 3a  43 4c 43 3a 41 44 43 20  |l LDA a:CLC:ADC |
00000300  23 38 3a 53 54 41 20 61  0d 01 cc 26 20 4c 44 41  |#8:STA a...& LDA|
00000310  20 61 2b 31 3a 41 44 43  20 23 30 3a 53 54 41 20  | a+1:ADC #0:STA |
00000320  61 2b 31 3a 44 45 59 3a  42 4e 45 20 63 6c 0d 01  |a+1:DEY:BNE cl..|
00000330  d6 0a 2e 65 6e 64 69 74  0d 01 e0 1d 20 4c 44 41  |...endit.... LDA|
00000340  20 73 6e 3a 43 4d 50 20  23 32 3a 42 4e 45 20 65  | sn:CMP #2:BNE e|
00000350  6e 64 69 74 32 0d 01 ea  1f 20 4c 44 41 20 61 3a  |ndit2.... LDA a:|
00000360  53 45 43 3a 53 42 43 20  23 26 32 38 30 30 20 83  |SEC:SBC #&2800 .|
00000370  20 32 35 36 0d 01 f4 0a  20 53 54 41 20 61 0d 01  | 256.... STA a..|
00000380  fe 1d 20 4c 44 41 20 61  2b 31 3a 53 42 43 20 23  |.. LDA a+1:SBC #|
00000390  26 32 38 30 30 20 81 20  32 35 36 0d 02 08 0c 20  |&2800 . 256.... |
000003a0  53 54 41 20 61 2b 31 0d  02 12 0b 2e 65 6e 64 69  |STA a+1.....endi|
000003b0  74 32 0d 02 1c 08 20 52  54 53 0d 02 26 09 2e 64  |t2.... RTS..&..d|
000003c0  65 6d 6f 0d 02 30 0e 20  4c 44 41 20 63 68 65 61  |emo..0. LDA chea|
000003d0  74 0d 02 3a 10 20 42 4e  45 20 63 68 65 61 74 6f  |t..:. BNE cheato|
000003e0  6e 0d 02 44 12 20 4c 44  41 20 64 65 61 74 68 66  |n..D. LDA deathf|
000003f0  6c 61 67 0d 02 4e 0d 20  42 4e 45 20 64 65 61 64  |lag..N. BNE dead|
00000400  0d 02 58 0c 2e 63 68 65  61 74 6f 6e 0d 02 62 15  |..X..cheaton..b.|
00000410  20 4c 44 58 20 23 26 39  45 3a 4a 53 52 20 6b 65  | LDX #&9E:JSR ke|
00000420  79 0d 02 6c 10 20 42 4e  45 20 6e 6f 74 6c 65 66  |y..l. BNE notlef|
00000430  74 0d 02 76 1d 20 4c 44  41 20 78 3a 43 4d 50 20  |t..v. LDA x:CMP |
00000440  23 35 3a 42 43 43 20 6e  6f 74 6c 65 66 74 0d 02  |#5:BCC notleft..|
00000450  80 0a 20 44 45 43 20 78  0d 02 8a 0c 2e 6e 6f 74  |.. DEC x.....not|
00000460  6c 65 66 74 0d 02 94 15  20 4c 44 58 20 23 26 42  |left.... LDX #&B|
00000470  44 3a 4a 53 52 20 6b 65  79 0d 02 9e 11 20 42 4e  |D:JSR key.... BN|
00000480  45 20 6e 6f 74 72 69 67  68 74 0d 02 a8 1f 20 4c  |E notright.... L|
00000490  44 41 20 78 3a 43 4d 50  20 23 32 34 3a 42 43 53  |DA x:CMP #24:BCS|
000004a0  20 6e 6f 74 72 69 67 68  74 0d 02 b2 0a 20 49 4e  | notright.... IN|
000004b0  43 20 78 0d 02 bc 0d 2e  6e 6f 74 72 69 67 68 74  |C x.....notright|
000004c0  0d 02 c6 15 20 4c 44 58  20 23 26 39 37 3a 4a 53  |.... LDX #&97:JS|
000004d0  52 20 6b 65 79 0d 02 d0  10 20 42 4e 45 20 6e 6f  |R key.... BNE no|
000004e0  74 64 6f 77 6e 0d 02 da  1e 20 4c 44 41 20 79 3a  |tdown.... LDA y:|
000004f0  43 4d 50 20 23 32 35 3a  42 43 53 20 6e 6f 74 64  |CMP #25:BCS notd|
00000500  6f 77 6e 0d 02 e4 0a 20  49 4e 43 20 79 0d 02 ee  |own.... INC y...|
00000510  0c 2e 6e 6f 74 64 6f 77  6e 0d 02 f8 15 20 4c 44  |..notdown.... LD|
00000520  58 20 23 26 42 37 3a 4a  53 52 20 6b 65 79 0d 03  |X #&B7:JSR key..|
00000530  02 0e 20 42 4e 45 20 6e  6f 74 75 70 0d 03 0c 1b  |.. BNE notup....|
00000540  20 4c 44 41 20 79 3a 43  4d 50 20 23 35 3a 42 43  | LDA y:CMP #5:BC|
00000550  43 20 6e 6f 74 75 70 0d  03 16 0a 20 44 45 43 20  |C notup.... DEC |
00000560  79 0d 03 20 0a 2e 6e 6f  74 75 70 0d 03 2a 10 20  |y.. ..notup..*. |
00000570  4c 44 41 20 23 97 28 22  50 22 29 0d 03 34 10 20  |LDA #.("P")..4. |
00000580  4a 53 52 20 73 63 68 6f  6f 73 65 0d 03 3e 0d 20  |JSR schoose..>. |
00000590  4a 53 52 20 63 61 6c 63  0d 03 48 14 20 4c 44 41  |JSR calc..H. LDA|
000005a0  20 23 34 3a 53 54 41 20  63 6f 6c 73 0d 03 52 0d  | #4:STA cols..R.|
000005b0  20 4a 53 52 20 70 6c 6f  74 0d 03 5c 08 20 52 54  | JSR plot..\. RT|
000005c0  53 0d 03 66 09 2e 64 65  61 64 0d 03 70 24 20 4c  |S..f..dead..p$ L|
000005d0  44 41 20 64 65 61 74 68  66 6c 61 67 3a 43 4d 50  |DA deathflag:CMP|
000005e0  20 23 31 3a 42 4e 45 20  6e 6f 76 64 75 73 0d 03  | #1:BNE novdus..|
000005f0  7a 0d 20 4c 44 59 20 23  32 35 35 0d 03 84 07 2e  |z. LDY #255.....|
00000600  76 6c 0d 03 8e 0b 20 4c  44 58 20 23 32 0d 03 98  |vl.... LDX #2...|
00000610  09 2e 76 31 39 6c 0d 03  a2 17 20 4c 44 41 20 23  |..v19l.... LDA #|
00000620  31 39 3a 4a 53 52 20 6f  73 77 72 63 68 0d 03 ac  |19:JSR oswrch...|
00000630  16 20 4c 44 41 20 23 30  3a 4a 53 52 20 6f 73 77  |. LDA #0:JSR osw|
00000640  72 63 68 0d 03 b6 13 20  54 58 41 3a 4a 53 52 20  |rch.... TXA:JSR |
00000650  6f 73 77 72 63 68 0d 03  c0 16 20 4c 44 41 20 23  |oswrch.... LDA #|
00000660  30 3a 4a 53 52 20 6f 73  77 72 63 68 0d 03 ca 1a  |0:JSR oswrch....|
00000670  20 4a 53 52 20 6f 73 77  72 63 68 3a 4a 53 52 20  | JSR oswrch:JSR |
00000680  6f 73 77 72 63 68 0d 03  d4 08 20 44 45 58 0d 03  |oswrch.... DEX..|
00000690  de 0d 20 42 4e 45 20 76  31 39 6c 0d 03 e8 0f 20  |.. BNE v19l.... |
000006a0  44 45 59 3a 42 4e 45 20  76 6c 0d 03 f2 0b 2e 6e  |DEY:BNE vl.....n|
000006b0  6f 76 64 75 73 0d 03 fc  12 20 49 4e 43 20 64 65  |ovdus.... INC de|
000006c0  61 74 68 66 6c 61 67 0d  04 06 0d 20 4a 53 52 20  |athflag.... JSR |
000006d0  77 61 69 74 0d 04 10 08  20 52 54 53 0d 04 1a 08  |wait.... RTS....|
000006e0  2e 6b 65 79 0d 04 24 0d  20 4c 44 41 20 23 31 32  |.key..$. LDA #12|
000006f0  39 0d 04 2e 0d 20 4c 44  59 20 23 32 35 35 0d 04  |9.... LDY #255..|
00000700  38 0f 20 4a 53 52 20 6f  73 62 79 74 65 0d 04 42  |8. JSR osbyte..B|
00000710  0d 20 43 50 59 20 23 32  35 35 0d 04 4c 08 20 52  |. CPY #255..L. R|
00000720  54 53 0d 04 56 0d 2e 77  65 6c 6c 64 6f 6e 65 0d  |TS..V..welldone.|
00000730  04 60 0d 20 4a 53 52 20  77 61 69 74 0d 04 6a 0b  |.`. JSR wait..j.|
00000740  20 4c 44 58 20 23 30 0d  04 74 08 2e 6d 73 67 0d  | LDX #0..t..msg.|
00000750  04 7e 0f 20 4c 44 41 20  74 65 78 74 2c 58 0d 04  |.~. LDA text,X..|
00000760  88 0f 20 4a 53 52 20 6f  73 77 72 63 68 0d 04 92  |.. JSR oswrch...|
00000770  08 20 49 4e 58 0d 04 9c  0b 20 43 4d 50 20 23 30  |. INX.... CMP #0|
00000780  0d 04 a6 0c 20 42 4e 45  20 6d 73 67 0d 04 b0 0c  |.... BNE msg....|
00000790  20 4c 44 41 20 23 32 31  0d 04 ba 0b 20 4c 44 58  | LDA #21.... LDX|
000007a0  20 23 30 0d 04 c4 0f 20  4a 53 52 20 6f 73 62 79  | #0.... JSR osby|
000007b0  74 65 0d 04 ce 08 20 52  54 53 0d 04 d8 09 2e 77  |te.... RTS.....w|
000007c0  61 69 74 0d 04 e2 0d 20  4c 44 58 20 23 32 35 35  |ait.... LDX #255|
000007d0  0d 04 ec 10 2e 77 31 20  4c 44 59 20 23 32 35 35  |.....w1 LDY #255|
000007e0  0d 04 f6 1f 2e 77 32 20  4e 4f 50 3a 4e 4f 50 3a  |.....w2 NOP:NOP:|
000007f0  4e 4f 50 3a 4e 4f 50 3a  4e 4f 50 3a 4e 4f 50 0d  |NOP:NOP:NOP:NOP.|
00000800  05 00 08 20 44 45 59 0d  05 0a 0b 20 42 4e 45 20  |... DEY.... BNE |
00000810  77 32 0d 05 14 08 20 44  45 58 0d 05 1e 0b 20 42  |w2.... DEX.... B|
00000820  4e 45 20 77 31 0d 05 28  08 20 52 54 53 0d 05 32  |NE w1..(. RTS..2|
00000830  09 2e 74 65 78 74 0d 05  3c 12 20 4f 50 54 20 a4  |..text..<. OPT .|
00000840  65 71 75 62 28 32 32 29  0d 05 46 11 20 4f 50 54  |equb(22)..F. OPT|
00000850  20 a4 65 71 75 62 28 35  29 0d 05 50 12 20 4f 50  | .equb(5)..P. OP|
00000860  54 20 a4 65 71 75 62 28  33 31 29 0d 05 5a 11 20  |T .equb(31)..Z. |
00000870  4f 50 54 20 a4 65 71 75  62 28 32 29 0d 05 64 11  |OPT .equb(2)..d.|
00000880  20 4f 50 54 20 a4 65 71  75 62 28 34 29 0d 05 6e  | OPT .equb(4)..n|
00000890  1c 20 4f 50 54 20 a4 65  71 75 73 28 22 57 65 6c  |. OPT .equs("Wel|
000008a0  6c 20 44 6f 6e 65 21 22  29 0d 05 78 12 20 4f 50  |l Done!")..x. OP|
000008b0  54 20 a4 65 71 75 62 28  33 31 29 0d 05 82 11 20  |T .equb(31).... |
000008c0  4f 50 54 20 a4 65 71 75  62 28 32 29 0d 05 8c 11  |OPT .equb(2)....|
000008d0  20 4f 50 54 20 a4 65 71  75 62 28 36 29 0d 05 96  | OPT .equb(6)...|
000008e0  24 20 4f 50 54 20 a4 65  71 75 73 28 22 4c 65 76  |$ OPT .equs("Lev|
000008f0  65 6c 20 31 20 43 6f 6d  70 6c 65 74 65 64 21 22  |el 1 Completed!"|
00000900  29 0d 05 a0 08 20 42 52  4b 0d 05 aa 25 2e 70 6c  |).... BRK...%.pl|
00000910  6f 74 20 4c 44 41 20 61  64 64 72 3a 50 48 41 3a  |ot LDA addr:PHA:|
00000920  4c 44 41 20 61 64 64 72  2b 31 3a 50 48 41 0d 05  |LDA addr+1:PHA..|
00000930  b4 26 20 4c 44 41 20 61  3a 53 54 41 20 61 64 64  |.& LDA a:STA add|
00000940  72 3a 4c 44 41 20 61 2b  31 3a 53 54 41 20 61 64  |r:LDA a+1:STA ad|
00000950  64 72 2b 31 0d 05 be 11  20 4a 53 52 20 65 6f 72  |dr+1.... JSR eor|
00000960  73 70 6c 6f 74 0d 05 c8  20 20 50 4c 41 3a 53 54  |splot...  PLA:ST|
00000970  41 20 61 64 64 72 2b 31  3a 50 4c 41 20 53 54 41  |A addr+1:PLA STA|
00000980  20 61 64 64 72 0d 05 d2  08 20 52 54 53 0d 05 dc  | addr.... RTS...|
00000990  1e 2e 73 70 6c 6f 74 20  20 20 20 20 20 20 5c 20  |..splot       \ |
000009a0  70 6c 6f 74 20 73 70 72  69 74 65 0d 05 e6 0d 20  |plot sprite.... |
000009b0  4c 44 41 20 61 64 64 72  0d 05 f0 08 20 50 48 41  |LDA addr.... PHA|
000009c0  0d 05 fa 0f 20 53 54 41  20 74 63 61 64 64 72 0d  |.... STA tcaddr.|
000009d0  06 04 0f 20 4c 44 41 20  61 64 64 72 2b 31 0d 06  |... LDA addr+1..|
000009e0  0e 08 20 50 48 41 0d 06  18 11 20 53 54 41 20 74  |.. PHA.... STA t|
000009f0  63 61 64 64 72 2b 31 0d  06 22 07 2e 6c 31 0d 06  |caddr+1.."..l1..|
00000a00  2c 0b 20 4c 44 59 20 23  30 0d 06 36 0b 20 4c 44  |,. LDY #0..6. LD|
00000a10  58 20 23 34 0d 06 40 07  2e 6c 32 0d 06 4a 1f 20  |X #4..@..l2..J. |
00000a20  4c 44 41 20 28 64 61 74  61 29 2c 59 20 5c 20 54  |LDA (data),Y \ T|
00000a30  68 69 73 20 69 73 20 6e  6f 74 0d 06 54 24 20 53  |his is not..T$ S|
00000a40  54 41 20 28 61 64 64 72  29 2c 59 20 5c 20 62 61  |TA (addr),Y \ ba|
00000a50  64 20 70 72 6f 67 72 61  6d 6d 69 6e 67 21 0d 06  |d programming!..|
00000a60  5e 23 20 49 4e 59 20 20  20 20 20 20 20 20 20 20  |^# INY          |
00000a70  5c 20 4d 61 6b 65 73 20  69 74 20 66 61 73 74 65  |\ Makes it faste|
00000a80  72 0d 06 68 11 20 4c 44  41 20 28 64 61 74 61 29  |r..h. LDA (data)|
00000a90  2c 59 0d 06 72 11 20 53  54 41 20 28 61 64 64 72  |,Y..r. STA (addr|
00000aa0  29 2c 59 0d 06 7c 08 20  49 4e 59 0d 06 86 11 20  |),Y..|. INY.... |
00000ab0  4c 44 41 20 28 64 61 74  61 29 2c 59 0d 06 90 11  |LDA (data),Y....|
00000ac0  20 53 54 41 20 28 61 64  64 72 29 2c 59 0d 06 9a  | STA (addr),Y...|
00000ad0  08 20 49 4e 59 0d 06 a4  11 20 4c 44 41 20 28 64  |. INY.... LDA (d|
00000ae0  61 74 61 29 2c 59 0d 06  ae 11 20 53 54 41 20 28  |ata),Y.... STA (|
00000af0  61 64 64 72 29 2c 59 0d  06 b8 08 20 49 4e 59 0d  |addr),Y.... INY.|
00000b00  06 c2 11 20 4c 44 41 20  28 64 61 74 61 29 2c 59  |... LDA (data),Y|
00000b10  0d 06 cc 11 20 53 54 41  20 28 61 64 64 72 29 2c  |.... STA (addr),|
00000b20  59 0d 06 d6 08 20 49 4e  59 0d 06 e0 11 20 4c 44  |Y.... INY.... LD|
00000b30  41 20 28 64 61 74 61 29  2c 59 0d 06 ea 11 20 53  |A (data),Y.... S|
00000b40  54 41 20 28 61 64 64 72  29 2c 59 0d 06 f4 08 20  |TA (addr),Y.... |
00000b50  49 4e 59 0d 06 fe 11 20  4c 44 41 20 28 64 61 74  |INY.... LDA (dat|
00000b60  61 29 2c 59 0d 07 08 11  20 53 54 41 20 28 61 64  |a),Y.... STA (ad|
00000b70  64 72 29 2c 59 0d 07 12  08 20 49 4e 59 0d 07 1c  |dr),Y.... INY...|
00000b80  11 20 4c 44 41 20 28 64  61 74 61 29 2c 59 0d 07  |. LDA (data),Y..|
00000b90  26 11 20 53 54 41 20 28  61 64 64 72 29 2c 59 0d  |&. STA (addr),Y.|
00000ba0  07 30 08 20 49 4e 59 0d  07 3a 0d 20 4c 44 41 20  |.0. INY..:. LDA |
00000bb0  61 64 64 72 0d 07 44 08  20 43 4c 43 0d 07 4e 0d  |addr..D. CLC..N.|
00000bc0  20 41 44 43 20 23 26 33  38 0d 07 58 0d 20 53 54  | ADC #&38..X. ST|
00000bd0  41 20 61 64 64 72 0d 07  62 0f 20 4c 44 41 20 61  |A addr..b. LDA a|
00000be0  64 64 72 2b 31 0d 07 6c  0b 20 41 44 43 20 23 31  |ddr+1..l. ADC #1|
00000bf0  0d 07 76 0f 20 53 54 41  20 61 64 64 72 2b 31 0d  |..v. STA addr+1.|
00000c00  07 80 08 20 44 45 58 0d  07 8a 0b 20 42 4e 45 20  |... DEX.... BNE |
00000c10  6c 32 0d 07 94 0d 20 4c  44 41 20 64 61 74 61 0d  |l2.... LDA data.|
00000c20  07 9e 08 20 43 4c 43 0d  07 a8 12 20 41 44 43 20  |... CLC.... ADC |
00000c30  23 53 70 72 44 65 70 74  68 0d 07 b2 0d 20 53 54  |#SprDepth.... ST|
00000c40  41 20 64 61 74 61 0d 07  bc 0f 20 4c 44 41 20 64  |A data.... LDA d|
00000c50  61 74 61 2b 31 0d 07 c6  0b 20 41 44 43 20 23 30  |ata+1.... ADC #0|
00000c60  0d 07 d0 0f 20 53 54 41  20 64 61 74 61 2b 31 0d  |.... STA data+1.|
00000c70  07 da 0f 20 4c 44 41 20  74 63 61 64 64 72 0d 07  |... LDA tcaddr..|
00000c80  e4 0b 20 41 44 43 20 23  38 0d 07 ee 0d 20 53 54  |.. ADC #8.... ST|
00000c90  41 20 61 64 64 72 0d 07  f8 0f 20 53 54 41 20 74  |A addr.... STA t|
00000ca0  63 61 64 64 72 0d 08 02  11 20 4c 44 41 20 74 63  |caddr.... LDA tc|
00000cb0  61 64 64 72 2b 31 0d 08  0c 0b 20 41 44 43 20 23  |addr+1.... ADC #|
00000cc0  30 0d 08 16 11 20 53 54  41 20 74 63 61 64 64 72  |0.... STA tcaddr|
00000cd0  2b 31 0d 08 20 0f 20 53  54 41 20 61 64 64 72 2b  |+1.. . STA addr+|
00000ce0  31 0d 08 2a 0d 20 44 45  43 20 63 6f 6c 73 0d 08  |1..*. DEC cols..|
00000cf0  34 0b 20 42 4e 45 20 6c  31 0d 08 3e 08 20 50 4c  |4. BNE l1..>. PL|
00000d00  41 0d 08 48 0f 20 53 54  41 20 61 64 64 72 2b 31  |A..H. STA addr+1|
00000d10  0d 08 52 08 20 50 4c 41  0d 08 5c 0d 20 53 54 41  |..R. PLA..\. STA|
00000d20  20 61 64 64 72 0d 08 66  08 20 52 54 53 0d 08 70  | addr..f. RTS..p|
00000d30  1e 2e 73 70 6c 6f 74 32  20 20 20 20 20 20 20 20  |..splot2        |
00000d40  5c 20 74 6f 20 65 6e 61  62 6c 65 0d 08 7a 1c 20  |\ to enable..z. |
00000d50  4c 44 41 20 23 53 70 72  57 69 64 74 68 20 5c 20  |LDA #SprWidth \ |
00000d60  72 65 76 65 72 73 65 0d  08 84 24 20 53 45 43 20  |reverse...$ SEC |
00000d70  20 20 20 20 20 20 20 20  20 20 5c 20 73 70 72 69  |          \ spri|
00000d80  74 65 2d 63 6c 69 70 70  69 6e 67 0d 08 8e 0d 20  |te-clipping.... |
00000d90  53 42 43 20 63 6f 6c 73  0d 08 98 08 20 54 41 59  |SBC cols.... TAY|
00000da0  0d 08 a2 10 20 42 45 51  20 64 6f 73 70 6c 6f 74  |.... BEQ dosplot|
00000db0  0d 08 ac 08 2e 73 32 6c  0d 08 b6 0d 20 4c 44 41  |.....s2l.... LDA|
00000dc0  20 64 61 74 61 0d 08 c0  08 20 43 4c 43 0d 08 ca  | data.... CLC...|
00000dd0  12 20 41 44 43 20 23 53  70 72 44 65 70 74 68 0d  |. ADC #SprDepth.|
00000de0  08 d4 0d 20 53 54 41 20  64 61 74 61 0d 08 de 0f  |... STA data....|
00000df0  20 4c 44 41 20 64 61 74  61 2b 31 0d 08 e8 0b 20  | LDA data+1.... |
00000e00  41 44 43 20 23 30 0d 08  f2 0f 20 53 54 41 20 64  |ADC #0.... STA d|
00000e10  61 74 61 2b 31 0d 08 fc  08 20 44 45 59 0d 09 06  |ata+1.... DEY...|
00000e20  0c 20 42 4e 45 20 73 32  6c 0d 09 10 0c 2e 64 6f  |. BNE s2l.....do|
00000e30  73 70 6c 6f 74 0d 09 1a  0e 20 4a 4d 50 20 73 70  |splot.... JMP sp|
00000e40  6c 6f 74 0d 09 24 0d 2e  65 6f 72 73 70 6c 6f 74  |lot..$..eorsplot|
00000e50  0d 09 2e 0d 20 4c 44 41  20 61 64 64 72 0d 09 38  |.... LDA addr..8|
00000e60  08 20 50 48 41 0d 09 42  0f 20 53 54 41 20 74 63  |. PHA..B. STA tc|
00000e70  61 64 64 72 0d 09 4c 0f  20 4c 44 41 20 61 64 64  |addr..L. LDA add|
00000e80  72 2b 31 0d 09 56 08 20  50 48 41 0d 09 60 11 20  |r+1..V. PHA..`. |
00000e90  53 54 41 20 74 63 61 64  64 72 2b 31 0d 09 6a 08  |STA tcaddr+1..j.|
00000ea0  2e 65 6c 31 0d 09 74 0b  20 4c 44 59 20 23 30 0d  |.el1..t. LDY #0.|
00000eb0  09 7e 12 20 4c 44 58 20  23 34 3a 53 54 58 20 63  |.~. LDX #4:STX c|
00000ec0  64 0d 09 88 10 2e 65 65  6c 32 20 4c 44 58 20 23  |d.....eel2 LDX #|
00000ed0  38 0d 09 92 08 2e 65 6c  32 0d 09 9c 1b 20 4c 44  |8.....el2.... LD|
00000ee0  41 20 28 64 61 74 61 29  2c 59 3a 42 45 51 20 62  |A (data),Y:BEQ b|
00000ef0  6c 61 63 6b 0d 09 a6 1f  20 50 48 41 3a 4c 44 41  |lack.... PHA:LDA|
00000f00  20 28 61 64 64 72 29 2c  59 3a 42 45 51 20 6e 6f  | (addr),Y:BEQ no|
00000f10  68 69 74 0d 09 b0 19 20  4c 44 41 20 23 31 3a 53  |hit.... LDA #1:S|
00000f20  54 41 20 64 65 61 74 68  66 6c 61 67 0d 09 ba 0a  |TA deathflag....|
00000f30  2e 6e 6f 68 69 74 0d 09  c4 08 20 50 4c 41 0d 09  |.nohit.... PLA..|
00000f40  ce 0a 2e 62 6c 61 63 6b  0d 09 d8 20 20 82 20 28  |...black...  . (|
00000f50  61 64 64 72 29 2c 59 3a  53 54 41 20 28 61 64 64  |addr),Y:STA (add|
00000f60  72 29 2c 59 3a 49 4e 59  0d 09 e2 10 20 44 45 58  |r),Y:INY.... DEX|
00000f70  3a 42 4e 45 20 65 6c 32  0d 09 ec 23 20 4c 44 41  |:BNE el2...# LDA|
00000f80  20 61 64 64 72 3a 43 4c  43 3a 41 44 43 20 23 26  | addr:CLC:ADC #&|
00000f90  33 38 3a 53 54 41 20 61  64 64 72 0d 09 f6 21 20  |38:STA addr...! |
00000fa0  4c 44 41 20 61 64 64 72  2b 31 3a 41 44 43 20 23  |LDA addr+1:ADC #|
00000fb0  31 3a 53 54 41 20 61 64  64 72 2b 31 0d 0a 00 0b  |1:STA addr+1....|
00000fc0  20 44 45 43 20 63 64 0d  0a 0a 0d 20 42 4e 45 20  | DEC cd.... BNE |
00000fd0  65 65 6c 32 0d 0a 14 0d  20 4c 44 41 20 64 61 74  |eel2.... LDA dat|
00000fe0  61 0d 0a 1e 1f 20 43 4c  43 3a 41 44 43 20 23 53  |a.... CLC:ADC #S|
00000ff0  70 72 44 65 70 74 68 3a  53 54 41 20 64 61 74 61  |prDepth:STA data|
00001000  0d 0a 28 21 20 4c 44 41  20 64 61 74 61 2b 31 3a  |..(! LDA data+1:|
00001010  41 44 43 20 23 30 3a 53  54 41 20 64 61 74 61 2b  |ADC #0:STA data+|
00001020  31 0d 0a 32 1f 20 4c 44  41 20 74 63 61 64 64 72  |1..2. LDA tcaddr|
00001030  3a 41 44 43 20 23 38 3a  53 54 41 20 61 64 64 72  |:ADC #8:STA addr|
00001040  0d 0a 3c 0f 20 53 54 41  20 74 63 61 64 64 72 0d  |..<. STA tcaddr.|
00001050  0a 46 25 20 4c 44 41 20  74 63 61 64 64 72 2b 31  |.F% LDA tcaddr+1|
00001060  3a 41 44 43 20 23 30 3a  53 54 41 20 74 63 61 64  |:ADC #0:STA tcad|
00001070  64 72 2b 31 0d 0a 50 0f  20 53 54 41 20 61 64 64  |dr+1..P. STA add|
00001080  72 2b 31 0d 0a 5a 0d 20  44 45 43 20 63 6f 6c 73  |r+1..Z. DEC cols|
00001090  0d 0a 64 0c 20 42 4e 45  20 65 6c 31 0d 0a 6e 13  |..d. BNE el1..n.|
000010a0  20 50 4c 41 3a 53 54 41  20 61 64 64 72 2b 31 0d  | PLA:STA addr+1.|
000010b0  0a 78 11 20 50 4c 41 3a  53 54 41 20 61 64 64 72  |.x. PLA:STA addr|
000010c0  0d 0a 82 08 20 52 54 53  0d 0a 8c 20 2e 73 77 69  |.... RTS... .swi|
000010d0  74 63 68 31 20 20 20 20  5c 20 63 68 61 6e 67 65  |tch1    \ change|
000010e0  20 73 63 72 65 65 6e 20  0d 0a 96 1f 20 4c 44 41  | screen .... LDA|
000010f0  20 23 31 39 20 20 20 20  5c 20 73 74 61 72 74 20  | #19    \ start |
00001100  61 64 64 72 65 73 73 0d  0a a0 1d 20 4a 53 52 20  |address.... JSR |
00001110  6f 73 62 79 74 65 20 5c  20 74 6f 20 73 63 72 65  |osbyte \ to scre|
00001120  65 6e 20 31 0d 0a aa 0c  20 4c 44 41 20 23 31 33  |en 1.... LDA #13|
00001130  0d 0a b4 0e 20 53 54 41  20 26 46 45 30 30 0d 0a  |.... STA &FE00..|
00001140  be 1e 20 4c 44 41 20 23  28 73 63 72 65 65 6e 31  |.. LDA #(screen1|
00001150  20 83 20 32 30 34 38 20  81 20 38 29 0d 0a c8 0e  | . 2048 . 8)....|
00001160  20 53 54 41 20 26 46 45  30 31 0d 0a d2 0c 20 4c  | STA &FE01.... L|
00001170  44 41 20 23 31 32 0d 0a  dc 0e 20 53 54 41 20 26  |DA #12.... STA &|
00001180  46 45 30 30 0d 0a e6 1a  20 4c 44 41 20 23 28 73  |FE00.... LDA #(s|
00001190  63 72 65 65 6e 31 20 81  20 32 30 34 38 29 0d 0a  |creen1 . 2048)..|
000011a0  f0 0e 20 53 54 41 20 26  46 45 30 31 0d 0a fa 12  |.. STA &FE01....|
000011b0  20 4c 44 41 20 23 31 3a  53 54 41 20 73 6e 0d 0b  | LDA #1:STA sn..|
000011c0  04 08 20 52 54 53 0d 0b  0e 0c 2e 73 77 69 74 63  |.. RTS.....switc|
000011d0  68 32 0d 0b 18 1f 20 4c  44 41 20 23 31 39 20 20  |h2.... LDA #19  |
000011e0  20 20 5c 20 63 68 61 6e  67 65 20 73 63 72 65 65  |  \ change scree|
000011f0  6e 0d 0b 22 1f 20 4a 53  52 20 6f 73 62 79 74 65  |n..". JSR osbyte|
00001200  20 5c 20 73 74 61 72 74  20 61 64 64 72 65 73 73  | \ start address|
00001210  0d 0b 2c 1d 20 4c 44 41  20 23 31 33 20 20 20 20  |..,. LDA #13    |
00001220  5c 20 74 6f 20 73 63 72  65 65 6e 20 32 0d 0b 36  |\ to screen 2..6|
00001230  0e 20 53 54 41 20 26 46  45 30 30 0d 0b 40 1e 20  |. STA &FE00..@. |
00001240  4c 44 41 20 23 28 73 63  72 65 65 6e 32 20 83 20  |LDA #(screen2 . |
00001250  32 30 34 38 20 81 20 38  29 0d 0b 4a 0e 20 53 54  |2048 . 8)..J. ST|
00001260  41 20 26 46 45 30 31 0d  0b 54 0c 20 4c 44 41 20  |A &FE01..T. LDA |
00001270  23 31 32 0d 0b 5e 0e 20  53 54 41 20 26 46 45 30  |#12..^. STA &FE0|
00001280  30 0d 0b 68 1a 20 4c 44  41 20 23 28 73 63 72 65  |0..h. LDA #(scre|
00001290  65 6e 32 20 81 20 32 30  34 38 29 0d 0b 72 0e 20  |en2 . 2048)..r. |
000012a0  53 54 41 20 26 46 45 30  31 0d 0b 7c 12 20 4c 44  |STA &FE01..|. LD|
000012b0  41 20 23 32 3a 53 54 41  20 73 6e 0d 0b 86 08 20  |A #2:STA sn.... |
000012c0  52 54 53 0d 0b 90 0b 2e  73 63 72 6f 6c 6c 0d 0b  |RTS.....scroll..|
000012d0  9a 0c 20 4c 44 41 20 23  32 32 0d 0b a4 0f 20 4a  |.. LDA #22.... J|
000012e0  53 52 20 6f 73 77 72 63  68 0d 0b ae 0b 20 4c 44  |SR oswrch.... LD|
000012f0  41 20 23 35 0d 0b b8 0f  20 4a 53 52 20 6f 73 77  |A #5.... JSR osw|
00001300  72 63 68 0d 0b c2 17 20  4c 44 41 20 23 32 33 3a  |rch.... LDA #23:|
00001310  4a 53 52 20 6f 73 77 72  63 68 0d 0b cc 16 20 4c  |JSR oswrch.... L|
00001320  44 41 20 23 30 3a 4a 53  52 20 6f 73 77 72 63 68  |DA #0:JSR oswrch|
00001330  0d 0b d6 17 20 4c 44 41  20 23 31 30 3a 4a 53 52  |.... LDA #10:JSR|
00001340  20 6f 73 77 72 63 68 0d  0b e0 17 20 4c 44 41 20  | oswrch.... LDA |
00001350  23 33 32 3a 4a 53 52 20  6f 73 77 72 63 68 0d 0b  |#32:JSR oswrch..|
00001360  ea 21 20 4c 44 41 20 23  30 3a 4a 53 52 20 6f 73  |.! LDA #0:JSR os|
00001370  77 72 63 68 3a 4a 53 52  20 6f 73 77 72 63 68 0d  |wrch:JSR oswrch.|
00001380  0b f4 1a 20 4a 53 52 20  6f 73 77 72 63 68 3a 4a  |... JSR oswrch:J|
00001390  53 52 20 6f 73 77 72 63  68 0d 0b fe 1a 20 4a 53  |SR oswrch.... JS|
000013a0  52 20 6f 73 77 72 63 68  3a 4a 53 52 20 6f 73 77  |R oswrch:JSR osw|
000013b0  72 63 68 0d 0c 08 1f 20  4c 44 41 20 23 30 20 20  |rch.... LDA #0  |
000013c0  5c 20 63 6c 65 61 72 20  62 72 65 61 6b 20 66 6c  |\ clear break fl|
000013d0  61 67 0d 0c 12 0c 20 53  54 41 20 26 46 46 0d 0c  |ag.... STA &FF..|
000013e0  1c 12 20 53 54 41 20 64  65 61 74 68 66 6c 61 67  |.. STA deathflag|
000013f0  0d 0c 26 0b 20 4c 44 59  20 23 30 0d 0c 30 15 20  |..&. LDY #0..0. |
00001400  4c 44 41 20 23 26 33 30  30 30 20 83 20 32 35 36  |LDA #&3000 . 256|
00001410  0d 0c 3a 0c 20 53 54 41  20 26 39 30 0d 0c 44 15  |..:. STA &90..D.|
00001420  20 4c 44 41 20 23 26 33  30 30 30 20 81 20 32 35  | LDA #&3000 . 25|
00001430  36 0d 0c 4e 0c 20 53 54  41 20 26 39 31 0d 0c 58  |6..N. STA &91..X|
00001440  0a 2e 62 6c 6f 6f 70 0d  0c 62 0b 20 4c 44 41 20  |..bloop..b. LDA |
00001450  23 30 0d 0c 6c 1d 20 53  54 41 20 28 26 39 30 29  |#0..l. STA (&90)|
00001460  2c 59 20 5c 20 63 6c 65  61 72 20 62 6f 74 68 0d  |,Y \ clear both.|
00001470  0c 76 21 20 4c 44 41 20  26 39 30 20 20 20 20 20  |.v! LDA &90     |
00001480  5c 20 6f 66 20 74 68 65  20 73 63 72 65 65 6e 73  |\ of the screens|
00001490  0d 0c 80 21 20 43 4c 43  20 20 20 20 20 20 20 20  |...! CLC        |
000014a0  20 5c 20 2d 4e 42 2d 20  74 68 69 73 20 77 69 6c  | \ -NB- this wil|
000014b0  6c 0d 0c 8a 21 20 41 44  43 20 23 31 20 20 20 20  |l...! ADC #1    |
000014c0  20 20 5c 20 63 6c 65 61  72 20 66 72 6f 6d 20 74  |  \ clear from t|
000014d0  68 65 0d 0c 94 23 20 53  54 41 20 26 39 30 20 20  |he...# STA &90  |
000014e0  20 20 20 5c 20 73 74 61  72 74 20 6f 66 20 73 63  |   \ start of sc|
000014f0  72 65 65 6e 31 0d 0c 9e  21 20 42 43 43 20 6e 63  |reen1...! BCC nc|
00001500  20 20 20 20 20 20 5c 20  61 6c 6c 20 74 68 65 20  |      \ all the |
00001510  77 61 79 20 74 6f 0d 0c  a8 18 20 49 4e 43 20 26  |way to.... INC &|
00001520  39 31 20 20 20 20 20 5c  20 26 37 46 46 46 0d 0c  |91     \ &7FFF..|
00001530  b2 07 2e 6e 63 0d 0c bc  0c 20 4c 44 41 20 26 39  |...nc.... LDA &9|
00001540  30 0d 0c c6 15 20 43 4d  50 20 23 26 38 30 30 30  |0.... CMP #&8000|
00001550  20 83 20 32 35 36 0d 0c  d0 0e 20 42 4e 45 20 62  | . 256.... BNE b|
00001560  6c 6f 6f 70 0d 0c da 0c  20 4c 44 41 20 26 39 31  |loop.... LDA &91|
00001570  0d 0c e4 15 20 43 4d 50  20 23 26 38 30 30 30 20  |.... CMP #&8000 |
00001580  81 20 32 35 36 0d 0c ee  0e 20 42 4e 45 20 62 6c  |. 256.... BNE bl|
00001590  6f 6f 70 0d 0c f8 20 20  4c 44 41 20 23 6d 61 70  |oop...  LDA #map|
000015a0  20 83 20 32 35 36 20 5c  20 69 6e 69 74 69 61 6c  | . 256 \ initial|
000015b0  69 73 65 0d 0d 02 23 20  53 54 41 20 26 37 30 20  |ise...# STA &70 |
000015c0  20 20 20 20 20 20 20 20  20 5c 20 70 6f 69 6e 74  |         \ point|
000015d0  65 72 73 20 74 6f 0d 0d  0c 1e 20 4c 44 41 20 23  |ers to.... LDA #|
000015e0  6d 61 70 20 81 20 32 35  36 20 5c 20 6d 61 70 20  |map . 256 \ map |
000015f0  64 61 74 61 0d 0d 16 0c  20 53 54 41 20 26 37 31  |data.... STA &71|
00001600  0d 0d 20 20 2e 73 63 72  6c 6f 6f 70 20 20 20 20  |..  .scrloop    |
00001610  20 20 5c 20 63 6f 6e 74  72 6f 6c 20 6c 6f 6f 70  |  \ control loop|
00001620  0d 0d 2a 0d 20 4a 53 52  20 64 65 6d 6f 0d 0d 34  |..*. JSR demo..4|
00001630  26 20 4a 53 52 20 73 77  69 74 63 68 31 20 20 5c  |& JSR switch1  \|
00001640  20 73 77 69 74 63 68 20  74 6f 20 73 63 72 65 65  | switch to scree|
00001650  6e 20 31 0d 0d 3e 0d 20  43 4d 50 20 23 26 45 41  |n 1..>. CMP #&EA|
00001660  0d 0d 48 17 20 4c 44 41  20 23 73 63 72 65 65 6e  |..H. LDA #screen|
00001670  32 20 83 20 32 35 36 0d  0d 52 08 20 43 4c 43 0d  |2 . 256..R. CLC.|
00001680  0d 5c 15 20 41 44 43 20  23 41 4c 49 47 4e 20 83  |.\. ADC #ALIGN .|
00001690  20 32 35 36 0d 0d 66 0f  20 53 54 41 20 6d 61 70  | 256..f. STA map|
000016a0  74 6f 70 0d 0d 70 17 20  4c 44 41 20 23 73 63 72  |top..p. LDA #scr|
000016b0  65 65 6e 32 20 81 20 32  35 36 0d 0d 7a 15 20 41  |een2 . 256..z. A|
000016c0  44 43 20 23 41 4c 49 47  4e 20 81 20 32 35 36 0d  |DC #ALIGN . 256.|
000016d0  0d 84 11 20 53 54 41 20  6d 61 70 74 6f 70 2b 31  |... STA maptop+1|
000016e0  0d 0d 8e 26 20 4a 53 52  20 70 6c 6f 74 6d 61 70  |...& JSR plotmap|
000016f0  20 5c 20 70 6c 6f 74 20  6d 61 70 20 6f 76 65 72  | \ plot map over|
00001700  20 73 63 72 20 32 0d 0d  98 0d 20 43 4d 50 20 23  | scr 2.... CMP #|
00001710  26 45 41 0d 0d a2 0e 20  42 4e 45 20 63 6f 6e 74  |&EA.... BNE cont|
00001720  31 0d 0d ac 11 20 4a 53  52 20 77 65 6c 6c 64 6f  |1.... JSR welldo|
00001730  6e 65 0d 0d b6 08 20 52  54 53 0d 0d c0 0a 2e 63  |ne.... RTS.....c|
00001740  6f 6e 74 31 0d 0d ca 0d  20 4a 53 52 20 64 65 6d  |ont1.... JSR dem|
00001750  6f 0d 0d d4 26 20 4a 53  52 20 73 77 69 74 63 68  |o...& JSR switch|
00001760  32 20 5c 20 72 65 76 65  61 6c 20 6d 61 70 20 6f  |2 \ reveal map o|
00001770  6e 20 73 63 72 20 32 0d  0d de 17 20 4c 44 41 20  |n scr 2.... LDA |
00001780  23 73 63 72 65 65 6e 31  20 83 20 32 35 36 0d 0d  |#screen1 . 256..|
00001790  e8 08 20 43 4c 43 0d 0d  f2 15 20 41 44 43 20 23  |.. CLC.... ADC #|
000017a0  41 4c 49 47 4e 20 83 20  32 35 36 0d 0d fc 0f 20  |ALIGN . 256.... |
000017b0  53 54 41 20 6d 61 70 74  6f 70 0d 0e 06 17 20 4c  |STA maptop.... L|
000017c0  44 41 20 23 73 63 72 65  65 6e 31 20 81 20 32 35  |DA #screen1 . 25|
000017d0  36 0d 0e 10 15 20 41 44  43 20 23 41 4c 49 47 4e  |6.... ADC #ALIGN|
000017e0  20 81 20 32 35 36 0d 0e  1a 11 20 53 54 41 20 6d  | . 256.... STA m|
000017f0  61 70 74 6f 70 2b 31 0d  0e 24 26 20 4a 53 52 20  |aptop+1..$& JSR |
00001800  70 6c 6f 74 6d 61 70 20  5c 20 70 6c 6f 74 20 6d  |plotmap \ plot m|
00001810  61 70 20 6f 76 65 72 20  73 63 72 20 31 0d 0e 2e  |ap over scr 1...|
00001820  0d 20 43 4d 50 20 23 26  45 41 0d 0e 38 0e 20 42  |. CMP #&EA..8. B|
00001830  4e 45 20 63 6f 6e 74 32  0d 0e 42 11 20 4a 53 52  |NE cont2..B. JSR|
00001840  20 77 65 6c 6c 64 6f 6e  65 0d 0e 4c 08 20 52 54  | welldone..L. RT|
00001850  53 0d 0e 56 0a 2e 63 6f  6e 74 32 0d 0e 60 12 20  |S..V..cont2..`. |
00001860  4c 44 41 20 64 65 61 74  68 66 6c 61 67 0d 0e 6a  |LDA deathflag..j|
00001870  0b 20 43 4d 50 20 23 32  0d 0e 74 13 20 42 43 43  |. CMP #2..t. BCC|
00001880  20 6e 6f 74 64 65 61 64  79 65 74 0d 0e 7e 0f 20  | notdeadyet..~. |
00001890  4a 4d 50 20 73 63 72 6f  6c 6c 0d 0e 88 0f 2e 6e  |JMP scroll.....n|
000018a0  6f 74 64 65 61 64 79 65  74 0d 0e 92 21 20 42 49  |otdeadyet...! BI|
000018b0  54 20 26 46 46 20 20 20  20 20 5c 20 74 65 73 74  |T &FF     \ test|
000018c0  20 66 6f 72 20 62 72 65  61 6b 0d 0e 9c 10 20 42  | for break.... B|
000018d0  45 51 20 73 63 72 6c 6f  6f 70 0d 0e a6 08 20 42  |EQ scrloop.... B|
000018e0  52 4b 0d 0e b0 12 20 4f  50 54 20 a4 65 71 75 62  |RK.... OPT .equb|
000018f0  28 32 37 29 0d 0e ba 18  20 4f 50 54 20 a4 65 71  |(27).... OPT .eq|
00001900  75 73 28 22 45 73 63 61  70 65 22 29 0d 0e c4 08  |us("Escape")....|
00001910  20 42 52 4b 0d 0e ce 21  2e 70 6c 6f 74 6d 61 70  | BRK...!.plotmap|
00001920  20 20 20 20 20 20 5c 20  70 6c 6f 74 20 61 20 73  |      \ plot a s|
00001930  63 72 65 65 6e 0d 0e d8  25 20 49 4e 43 20 63 6f  |creen...% INC co|
00001940  75 6e 74 65 72 20 20 5c  20 66 72 6f 6d 20 74 68  |unter  \ from th|
00001950  65 20 6d 61 70 20 64 61  74 61 0d 0e e2 0c 20 4c  |e map data.... L|
00001960  44 41 20 26 37 30 0d 0e  ec 0e 20 53 54 41 20 6f  |DA &70.... STA o|
00001970  6c 64 37 30 0d 0e f6 0c  20 4c 44 41 20 26 37 31  |ld70.... LDA &71|
00001980  0d 0f 00 10 20 53 54 41  20 6f 6c 64 37 30 2b 31  |.... STA old70+1|
00001990  0d 0f 0a 0b 20 4c 44 59  20 23 30 0d 0f 14 0d 20  |.... LDY #0.... |
000019a0  53 54 59 20 6d 63 6f 6c  0d 0f 1e 0f 20 4c 44 41  |STY mcol.... LDA|
000019b0  20 6d 61 70 74 6f 70 0d  0f 28 0d 20 53 54 41 20  | maptop..(. STA |
000019c0  61 64 64 72 0d 0f 32 11  20 4c 44 41 20 6d 61 70  |addr..2. LDA map|
000019d0  74 6f 70 2b 31 0d 0f 3c  0f 20 53 54 41 20 61 64  |top+1..<. STA ad|
000019e0  64 72 2b 31 0d 0f 46 07  2e 6d 6c 0d 0f 50 0b 20  |dr+1..F..ml..P. |
000019f0  4c 44 59 20 23 30 0d 0f  5a 0d 20 4c 44 41 20 61  |LDY #0..Z. LDA a|
00001a00  64 64 72 0d 0f 64 10 20  53 54 41 20 74 6f 70 61  |ddr..d. STA topa|
00001a10  64 64 72 0d 0f 6e 0f 20  4c 44 41 20 61 64 64 72  |ddr..n. LDA addr|
00001a20  2b 31 0d 0f 78 12 20 53  54 41 20 74 6f 70 61 64  |+1..x. STA topad|
00001a30  64 72 2b 31 0d 0f 82 08  2e 70 6d 6c 0d 0f 8c 24  |dr+1.....pml...$|
00001a40  20 4c 44 41 20 28 26 37  30 29 2c 59 20 20 20 5c  | LDA (&70),Y   \|
00001a50  20 6c 6f 61 64 20 6d 61  70 20 73 79 6d 62 6f 6c  | load map symbol|
00001a60  0d 0f 96 0d 20 43 4d 50  20 23 26 45 41 0d 0f a0  |.... CMP #&EA...|
00001a70  0f 20 42 4e 45 20 6e 6f  74 65 6f 64 0d 0f aa 08  |. BNE noteod....|
00001a80  20 52 54 53 0d 0f b4 0b  2e 6e 6f 74 65 6f 64 0d  | RTS.....noteod.|
00001a90  0f be 24 20 4a 53 52 20  73 63 68 6f 6f 73 65 20  |..$ JSR schoose |
00001aa0  20 20 5c 20 61 6e 64 20  63 68 6f 6f 73 65 20 74  |  \ and choose t|
00001ab0  68 65 20 0d 0f c8 22 20  4c 44 41 20 6d 63 6f 6c  |he ..." LDA mcol|
00001ac0  20 20 20 20 20 20 5c 20  63 6f 72 72 65 73 70 6f  |      \ correspo|
00001ad0  6e 64 69 6e 67 0d 0f d2  1b 20 42 45 51 20 64 6f  |nding.... BEQ do|
00001ae0  63 6c 69 70 20 20 20 20  5c 20 73 70 72 69 74 65  |clip    \ sprite|
00001af0  0d 0f dc 12 20 4c 44 41  20 23 53 70 72 57 69 64  |.... LDA #SprWid|
00001b00  74 68 0d 0f e6 0d 20 53  54 41 20 63 6f 6c 73 0d  |th.... STA cols.|
00001b10  0f f0 13 20 4a 4d 50 20  6f 76 65 72 64 6f 63 6c  |... JMP overdocl|
00001b20  69 70 0d 0f fa 13 2e 64  6f 63 6c 69 70 20 20 20  |ip.....doclip   |
00001b30  20 20 20 20 20 0d 10 04  1f 20 4c 44 41 20 6e 63  |     .... LDA nc|
00001b40  6f 6c 73 20 20 20 20 20  5c 20 6f 6e 6c 79 20 70  |ols     \ only p|
00001b50  72 69 6e 74 0d 10 0e 24  20 53 54 41 20 63 6f 6c  |rint...$ STA col|
00001b60  73 20 20 20 20 20 20 5c  20 27 6e 63 6f 6c 73 27  |s      \ 'ncols'|
00001b70  20 63 6f 6c 75 6d 6e 73  0d 10 18 22 2e 6f 76 65  | columns...".ove|
00001b80  72 64 6f 63 6c 69 70 20  20 20 20 5c 20 6f 66 20  |rdoclip    \ of |
00001b90  74 68 65 20 73 70 72 69  74 65 0d 10 22 0f 20 53  |the sprite..". S|
00001ba0  54 59 20 79 73 74 6f 72  65 0d 10 2c 22 20 4c 44  |TY ystore..," LD|
00001bb0  41 20 6d 63 6f 6c 20 20  20 20 20 20 20 20 5c 20  |A mcol        \ |
00001bc0  69 66 20 6e 6f 74 20 6c  61 73 74 0d 10 36 25 20  |if not last..6% |
00001bd0  43 4d 50 20 23 4d 61 70  57 69 64 74 68 2d 31 20  |CMP #MapWidth-1 |
00001be0  5c 20 63 6f 6c 75 6d 6e  20 74 68 65 6e 20 64 6f  |\ column then do|
00001bf0  0d 10 40 25 20 42 4e 45  20 64 6f 73 70 6c 6f 74  |..@% BNE dosplot|
00001c00  32 20 20 20 20 5c 20 61  20 72 65 76 65 72 73 65  |2    \ a reverse|
00001c10  20 63 6c 69 70 0d 10 4a  12 20 4c 44 41 20 23 53  | clip..J. LDA #S|
00001c20  70 72 57 69 64 74 68 0d  10 54 08 20 53 45 43 0d  |prWidth..T. SEC.|
00001c30  10 5e 0e 20 53 42 43 20  6e 63 6f 6c 73 0d 10 68  |.^. SBC ncols..h|
00001c40  0d 20 42 4e 45 20 67 6f  6f 6e 0d 10 72 12 20 4c  |. BNE goon..r. L|
00001c50  44 41 20 23 53 70 72 57  69 64 74 68 0d 10 7c 12  |DA #SprWidth..|.|
00001c60  2e 67 6f 6f 6e 20 53 54  41 20 63 6f 6c 73 0d 10  |.goon STA cols..|
00001c70  86 26 20 4a 53 52 20 73  70 6c 6f 74 20 20 20 20  |.& JSR splot    |
00001c80  20 20 5c 20 64 6f 20 74  68 65 20 63 6c 69 70 20  |  \ do the clip |
00001c90  74 68 65 20 0d 10 90 26  20 4a 4d 50 20 6f 76 65  |the ...& JMP ove|
00001ca0  72 73 70 6c 6f 74 32 20  5c 20 6f 74 68 65 72 20  |rsplot2 \ other |
00001cb0  77 61 79 20 61 72 6f 75  6e 64 0d 10 9a 0d 2e 64  |way around.....d|
00001cc0  6f 73 70 6c 6f 74 32 0d  10 a4 0f 20 4a 53 52 20  |osplot2.... JSR |
00001cd0  73 70 6c 6f 74 32 0d 10  ae 0f 2e 6f 76 65 72 73  |splot2.....overs|
00001ce0  70 6c 6f 74 32 0d 10 b8  23 20 4c 44 59 20 79 73  |plot2...# LDY ys|
00001cf0  74 6f 72 65 20 20 20 20  20 5c 20 67 6f 20 6f 6e  |tore     \ go on|
00001d00  20 74 6f 20 6e 65 78 74  0d 10 c2 1d 20 4c 44 41  | to next.... LDA|
00001d10  20 61 64 64 72 20 20 20  20 20 20 20 5c 20 6d 61  | addr       \ ma|
00001d20  70 20 72 6f 77 0d 10 cc  08 20 43 4c 43 0d 10 d6  |p row.... CLC...|
00001d30  15 20 41 44 43 20 23 49  6e 63 4e 72 20 83 20 32  |. ADC #IncNr . 2|
00001d40  35 36 0d 10 e0 0d 20 53  54 41 20 61 64 64 72 0d  |56.... STA addr.|
00001d50  10 ea 0f 20 4c 44 41 20  61 64 64 72 2b 31 0d 10  |... LDA addr+1..|
00001d60  f4 15 20 41 44 43 20 23  49 6e 63 4e 72 20 81 20  |.. ADC #IncNr . |
00001d70  32 35 36 0d 10 fe 0f 20  53 54 41 20 61 64 64 72  |256.... STA addr|
00001d80  2b 31 0d 11 08 08 20 49  4e 59 0d 11 12 12 20 43  |+1.... INY.... C|
00001d90  50 59 20 23 4d 61 70 44  65 70 74 68 0d 11 1c 0c  |PY #MapDepth....|
00001da0  20 42 4e 45 20 70 6d 6c  0d 11 26 0d 20 4c 44 41  | BNE pml..&. LDA|
00001db0  20 6d 63 6f 6c 0d 11 30  0b 20 42 4e 45 20 6f 6b  | mcol..0. BNE ok|
00001dc0  0d 11 3a 0b 20 4c 44 41  20 23 34 0d 11 44 08 20  |..:. LDA #4..D. |
00001dd0  53 45 43 0d 11 4e 0e 20  53 42 43 20 6e 63 6f 6c  |SEC..N. SBC ncol|
00001de0  73 0d 11 58 0d 20 42 45  51 20 6e 64 65 63 0d 11  |s..X. BEQ ndec..|
00001df0  62 08 20 54 41 59 0d 11  6c 09 2e 64 65 63 6c 0d  |b. TAY..l..decl.|
00001e00  11 76 10 20 4c 44 41 20  74 6f 70 61 64 64 72 0d  |.v. LDA topaddr.|
00001e10  11 80 08 20 53 45 43 0d  11 8a 0b 20 53 42 43 20  |... SEC.... SBC |
00001e20  23 38 0d 11 94 10 20 53  54 41 20 74 6f 70 61 64  |#8.... STA topad|
00001e30  64 72 0d 11 9e 12 20 4c  44 41 20 74 6f 70 61 64  |dr.... LDA topad|
00001e40  64 72 2b 31 0d 11 a8 0b  20 53 42 43 20 23 30 0d  |dr+1.... SBC #0.|
00001e50  11 b2 12 20 53 54 41 20  74 6f 70 61 64 64 72 2b  |... STA topaddr+|
00001e60  31 0d 11 bc 08 20 44 45  59 0d 11 c6 0d 20 42 4e  |1.... DEY.... BN|
00001e70  45 20 64 65 63 6c 0d 11  d0 09 2e 6e 64 65 63 0d  |E decl.....ndec.|
00001e80  11 da 0e 20 44 45 43 20  6e 63 6f 6c 73 0d 11 e4  |... DEC ncols...|
00001e90  0b 20 42 4e 45 20 6f 6b  0d 11 ee 12 20 4c 44 41  |. BNE ok.... LDA|
00001ea0  20 23 53 70 72 57 69 64  74 68 0d 11 f8 0e 20 53  | #SprWidth.... S|
00001eb0  54 41 20 6e 63 6f 6c 73  0d 12 02 07 2e 6f 6b 0d  |TA ncols.....ok.|
00001ec0  12 0c 0d 20 49 4e 43 20  6d 63 6f 6c 0d 12 16 0c  |... INC mcol....|
00001ed0  20 4c 44 41 20 26 37 30  0d 12 20 08 20 43 4c 43  | LDA &70.. . CLC|
00001ee0  0d 12 2a 12 20 41 44 43  20 23 4d 61 70 44 65 70  |..*. ADC #MapDep|
00001ef0  74 68 0d 12 34 0c 20 53  54 41 20 26 37 30 0d 12  |th..4. STA &70..|
00001f00  3e 0c 20 4c 44 41 20 26  37 31 0d 12 48 0b 20 41  |>. LDA &71..H. A|
00001f10  44 43 20 23 30 0d 12 52  0c 20 53 54 41 20 26 37  |DC #0..R. STA &7|
00001f20  31 0d 12 5c 23 20 4c 44  41 20 74 6f 70 61 64 64  |1..\# LDA topadd|
00001f30  72 20 20 20 20 20 20 20  20 20 5c 20 67 6f 20 6f  |r         \ go o|
00001f40  6e 20 74 6f 0d 12 66 23  20 43 4c 43 20 20 20 20  |n to..f# CLC    |
00001f50  20 20 20 20 20 20 20 20  20 20 20 20 20 5c 20 6e  |             \ n|
00001f60  65 78 74 20 6d 61 70 0d  12 70 1f 20 41 44 43 20  |ext map..p. ADC |
00001f70  23 49 6e 63 4e 63 20 83  20 32 35 36 20 20 5c 20  |#IncNc . 256  \ |
00001f80  63 6f 6c 75 6d 6e 0d 12  7a 0d 20 53 54 41 20 61  |column..z. STA a|
00001f90  64 64 72 0d 12 84 12 20  4c 44 41 20 74 6f 70 61  |ddr.... LDA topa|
00001fa0  64 64 72 2b 31 0d 12 8e  15 20 41 44 43 20 23 49  |ddr+1.... ADC #I|
00001fb0  6e 63 4e 63 20 81 20 32  35 36 0d 12 98 0f 20 53  |ncNc . 256.... S|
00001fc0  54 41 20 61 64 64 72 2b  31 0d 12 a2 0d 20 4c 44  |TA addr+1.... LD|
00001fd0  41 20 6d 63 6f 6c 0d 12  ac 12 20 43 4d 50 20 23  |A mcol.... CMP #|
00001fe0  4d 61 70 57 69 64 74 68  0d 12 b6 0c 20 42 45 51  |MapWidth.... BEQ|
00001ff0  20 6e 6d 6c 0d 12 c0 0b  20 4a 4d 50 20 6d 6c 0d  | nml.... JMP ml.|
00002000  12 ca 08 2e 6e 6d 6c 0d  12 d4 24 20 4c 44 41 20  |....nml...$ LDA |
00002010  63 6f 75 6e 74 65 72 20  20 20 20 5c 20 64 65 63  |counter    \ dec|
00002020  69 64 65 20 77 68 65 74  68 65 72 0d 12 de 25 20  |ide whether...% |
00002030  43 4d 50 20 23 34 20 20  20 20 20 20 20 20 20 5c  |CMP #4         \|
00002040  20 74 6f 20 67 6f 20 6f  6e 74 6f 20 6e 65 78 74  | to go onto next|
00002050  0d 12 e8 24 20 42 4e 45  20 6e 6f 74 63 34 20 20  |...$ BNE notc4  |
00002060  20 20 20 20 5c 20 63 6f  6c 75 6d 6e 20 6f 66 20  |    \ column of |
00002070  64 61 74 61 0d 12 f2 20  20 4c 44 41 20 6f 6c 64  |data...  LDA old|
00002080  37 30 20 20 20 20 20 20  5c 20 6f 72 20 74 6f 20  |70      \ or to |
00002090  6b 65 65 70 0d 12 fc 1f  20 43 4c 43 20 20 20 20  |keep.... CLC    |
000020a0  20 20 20 20 20 20 20 20  5c 20 73 63 72 6f 6c 6c  |        \ scroll|
000020b0  69 6e 67 0d 13 06 22 20  41 44 43 20 23 4d 61 70  |ing..." ADC #Map|
000020c0  44 65 70 74 68 20 20 5c  20 63 75 72 72 65 6e 74  |Depth  \ current|
000020d0  20 64 61 74 61 0d 13 10  0c 20 53 54 41 20 26 37  | data.... STA &7|
000020e0  30 0d 13 1a 10 20 4c 44  41 20 6f 6c 64 37 30 2b  |0.... LDA old70+|
000020f0  31 0d 13 24 0b 20 41 44  43 20 23 30 0d 13 2e 0c  |1..$. ADC #0....|
00002100  20 53 54 41 20 26 37 31  0d 13 38 0b 20 4c 44 41  | STA &71..8. LDA|
00002110  20 23 30 0d 13 42 10 20  53 54 41 20 63 6f 75 6e  | #0..B. STA coun|
00002120  74 65 72 0d 13 4c 12 20  4a 4d 50 20 6f 76 65 72  |ter..L. JMP over|
00002130  6e 6f 74 63 34 0d 13 56  0a 2e 6e 6f 74 63 34 0d  |notc4..V..notc4.|
00002140  13 60 0e 20 4c 44 41 20  6f 6c 64 37 30 0d 13 6a  |.`. LDA old70..j|
00002150  0c 20 53 54 41 20 26 37  30 0d 13 74 10 20 4c 44  |. STA &70..t. LD|
00002160  41 20 6f 6c 64 37 30 2b  31 0d 13 7e 0c 20 53 54  |A old70+1..~. ST|
00002170  41 20 26 37 31 0d 13 88  0e 2e 6f 76 65 72 6e 6f  |A &71.....overno|
00002180  74 63 34 0d 13 92 08 20  52 54 53 0d 13 9c 06 20  |tc4.... RTS.... |
00002190  3a 0d 13 a6 0c 2e 73 63  68 6f 6f 73 65 0d 13 b0  |:.....schoose...|
000021a0  0f 20 53 54 41 20 73 79  6d 62 6f 6c 0d 13 ba 0f  |. STA symbol....|
000021b0  20 53 54 59 20 79 73 74  6f 72 65 0d 13 c4 0b 20  | STY ystore.... |
000021c0  4c 44 59 20 23 30 0d 13  ce 0c 2e 73 65 61 72 63  |LDY #0.....searc|
000021d0  68 6c 0d 13 d8 12 20 4c  44 41 20 73 70 74 61 62  |hl.... LDA sptab|
000021e0  6c 65 2c 59 0d 13 e2 11  20 42 45 51 20 6e 6f 74  |le,Y.... BEQ not|
000021f0  66 6f 75 6e 64 0d 13 ec  0f 20 43 4d 50 20 73 79  |found.... CMP sy|
00002200  6d 62 6f 6c 0d 13 f6 10  20 42 45 51 20 66 6f 75  |mbol.... BEQ fou|
00002210  6e 64 69 74 0d 14 00 0c  20 49 4e 59 3a 49 4e 59  |ndit.... INY:INY|
00002220  0d 14 0a 08 20 49 4e 59  0d 14 14 10 20 4a 4d 50  |.... INY.... JMP|
00002230  20 73 65 61 72 63 68 6c  0d 14 1e 0c 2e 66 6f 75  | searchl.....fou|
00002240  6e 64 69 74 0d 14 28 14  20 4c 44 41 20 73 70 74  |ndit..(. LDA spt|
00002250  61 62 6c 65 2b 31 2c 59  0d 14 32 0d 20 53 54 41  |able+1,Y..2. STA|
00002260  20 64 61 74 61 0d 14 3c  14 20 4c 44 41 20 73 70  | data..<. LDA sp|
00002270  74 61 62 6c 65 2b 32 2c  59 0d 14 46 0f 20 53 54  |table+2,Y..F. ST|
00002280  41 20 64 61 74 61 2b 31  0d 14 50 0f 20 4c 44 59  |A data+1..P. LDY|
00002290  20 79 73 74 6f 72 65 0d  14 5a 08 20 52 54 53 0d  | ystore..Z. RTS.|
000022a0  14 64 0d 2e 6e 6f 74 66  6f 75 6e 64 0d 14 6e 12  |.d..notfound..n.|
000022b0  20 4c 44 41 20 73 70 74  61 62 6c 65 2b 31 0d 14  | LDA sptable+1..|
000022c0  78 0d 20 53 54 41 20 64  61 74 61 0d 14 82 12 20  |x. STA data.... |
000022d0  4c 44 41 20 73 70 74 61  62 6c 65 2b 32 0d 14 8c  |LDA sptable+2...|
000022e0  0f 20 53 54 41 20 64 61  74 61 2b 31 0d 14 96 0f  |. STA data+1....|
000022f0  20 4c 44 59 20 79 73 74  6f 72 65 0d 14 a0 08 20  | LDY ystore.... |
00002300  52 54 53 0d 14 aa 12 2e  63 6f 6c 73 20 20 20 20  |RTS.....cols    |
00002310  20 20 42 52 4b 0d 14 b4  16 2e 74 63 61 64 64 72  |  BRK.....tcaddr|
00002320  20 20 20 20 42 52 4b 3a  42 52 4b 0d 14 be 16 2e  |    BRK:BRK.....|
00002330  6d 61 70 74 6f 70 20 20  20 20 42 52 4b 3a 42 52  |maptop    BRK:BR|
00002340  4b 0d 14 c8 22 2e 6e 63  6f 6c 73 20 20 20 20 20  |K...".ncols     |
00002350  4f 50 54 20 a4 65 71 75  62 28 53 70 72 57 69 64  |OPT .equb(SprWid|
00002360  74 68 29 0d 14 d2 12 2e  79 73 74 6f 72 65 20 20  |th).....ystore  |
00002370  20 20 42 52 4b 0d 14 dc  12 2e 6d 63 6f 6c 20 20  |  BRK.....mcol  |
00002380  20 20 20 20 42 52 4b 0d  14 e6 12 2e 63 6f 75 6e  |    BRK.....coun|
00002390  74 65 72 20 20 20 42 52  4b 0d 14 f0 16 2e 6f 6c  |ter   BRK.....ol|
000023a0  64 37 30 20 20 20 20 20  42 52 4b 3a 42 52 4b 0d  |d70     BRK:BRK.|
000023b0  14 fa 12 2e 73 79 6d 62  6f 6c 20 20 20 20 42 52  |....symbol    BR|
000023c0  4b 0d 15 04 1b 2e 73 6e  20 20 20 20 20 20 20 20  |K.....sn        |
000023d0  4f 50 54 20 a4 65 71 75  62 28 31 29 0d 15 0e 12  |OPT .equb(1)....|
000023e0  2e 63 64 20 20 20 20 20  20 20 20 42 52 4b 0d 15  |.cd        BRK..|
000023f0  18 12 2e 64 65 61 74 68  66 6c 61 67 20 42 52 4b  |...deathflag BRK|
00002400  0d 15 22 14 2e 78 20 4f  50 54 20 a4 65 71 75 62  |.."..x OPT .equb|
00002410  28 31 30 29 0d 15 2c 14  2e 79 20 4f 50 54 20 a4  |(10)..,..y OPT .|
00002420  65 71 75 62 28 31 30 29  0d 15 36 0e 2e 61 20 42  |equb(10)..6..a B|
00002430  52 4b 3a 42 52 4b 0d 15  40 08 2e 6d 61 70 0d 15  |RK:BRK..@..map..|
00002440  4a 18 20 4f 50 54 20 a4  65 71 75 73 28 22 30 20  |J. OPT .equs("0 |
00002450  20 20 20 20 22 29 0d 15  54 18 20 4f 50 54 20 a4  |    ")..T. OPT .|
00002460  65 71 75 73 28 22 30 20  20 20 20 20 22 29 0d 15  |equs("0     ")..|
00002470  5e 18 20 4f 50 54 20 a4  65 71 75 73 28 22 30 20  |^. OPT .equs("0 |
00002480  20 20 20 20 22 29 0d 15  68 18 20 4f 50 54 20 a4  |    ")..h. OPT .|
00002490  65 71 75 73 28 22 30 20  20 20 20 20 22 29 0d 15  |equs("0     ")..|
000024a0  72 18 20 4f 50 54 20 a4  65 71 75 73 28 22 30 20  |r. OPT .equs("0 |
000024b0  20 20 20 20 22 29 0d 15  7c 18 20 4f 50 54 20 a4  |    ")..|. OPT .|
000024c0  65 71 75 73 28 22 30 20  20 20 20 20 22 29 0d 15  |equs("0     ")..|
000024d0  86 18 20 4f 50 54 20 a4  65 71 75 73 28 22 30 30  |.. OPT .equs("00|
000024e0  30 30 20 30 22 29 0d 15  90 18 20 4f 50 54 20 a4  |00 0").... OPT .|
000024f0  65 71 75 73 28 22 30 30  30 30 20 30 22 29 0d 15  |equs("0000 0")..|
00002500  9a 18 20 4f 50 54 20 a4  65 71 75 73 28 22 30 30  |.. OPT .equs("00|
00002510  30 30 20 30 22 29 0d 15  a4 18 20 4f 50 54 20 a4  |00 0").... OPT .|
00002520  65 71 75 73 28 22 30 30  30 30 20 30 22 29 0d 15  |equs("0000 0")..|
00002530  ae 18 20 4f 50 54 20 a4  65 71 75 73 28 22 30 30  |.. OPT .equs("00|
00002540  30 30 20 30 22 29 0d 15  b8 18 20 4f 50 54 20 a4  |00 0").... OPT .|
00002550  65 71 75 73 28 22 30 30  30 30 20 30 22 29 0d 15  |equs("0000 0")..|
00002560  c2 18 20 4f 50 54 20 a4  65 71 75 73 28 22 30 30  |.. OPT .equs("00|
00002570  30 20 20 30 22 29 0d 15  cc 18 20 4f 50 54 20 a4  |0  0").... OPT .|
00002580  65 71 75 73 28 22 30 20  20 20 20 30 22 29 0d 15  |equs("0    0")..|
00002590  d6 18 20 4f 50 54 20 a4  65 71 75 73 28 22 30 20  |.. OPT .equs("0 |
000025a0  20 30 30 30 22 29 0d 15  e0 18 20 4f 50 54 20 a4  | 000").... OPT .|
000025b0  65 71 75 73 28 22 30 20  30 20 20 20 22 29 0d 15  |equs("0 0   ")..|
000025c0  ea 18 20 4f 50 54 20 a4  65 71 75 73 28 22 30 20  |.. OPT .equs("0 |
000025d0  30 30 30 30 22 29 0d 15  f4 18 20 4f 50 54 20 a4  |0000").... OPT .|
000025e0  65 71 75 73 28 22 30 20  20 20 20 30 22 29 0d 15  |equs("0    0")..|
000025f0  fe 18 20 4f 50 54 20 a4  65 71 75 73 28 22 30 20  |.. OPT .equs("0 |
00002600  20 20 20 30 22 29 0d 16  08 18 20 4f 50 54 20 a4  |   0").... OPT .|
00002610  65 71 75 73 28 22 30 30  30 30 20 30 22 29 0d 16  |equs("0000 0")..|
00002620  12 18 20 4f 50 54 20 a4  65 71 75 73 28 22 30 30  |.. OPT .equs("00|
00002630  30 30 20 30 22 29 0d 16  1c 18 20 4f 50 54 20 a4  |00 0").... OPT .|
00002640  65 71 75 73 28 22 30 30  20 20 20 30 22 29 0d 16  |equs("00   0")..|
00002650  26 18 20 4f 50 54 20 a4  65 71 75 73 28 22 30 30  |&. OPT .equs("00|
00002660  20 20 30 30 22 29 0d 16  30 18 20 4f 50 54 20 a4  |  00")..0. OPT .|
00002670  65 71 75 73 28 22 30 20  20 30 30 30 22 29 0d 16  |equs("0  000")..|
00002680  3a 18 20 4f 50 54 20 a4  65 71 75 73 28 22 30 20  |:. OPT .equs("0 |
00002690  20 30 30 30 22 29 0d 16  44 18 20 4f 50 54 20 a4  | 000")..D. OPT .|
000026a0  65 71 75 73 28 22 30 30  20 20 30 30 22 29 0d 16  |equs("00  00")..|
000026b0  4e 18 20 4f 50 54 20 a4  65 71 75 73 28 22 30 30  |N. OPT .equs("00|
000026c0  20 20 20 30 22 29 0d 16  58 18 20 4f 50 54 20 a4  |   0")..X. OPT .|
000026d0  65 71 75 73 28 22 30 30  30 30 20 30 22 29 0d 16  |equs("0000 0")..|
000026e0  62 18 20 4f 50 54 20 a4  65 71 75 73 28 22 30 30  |b. OPT .equs("00|
000026f0  30 30 20 30 22 29 0d 16  6c 18 20 4f 50 54 20 a4  |00 0")..l. OPT .|
00002700  65 71 75 73 28 22 30 20  20 20 20 30 22 29 0d 16  |equs("0    0")..|
00002710  76 18 20 4f 50 54 20 a4  65 71 75 73 28 22 30 20  |v. OPT .equs("0 |
00002720  30 30 20 30 22 29 0d 16  80 18 20 4f 50 54 20 a4  |00 0").... OPT .|
00002730  65 71 75 73 28 22 30 20  30 30 20 30 22 29 0d 16  |equs("0 00 0")..|
00002740  8a 18 20 4f 50 54 20 a4  65 71 75 73 28 22 30 20  |.. OPT .equs("0 |
00002750  30 30 20 30 22 29 0d 16  94 18 20 4f 50 54 20 a4  |00 0").... OPT .|
00002760  65 71 75 73 28 22 30 20  30 30 20 30 22 29 0d 16  |equs("0 00 0")..|
00002770  9e 18 20 4f 50 54 20 a4  65 71 75 73 28 22 30 20  |.. OPT .equs("0 |
00002780  30 30 20 30 22 29 0d 16  a8 18 20 4f 50 54 20 a4  |00 0").... OPT .|
00002790  65 71 75 73 28 22 20 20  30 30 20 20 22 29 0d 16  |equs("  00  ")..|
000027a0  b2 18 20 4f 50 54 20 a4  65 71 75 73 28 22 20 20  |.. OPT .equs("  |
000027b0  30 30 20 20 22 29 0d 16  bc 18 20 4f 50 54 20 a4  |00  ").... OPT .|
000027c0  65 71 75 73 28 22 20 30  30 30 30 20 22 29 0d 16  |equs(" 0000 ")..|
000027d0  c6 18 20 4f 50 54 20 a4  65 71 75 73 28 22 20 20  |.. OPT .equs("  |
000027e0  20 20 20 20 22 29 0d 16  d0 18 20 4f 50 54 20 a4  |    ").... OPT .|
000027f0  65 71 75 73 28 22 30 30  20 20 30 30 22 29 0d 16  |equs("00  00")..|
00002800  da 18 20 4f 50 54 20 a4  65 71 75 73 28 22 30 30  |.. OPT .equs("00|
00002810  20 20 30 30 22 29 0d 16  e4 18 20 4f 50 54 20 a4  |  00").... OPT .|
00002820  65 71 75 73 28 22 20 20  20 20 20 20 22 29 0d 16  |equs("      ")..|
00002830  ee 18 20 4f 50 54 20 a4  65 71 75 73 28 22 20 20  |.. OPT .equs("  |
00002840  20 20 20 20 22 29 0d 16  f8 18 20 4f 50 54 20 a4  |    ").... OPT .|
00002850  65 71 75 73 28 22 20 20  20 20 20 20 22 29 0d 17  |equs("      ")..|
00002860  02 08 20 4e 4f 50 0d 17  0c 0c 2e 73 70 74 61 62  |.. NOP.....sptab|
00002870  6c 65 0d 17 16 13 20 4f  50 54 20 a4 65 71 75 73  |le.... OPT .equs|
00002880  28 22 20 22 29 0d 17 20  19 20 4f 50 54 20 a4 65  |(" ").. . OPT .e|
00002890  71 75 77 28 62 6c 61 6e  6b 64 61 74 61 29 0d 17  |quw(blankdata)..|
000028a0  2a 13 20 4f 50 54 20 a4  65 71 75 73 28 22 50 22  |*. OPT .equs("P"|
000028b0  29 0d 17 34 19 20 4f 50  54 20 a4 65 71 75 77 28  |)..4. OPT .equw(|
000028c0  62 6c 6f 63 6b 64 61 74  61 29 0d 17 3e 13 20 4f  |blockdata)..>. O|
000028d0  50 54 20 a4 65 71 75 73  28 22 30 22 29 0d 17 48  |PT .equs("0")..H|
000028e0  1e 20 4f 50 54 20 a4 65  71 75 77 28 62 6c 6f 63  |. OPT .equw(bloc|
000028f0  6b 64 61 74 61 2b 33 32  2a 34 29 0d 17 52 08 20  |kdata+32*4)..R. |
00002900  42 52 4b 0d 17 5c 0e 2e  62 6c 6f 63 6b 64 61 74  |BRK..\..blockdat|
00002910  61 0d 17 66 0f 20 4f 50  54 20 a4 73 64 61 74 61  |a..f. OPT .sdata|
00002920  0d 17 70 0e 2e 62 6c 61  6e 6b 64 61 74 61 0d 17  |..p..blankdata..|
00002930  7a 1b 20 4f 50 54 20 a4  65 71 75 73 28 c4 34 2a  |z. OPT .equs(.4*|
00002940  33 32 2c bd 28 30 29 29  29 0d 17 84 07 5d 3a ed  |32,.(0)))....]:.|
00002950  0d 17 8e 0c f2 65 78 65  63 75 74 65 0d 17 98 05  |.....execute....|
00002960  e0 0d 17 a2 05 3a 0d 17  ac 0b dd a4 73 64 61 74  |.....:......sdat|
00002970  61 0d 17 b6 05 f7 0d 17  c0 26 e3 20 49 25 3d 31  |a........&. I%=1|
00002980  20 b8 20 28 28 53 70 72  57 69 64 74 68 2a 53 70  | . ((SprWidth*Sp|
00002990  72 44 65 70 74 68 29 2f  34 29 2a 32 0d 17 ca 08  |rDepth)/4)*2....|
000029a0  f3 20 64 24 0d 17 d4 1f  5b 4f 50 54 20 50 3a 4f  |. d$....[OPT P:O|
000029b0  50 54 20 a4 65 71 75 64  28 a0 28 22 26 22 2b 64  |PT .equd(.("&"+d|
000029c0  24 29 29 0d 17 de 0a 5d  3a ed 3a 3d 50 0d 17 e8  |$))....]:.:=P...|
000029d0  05 3a 0d 17 f2 0c dd a4  78 79 64 61 74 61 0d 17  |.:......xydata..|
000029e0  fc 0a f7 20 8d 44 60 58  0d 18 06 11 e3 20 49 25  |... .D`X..... I%|
000029f0  3d 31 20 b8 20 36 34 2f  34 0d 18 10 08 f3 20 64  |=1 . 64/4..... d|
00002a00  24 0d 18 1a 21 5b 4f 50  54 20 50 3a 4f 50 54 20  |$...![OPT P:OPT |
00002a10  a4 65 71 75 64 28 a0 28  22 26 22 2b 64 24 29 29  |.equd(.("&"+d$))|
00002a20  3a 5d 0d 18 24 08 ed 3a  3d 50 0d 18 2e 05 3a 0d  |:]..$..:=P....:.|
00002a30  18 38 7e dc 20 30 2c 45  30 43 30 43 30 38 2c 46  |.8~. 0,E0C0C08,F|
00002a40  30 46 30 46 30 45 2c 31  30 31 30 30 32 30 36 2c  |0F0F0E,10100206,|
00002a50  33 30 33 30 2c 30 2c 30  2c 30 2c 30 2c 30 2c 46  |3030,0,0,0,0,0,F|
00002a60  30 46 30 30 2c 43 30 45  30 46 30 46 30 2c 38 30  |0F00,C0E0F0F0,80|
00002a70  2c 30 2c 30 2c 30 2c 30  2c 45 30 36 30 30 30 30  |,0,0,0,0,E060000|
00002a80  30 2c 37 30 45 30 46 30  30 2c 33 38 33 2c 30 2c  |0,70E0F00,383,0,|
00002a90  30 2c 30 2c 30 2c 30 2c  30 2c 33 30 36 30 43 30  |0,0,0,0,0,3060C0|
00002aa0  30 2c 46 30 46 2c 30 2c  30 2c 30 2c 30 0d 18 42  |0,F0F,0,0,0,0..B|
00002ab0  e3 dc 20 33 43 37 46 37  46 46 46 2c 32 43 33 43  |.. 3C7F7FFF,2C3C|
00002ac0  31 43 32 43 2c 31 43 32  43 33 43 31 43 2c 33 43  |1C2C,1C2C3C1C,3C|
00002ad0  31 43 32 43 33 43 2c 32  43 33 43 31 43 32 43 2c  |1C2C3C,2C3C1C2C,|
00002ae0  31 43 32 43 33 43 31 43  2c 33 43 31 43 32 43 33  |1C2C3C1C,3C1C2C3|
00002af0  43 2c 46 30 46 30 46 32  43 2c 36 30 46 46 46 46  |C,F0F0F2C,60FFFF|
00002b00  46 46 2c 44 30 36 30 42  30 44 30 2c 42 30 44 30  |FF,D060B0D0,B0D0|
00002b10  36 30 42 30 2c 36 30 42  30 44 30 36 30 2c 44 30  |60B0,60B0D060,D0|
00002b20  36 30 42 30 44 30 2c 42  30 44 30 36 30 42 30 2c  |60B0D0,B0D060B0,|
00002b30  36 30 42 30 44 30 36 30  2c 46 30 46 30 46 44 30  |60B0D060,F0F0FD0|
00002b40  2c 44 30 46 46 46 46 46  46 2c 42 30 44 30 36 30  |,D0FFFFFF,B0D060|
00002b50  42 30 2c 36 30 42 30 44  30 36 30 2c 44 30 36 30  |B0,60B0D060,D060|
00002b60  42 30 44 30 2c 42 30 44  30 36 30 42 30 2c 36 30  |B0D0,B0D060B0,60|
00002b70  42 30 44 30 36 30 2c 44  30 36 30 42 30 44 30 2c  |B0D060,D060B0D0,|
00002b80  46 30 46 30 46 42 30 2c  42 33 46 46 46 46 46 46  |F0F0FB0,B3FFFFFF|
00002b90  0d 18 4c 43 dc 37 33 42  33 46 33 37 33 2c 46 33  |..LC.73B3F373,F3|
00002ba0  37 33 42 33 46 33 2c 42  33 46 33 37 33 42 33 2c  |73B3F3,B3F373B3,|
00002bb0  37 33 42 33 46 33 37 33  2c 46 33 37 33 42 33 46  |73B3F373,F373B3F|
00002bc0  33 2c 42 33 46 33 37 33  42 33 2c 31 46 31 46 33  |3,B3F373B3,1F1F3|
00002bd0  46 37 33 0d 18 56 05 3a  0d 18 60 95 dc 20 43 30  |F73..V.:..`.. C0|
00002be0  38 30 34 30 30 30 2c 43  30 38 30 34 30 30 30 2c  |804000,C0804000,|
00002bf0  43 30 38 30 34 30 30 30  2c 43 30 38 30 34 30 30  |C0804000,C080400|
00002c00  30 2c 43 30 38 30 34 30  30 30 2c 43 30 38 30 34  |0,C0804000,C0804|
00002c10  30 30 30 2c 43 30 38 30  34 30 30 30 2c 43 30 38  |000,C0804000,C08|
00002c20  30 34 30 30 30 2c 35 42  35 41 35 39 35 38 2c 36  |04000,5B5A5958,6|
00002c30  30 35 46 35 45 35 44 2c  36 35 36 34 36 33 36 32  |05F5E5D,65646362|
00002c40  2c 36 41 36 39 36 38 36  37 2c 36 46 36 45 36 44  |,6A696867,6F6E6D|
00002c50  36 43 2c 37 34 37 33 37  32 37 31 2c 37 39 37 38  |6C,74737271,7978|
00002c60  37 37 37 36 2c 37 45 37  44 37 43 37 42 0d 18 6a  |7776,7E7D7C7B..j|
00002c70  05 3a 0d 18 74 21 dd a4  65 71 75 73 28 73 24 29  |.:..t!..equs(s$)|
00002c80  24 50 25 3d 73 24 3a 50  25 3d 50 25 2b a9 73 24  |$P%=s$:P%=P%+.s$|
00002c90  3a 3d 50 0d 18 7e 1f dd  a4 65 71 75 62 28 42 25  |:=P..~...equb(B%|
00002ca0  29 3f 50 25 3d 42 25 3a  50 25 3d 50 25 2b 31 3a  |)?P%=B%:P%=P%+1:|
00002cb0  3d 50 0d 18 88 1f dd a4  65 71 75 77 28 57 25 29  |=P......equw(W%)|
00002cc0  21 50 25 3d 57 25 3a 50  25 3d 50 25 2b 32 3a 3d  |!P%=W%:P%=P%+2:=|
00002cd0  50 0d 18 92 1f dd a4 65  71 75 64 28 44 25 29 21  |P......equd(D%)!|
00002ce0  50 25 3d 44 25 3a 50 25  3d 50 25 2b 34 3a 3d 50  |P%=D%:P%=P%+4:=P|
00002cf0  0d 18 9c 05 3a 0d 18 a6  0d dd f2 65 78 65 63 75  |....:......execu|
00002d00  74 65 0d 18 b0 1a 73 24  3d 22 43 41 4c 4c 20 73  |te....s$="CALL s|
00002d10  63 72 6f 6c 6c 22 2b bd  28 31 33 29 0d 18 ba 11  |croll"+.(13)....|
00002d20  e3 20 4c 3d 31 20 b8 20  a9 28 73 24 29 0d 18 c4  |. L=1 . .(s$)...|
00002d30  13 58 25 3d 30 3a 59 25  3d 97 c1 73 24 2c 4c 29  |.X%=0:Y%=..s$,L)|
00002d40  0d 18 ce 13 41 25 3d 31  33 38 3a d6 20 6f 73 62  |....A%=138:. osb|
00002d50  79 74 65 0d 18 d8 07 ed  3a e1 0d ff              |yte.....:...|
00002d5c
ScrSoft.m0
ScrSoft.m1
ScrSoft.m2
ScrSoft.m4
ScrSoft.m5