C64 Software  <  SCA: The C64 Software Collection / SPRITESCROLL

  Run
1000              ;
1010              ;BREITSCROLL 1
1020              ;21.6.86   STI
1030              ;
1040 C            EQU 3    ;SPRITEFARBE
1050 EY           EQU 0    ;EXPAND Y
1060 ROW          EQU 250
1070 CNTR         EQU 251
1080 TEXT         EQU 252
1090 PTR1         EQU 254
1100              ;
1110 SPRITEPTR    EQU 2040
1120 SPRITENR     EQU 128
1130 SPRITES      EQU 8192
1140 LASTSPRITE   EQU SPRITES+384+12
1150 V            EQU 53248
1160 REG          EQU 53270
1170              ;
1180              ORG 20000
1190              ;
1200              ;
1210 INT          SEI
1220              LDA #<ISR
1230              STA 788
1240              LDA #>ISR
1250              STA 789
1260              LDA #127
1270              STA 56333
1280              ;
1290              LDX #46
1300 INIT1        LDA VICTAB,X
1310              STA V,X
1320              DEX
1330              BPL INIT1
1340              ;
1350              LDX #7
1360              STX CNTR
1370              LDA #SPRITENR+6
1380 INIT2        STA SPRITEPTR-1,X
1390              SEC
1400              SBC #1
1410              DEX
1420              BNE INIT2
1430              ;
1440              TXA
1450 INIT3        STA SPRITES,X
1460              STA SPRITES+256,X
1470              STA SPRITES+512,X
1480              INX
1490              BNE INIT3
1500              ;
1510              LDA #<TEXTTAB
1520              STA TEXT
1530              LDA #>TEXTTAB
1540              STA TEXT+1
1550              ;
1560              CLI
1570              RTS
1580              ;
1590              ;
1600              ;
1610 ISR          LDA #1
1620              STA 53273
1630              LDA #19
1640              STA 53265
1650              ;
1660              JSR SCLOLL
1670              LDA #27
1680              STA 53265
1690              ;
1700              LDA Y
1710              STA V+1
1720              STA V+3
1730              STA V+5
1740              STA V+7
1750              STA V+9
1760              STA V+11
1770              STA V+13
1780              JMP 59953
1790              PLA
1800              TAY
1810              PLA
1820              TAX
1830              PLA
1840              RTI
1850              ;
1860 SCLOLL       LDA #27
1870 SCLOLL1      STA ROW
1880              CLC
1890              ADC #<LASTSPRITE
1900              STA MODIF+1
1910              LDA #>LASTSPRITE
1920              STA MODIF+2
1930              ;
1940              LDY #7
1950 SCLOLL2      LDX #2
1960 MODIF        ROL 65530,X
1970              DEX
1980              BPL MODIF
1990              ;
2000              PHP
2010              LDA MODIF+1
2020              SEC
2030              SBC #64
2040              STA MODIF+1
2050              BCS SCLOLL3
2060              DEC MODIF+2
2070 SCLOLL3      PLP
2080              DEY
2090              BNE SCLOLL2
2100              ;
2110              LDA ROW
2120              SEC
2130              SBC #3
2140              BPL SCLOLL1
2150              ;
2160              DEC CNTR
2170              LDA CNTR
2180              BNE SCLOLLAUS
2190              LDA #8
2200              STA CNTR
2210              LDA #27    ;$D8/8
2220              STA PTR1+1
2230              ;
2240              LDY #0
2250 SCLOLL4      LDA (TEXT),Y
2260              BNE SCLOLL5
2270              ;
2280              LDA #<TEXTTAB
2290              STA TEXT
2300              LDA #>TEXTTAB
2310              STA TEXT+1
2320              BNE SCLOLL4
2330              ;
2340 SCLOLL5      INC TEXT
2350              BNE SCLOLL6
2360              INC TEXT+1
2370              ;
2380 SCLOLL6      ASL
2390              ROL PTR1+1
2400              ASL
2410              ROL PTR1+1
2420              ASL
2430              ROL PTR1+1
2440              STA PTR1
2450              LDA #51
2460              STA 1
2470              LDX #0
2480              LDY #0
2490 SCLOLL7      LDA (PTR1),Y
2500              STA LASTSPRITE+2,X
2510              INX
2520              INX
2530              INX
2540              INY
2550              CPY #7
2560              BCC SCLOLL7
2570              LDA #55
2580              STA 1
2590              ;
2600              ;
2610 SCLOLLAUS    RTS
2620              ;
2630              ;
2640              ;
2650 VICTAB       DFB 20,0,68,0,116,0,164,0,212,0,4,0,52,0,0,0,%01100000
2660              DFB 27,249,0,0,127,8,EY,21,1,129,0,0,255,0,0
2670              DFB 0,0,0,0,0,0,0,C,C,C,C,C,C,C,C
2680              ;
2690 Y            DFB 100
2700              ;
2710 TEXTTAB      DFB ""
2720              DFB ""
2730              DFB ""
2740              DFB "",0
READY.