mirror of
https://github.com/antoinevignau/source.git
synced 2024-12-29 11:30:55 +00:00
4d4fb6a665
Some old (WIP) disassemblies and my own source code now available online.
731 lines
16 KiB
Plaintext
731 lines
16 KiB
Plaintext
0010 .LI OFF
|
|
0020 TEMP1 .EQ $F0
|
|
0030 TEMP2 .EQ $F1
|
|
0040 TEMP3 .EQ $F2
|
|
0050 TEMP4 .EQ $FF
|
|
0060 SCRPNT1 .EQ $F5
|
|
0070 SCRPNT2 .EQ $F7
|
|
0080 POINTER1 .EQ $F9
|
|
0090 POINTER2 .EQ $FB
|
|
0100 POINTER3 .EQ $FD
|
|
0110 POINTER4 .EQ $EE
|
|
0120 POINTER5 .EQ $7D
|
|
0130 HEIGHT .EQ $ED
|
|
0140 PATINDEX .EQ $EC
|
|
0150 AAMSBYT .EQ $10C0
|
|
0160 AALSBYT .EQ $10E0
|
|
0170 ANTBYT1 .EQ $1000
|
|
0180 ANTBYT2 .EQ $1020
|
|
0190 ANTBYT3 .EQ $1040
|
|
0200 ANTBYT4 .EQ $1060
|
|
0210 ANTXOLD .EQ $D5
|
|
0220 ANTYOLD .EQ $D4
|
|
0230 ANTXXOLD .EQ $D3
|
|
0240 ANTX .EQ $DC
|
|
0250 ANTY .EQ $DB
|
|
0260 ANTXX .EQ $DA
|
|
0270 ANTNUM .EQ $D8
|
|
0280 DESTBYT1 .EQ $1080
|
|
0290 DESTBYT2 .EQ $10A0
|
|
0300 K8 .EQ $AF
|
|
0310 INIT.K8 .EQ $AE
|
|
0320 FOODNUM .EQ $AD
|
|
0330 FOODX .EQ $AC
|
|
0340 FOODY .EQ $AB
|
|
0350 FOODBYT1 .EQ $65D0
|
|
0360 FOODBYT2 .EQ $65D8
|
|
0370 FOODBYT3 .EQ $65E0
|
|
0380 FOOD.HEIGHT .EQ $A8
|
|
0390 ANTHOLD .EQ $65E8
|
|
0400 BYTE3 .EQ $AA
|
|
0410 WIDTH .EQ $A9
|
|
0420 SWAT .EQ $C5
|
|
0430 MANDIR .EQ $C8
|
|
0440 GRAB.FOOD .EQ $B7
|
|
0450 BYFOOD .EQ $B6
|
|
0460 MANSTATE .EQ $C7
|
|
0470 MANXX .EQ $CA
|
|
0480 MANY .EQ $C9
|
|
0490 SPIDERBYT4 .EQ $4118
|
|
0500 ANTPOSITIONS .EQ $65F0
|
|
0510 ANTPOS .EQ $A7
|
|
0520 ORIENT .EQ $A6
|
|
0530 ANT.ORIENTATIONS .EQ $65F8
|
|
0540 STING.MAN.Z .EQ $600F
|
|
0550 ERASE.ANT.Z .EQ $170F
|
|
0560 PLOT.ANT3.Z .EQ $1703
|
|
0570 PLOT.FOOD2.Z .EQ $6962
|
|
0580 UPDATE.HORIZ.DESTBYTS2.Z .EQ $6956
|
|
0590 UPDATE.VERT.DESTBYTS2.Z .EQ $7066
|
|
0600 VACATE.ANTS.BLOCKS.Z .EQ $4F06
|
|
0610 ERASE.WEB.Z .EQ $600C
|
|
0620 SCORE.Z .EQ $4F09
|
|
0630 SWAT.ANT.SOUND.Z .EQ $4F0F
|
|
0640 SWAT.SPIDER.SOUND.Z .EQ $4F12
|
|
0650 .OR $7340
|
|
0660 .TA $1340
|
|
0670 JMP CARRY.FOOD
|
|
0680 CARRY.FOOD
|
|
0690 AND #$07
|
|
0700 TAX
|
|
0710 STA TEMP4
|
|
0720 LDA #$00
|
|
0730 STA SWAT
|
|
0740 LDA MANDIR
|
|
0750 CMP TABLE150A,X
|
|
0760 BEQ .1
|
|
0770 CMP TABLE150B,X
|
|
0780 BEQ .9
|
|
0790 CMP TABLE150C,X
|
|
0800 BEQ .9
|
|
0810 LDA #$00
|
|
0820 STA GRAB.FOOD
|
|
0830 STA BYFOOD
|
|
0840 .9 RTS
|
|
0850 .1 LDA TABLE151,X
|
|
0860 BPL .2
|
|
0870 CMP #$80
|
|
0880 BEQ .3
|
|
0890 LDA FOODBYT1,X
|
|
0900 CMP TABLE171,X
|
|
0910 BCC .9
|
|
0920 LDA MANSTATE
|
|
0930 CMP #$06
|
|
0940 BNE .4
|
|
0950 LDA #$04
|
|
0960 STA MANSTATE
|
|
0970 .4 LDA MANXX
|
|
0980 CMP #$02
|
|
0990 BEQ .5
|
|
1000 CMP #$05
|
|
1010 BEQ .5
|
|
1020 .8 RTS
|
|
1030 .2 JMP CARRY.VERT
|
|
1040 .3 LDA FOODBYT1,X
|
|
1050 CMP TABLE171,X
|
|
1060 BCS .9
|
|
1070 LDA MANSTATE
|
|
1080 CMP #$05
|
|
1090 BNE .4
|
|
1100 LDA #$02
|
|
1110 STA MANSTATE
|
|
1120 BNE .4
|
|
1130 .5 LDA TABLE152,X
|
|
1140 .7 STA HEIGHT
|
|
1150 LDA FOODBYT1,X
|
|
1160 STA FOODX
|
|
1170 CLC
|
|
1180 ADC TABLE155,X
|
|
1190 TAY
|
|
1200 LDA FOODBYT2,X
|
|
1210 STA FOODY
|
|
1220 TAX
|
|
1230 JSR CHECK.VERT.BLOCKS
|
|
1240 BNE .8
|
|
1250 LDX TEMP4
|
|
1260 LDA FOODX
|
|
1270 CMP TABLE156,X
|
|
1280 BEQ .6
|
|
1290 CLC
|
|
1300 ADC TABLE157,X
|
|
1310 STA FOODBYT1,X
|
|
1320 STA FOODX
|
|
1330 CLC
|
|
1340 ADC TABLE153,X
|
|
1350 TAY
|
|
1360 LDX TEMP4
|
|
1370 LDA TABLE152,X
|
|
1380 STA HEIGHT
|
|
1390 LDX FOODY
|
|
1400 JSR VACATE.COLUMN
|
|
1410 LDX TEMP4
|
|
1420 LDA FOODX
|
|
1430 CLC
|
|
1440 ADC TABLE153,X
|
|
1450 STA TEMP2
|
|
1460 LDA TABLE154,X
|
|
1470 STA HEIGHT
|
|
1480 LDA FOODY
|
|
1490 JSR ERASE.VERT.BLOCKS
|
|
1500 LDX TEMP4
|
|
1510 TXA
|
|
1520 ORA #$10
|
|
1530 STA TEMP4
|
|
1540 LDA TABLE152,X
|
|
1550 STA FOOD.HEIGHT
|
|
1560 LDA #$01
|
|
1570 STA WIDTH
|
|
1580 LDA FOODX
|
|
1590 PHA
|
|
1600 CLC
|
|
1610 ADC TABLE161,X
|
|
1620 STA FOODX
|
|
1630 JSR CHECK.ROWS
|
|
1640 PLA
|
|
1650 STA FOODX
|
|
1660 JSR PLOT.FOOD2.Z
|
|
1670 LDA FOODX
|
|
1680 ROR
|
|
1690 BCS .10
|
|
1700 LDA #$03
|
|
1710 .12 STA ANTPOS
|
|
1720 STA ANTPOSITIONS,X
|
|
1730 LDA TABLE167,X
|
|
1740 JMP UPDATE.HORIZ.DESTBYTS2.Z
|
|
1750 .10 LDA #$07
|
|
1760 BNE .12
|
|
1770 .6 TAY
|
|
1780 LDX TEMP4
|
|
1790 LDA TABLE152,X
|
|
1800 STA HEIGHT
|
|
1810 STA TEMP1
|
|
1820 LDX FOODY
|
|
1830 JSR VACATE.COLUMN
|
|
1840 INY
|
|
1850 LDX FOODY
|
|
1860 LDA TEMP1
|
|
1870 STA HEIGHT
|
|
1880 JSR VACATE.COLUMN
|
|
1890 LDA TEMP4
|
|
1900 EXT2
|
|
1910 BEQ .7
|
|
1920 CMP #$07
|
|
1930 BEQ .7
|
|
1940 INY
|
|
1950 LDX FOODY
|
|
1960 LDA #$03
|
|
1970 STA HEIGHT
|
|
1980 JSR VACATE.COLUMN
|
|
1990 .7 LDX TEMP4
|
|
2000 LDA TABLE154,X
|
|
2010 STA HEIGHT
|
|
2020 PHA
|
|
2030 LDA FOODX
|
|
2040 STA TEMP2
|
|
2050 LDA FOODY
|
|
2060 JSR ERASE.VERT.BLOCKS
|
|
2070 PLA
|
|
2080 STA HEIGHT
|
|
2090 PHA
|
|
2100 INC TEMP2
|
|
2110 LDA FOODY
|
|
2120 JSR ERASE.VERT.BLOCKS
|
|
2130 PLA
|
|
2140 LDX TEMP4
|
|
2150 BEQ .8
|
|
2160 CPX #$07
|
|
2170 BEQ .8
|
|
2180 STA HEIGHT
|
|
2190 INC TEMP2
|
|
2200 LDA FOODY
|
|
2210 JSR ERASE.VERT.BLOCKS
|
|
2220 .8 LDA TABLE158,X
|
|
2230 STA FOODX
|
|
2240 STA FOODBYT1,X
|
|
2250 TXA
|
|
2260 ORA #$50
|
|
2270 STA TEMP4
|
|
2280 LDA TABLE160,X
|
|
2290 STA WIDTH
|
|
2300 LDA TABLE152,X
|
|
2310 STA FOOD.HEIGHT
|
|
2320 JSR CHECK.ROWS
|
|
2330 JSR PLOT.FOOD2.Z
|
|
2340 LDX TEMP4
|
|
2350 LDA #$81
|
|
2360 STA FOODBYT3,X
|
|
2370 LDA TABLE152,X
|
|
2380 STA HEIGHT
|
|
2390 LDY TABLE164,X
|
|
2400 .13 LDA TABLE165,Y
|
|
2410 STA DESTBYT1,Y
|
|
2420 LDA TABLE166,Y
|
|
2430 STA DESTBYT2,Y
|
|
2440 INY
|
|
2450 DEC HEIGHT
|
|
2460 BNE .13
|
|
2470 LDA #$00
|
|
2480 STA GRAB.FOOD
|
|
2490 STA BYFOOD
|
|
2500 CPX #$03
|
|
2510 BNE .14
|
|
2520 STA ANTPOSITIONS,X
|
|
2530 RTS
|
|
2540 .14 LDA #$04
|
|
2550 STA ANTPOSITIONS,X
|
|
2560 RTS
|
|
2570 CHECK.ONE.ROW
|
|
2580 LDX FOODY
|
|
2590 LDY FOODX
|
|
2600 LDA AAMSBYT,X
|
|
2610 STA POINTER5+1
|
|
2620 LDA AALSBYT,X
|
|
2630 STA POINTER5
|
|
2640 LDA (POINTER5),Y
|
|
2650 AND #$3F
|
|
2660 STA TEMP3
|
|
2670 CMP #$20
|
|
2680 BCS .1
|
|
2690 CMP #$08
|
|
2700 BCS .2
|
|
2710 .3 LDA TEMP4
|
|
2720 LDY FOODX
|
|
2730 STA (POINTER5),Y
|
|
2740 INC FOODX
|
|
2750 DEC WIDTH
|
|
2760 BNE CHECK.ONE.ROW
|
|
2770 INC FOODY
|
|
2780 RTS
|
|
2790 .1 LDA #$01
|
|
2800 JSR SCORE.Z
|
|
2810 JSR SWAT.ANT.SOUND.Z
|
|
2820 LDA TEMP3
|
|
2830 AND #$1F
|
|
2840 PHA
|
|
2850 TAY
|
|
2860 LDA ANTBYT1,Y
|
|
2870 AND #$3F
|
|
2880 STA ANTX
|
|
2890 STA ANTXOLD
|
|
2900 LDA ANTBYT2,Y
|
|
2910 STA ANTY
|
|
2920 STA ANTYOLD
|
|
2930 LDA ANTBYT3,Y
|
|
2940 STA ANTXX
|
|
2950 STA ANTXXOLD
|
|
2960 JSR ERASE.ANT.Z
|
|
2970 JSR VACATE.ANTS.BLOCKS.Z
|
|
2980 PLA
|
|
2990 TAY
|
|
3000 LDA #$00
|
|
3010 STA ANTBYT1,Y
|
|
3020 BEQ .3
|
|
3030 .2 LDA #$02
|
|
3040 JSR SCORE.Z
|
|
3050 JSR SWAT.SPIDER.SOUND.Z
|
|
3060 LDA TEMP3
|
|
3070 AND #$07
|
|
3080 PHA
|
|
3090 JSR ERASE.WEB.Z
|
|
3100 PLA
|
|
3110 TAY
|
|
3120 LDA #$00
|
|
3130 STA SPIDERBYT4,Y
|
|
3140 BEQ .3
|
|
3150 CHECK.VERT.BLOCKS
|
|
3160 STY TEMP3
|
|
3170 .2 LDY TEMP3
|
|
3180 LDA AAMSBYT,X
|
|
3190 STA POINTER1+1
|
|
3200 LDA AALSBYT,X
|
|
3210 STA POINTER1
|
|
3220 LDA (POINTER1),Y
|
|
3230 AND #$3F
|
|
3240 BNE .1
|
|
3250 .3 INX
|
|
3260 DEC HEIGHT
|
|
3270 BNE .2
|
|
3280 RTS
|
|
3290 .1 CMP #$01
|
|
3300 BEQ NOT.LEGAL
|
|
3310 CMP #$20
|
|
3320 BCC .3
|
|
3330 AND #$1F
|
|
3340 TAY
|
|
3350 LDA ANTBYT4,Y
|
|
3360 BPL .3
|
|
3370 RTS
|
|
3380 CHECK.HORIZ.BLOCKS
|
|
3390 STX TEMP3
|
|
3400 .2 LDX TEMP3
|
|
3410 LDA AAMSBYT,X
|
|
3420 STA POINTER1+1
|
|
3430 LDA AALSBYT,X
|
|
3440 STA POINTER1
|
|
3450 LDA (POINTER1),Y
|
|
3460 AND #$3F
|
|
3470 BNE .1
|
|
3480 .3 INY
|
|
3490 DEC WIDTH
|
|
3500 BNE .2
|
|
3510 RTS
|
|
3520 .1 CMP #$01
|
|
3530 BEQ NOT.LEGAL
|
|
3540 CMP #$20
|
|
3550 BCC .3
|
|
3560 AND #$1F
|
|
3570 TAX
|
|
3580 LDA ANTBYT4,X
|
|
3590 BPL .3
|
|
3600 RTS
|
|
3610 NOT.LEGAL
|
|
3620 LDA #$FF
|
|
3630 RTS
|
|
3640 VACATE.COLUMN
|
|
3650 .1 LDA AAMSBYT,X
|
|
3660 STA POINTER1+1
|
|
3670 LDA AALSBYT,X
|
|
3680 STA POINTER1
|
|
3690 LDA (POINTER1),Y
|
|
3700 AND #$C0
|
|
3710 STA (POINTER1),Y
|
|
3720 INX
|
|
3730 DEC HEIGHT
|
|
3740 BNE .1
|
|
3750 RTS
|
|
3760 SET.COLUMN
|
|
3770 LDA TEMP4
|
|
3780 ORA #$10
|
|
3790 STA TEMP1
|
|
3800 .1 LDA AAMSBYT,X
|
|
3810 STA POINTER1+1
|
|
3820 LDA AALSBYT,X
|
|
3830 STA POINTER1
|
|
3840 LDA (POINTER1),Y
|
|
3850 AND #$C0
|
|
3860 ORA TEMP1
|
|
3870 STA (POINTER1),Y
|
|
3880 INX
|
|
3890 DEC HEIGHT
|
|
3900 BNE .1
|
|
3910 RTS
|
|
3920 ERASE.VERT.BLOCKS
|
|
3930 LDY TEMP2
|
|
3940 CPY #$2C
|
|
3950 BCS .1
|
|
3960 CPY #$04
|
|
3970 BCC .1
|
|
3980 ASL
|
|
3990 ASL
|
|
4000 ASL
|
|
4010 STA TEMP3
|
|
4020 TYA
|
|
4030 LSR
|
|
4040 BCS .2
|
|
4050 LDA #$AA
|
|
4060 BNE .3
|
|
4070 .2 LDA #$D5
|
|
4080 .3 CPY #$05
|
|
4090 BCC .4
|
|
4100 CPY #$2B
|
|
4110 BEQ .4
|
|
4120 CPY #$0B
|
|
4130 BCC .5
|
|
4140 CPY #$25
|
|
4150 BCC .4
|
|
4160 .5 AND #$7F
|
|
4170 .4 STA TEMP1
|
|
4180 .6 LDY TEMP3
|
|
4190 LDA (SCRPNT1),Y
|
|
4200 STA POINTER1+1
|
|
4210 CLC
|
|
4220 ADC #$60
|
|
4230 STA POINTER4+1
|
|
4240 LDA (SCRPNT2),Y
|
|
4250 STA POINTER1
|
|
4260 STA POINTER4
|
|
4270 LDY TEMP2
|
|
4280 LDA TEMP1
|
|
4290 STA (POINTER1),Y
|
|
4300 STA (POINTER4),Y
|
|
4310 INC TEMP3
|
|
4320 DEC HEIGHT
|
|
4330 BNE .6
|
|
4340 .1 RTS
|
|
4350 TABLE150A .HS D0CCCCC9D0B9B9C9
|
|
4360 TABLE150B .HS B0BBBBCBB0B0B0CB
|
|
4370 TABLE150C .HS BBCBCBB8BBB8B8B8
|
|
4380 TABLE151 .HS 8000009080010190
|
|
4390 TABLE152 .HS 0404030303030404
|
|
4400 TABLE153 .HS FFFFFF03FF020202
|
|
4410 TABLE154 .HS 2010101818101020
|
|
4420 TABLE155 .HS 020202FF03FFFFFF
|
|
4430 TABLE156 .HS 0905052508161625
|
|
4440 TABLE157 .HS 010101FF01FFFFFF
|
|
4450 TABLE158 .HS 0C0808210C131322
|
|
4460 TABLE159 .HS 0000000300000002
|
|
4470 TABLE160 .HS 0204030303030402
|
|
4480 TABLE161 .HS 0101010002000000
|
|
4490 TABLE164 .HS 0004080B0E111418
|
|
4500 TABLE165 .HS 8E8E8E8E919293949B9C9DA0A0A08F8F8F9293949B9C9D9EA1A1A1A1
|
|
4510 TABLE166 .HS 444C545C505450545054504C545C88909894909490949094889098A0
|
|
4520 TABLE167 .HS 010808FF01F8F8FF
|
|
4530 TABLE171 .HS 0A06062509161625
|
|
4540 VACATE.ROW
|
|
4550 .1 LDA AAMSBYT,X
|
|
4560 STA POINTER1+1
|
|
4570 LDA AALSBYT,X
|
|
4580 STA POINTER1
|
|
4590 LDA (POINTER1),Y
|
|
4600 AND #$C0
|
|
4610 STA (POINTER1),Y
|
|
4620 INY
|
|
4630 DEC WIDTH
|
|
4640 BNE .1
|
|
4650 RTS
|
|
4660 SET.ROW
|
|
4670 LDA TEMP4
|
|
4680 ORA #$10
|
|
4690 STA TEMP1
|
|
4700 .1 LDA AAMSBYT,X
|
|
4710 STA POINTER1+1
|
|
4720 LDA AALSBYT,X
|
|
4730 STA POINTER1
|
|
4740 LDA (POINTER1),Y
|
|
4750 AND #$C0
|
|
4760 ORA TEMP1
|
|
4770 STA (POINTER1),Y
|
|
4780 INY
|
|
4790 DEC WIDTH
|
|
4800 BNE .1
|
|
4810 RTS
|
|
4820 ERASE.HORIZ.BLOCKS
|
|
4830 TAY
|
|
4840 ASL
|
|
4850 ASL
|
|
4860 ASL
|
|
4870 STA TEMP3
|
|
4880 LDA FOODX
|
|
4890 LSR
|
|
4900 BCS .2
|
|
4910 LDA #$AA
|
|
4920 BNE .3
|
|
4930 .2 LDA #$D5
|
|
4940 .3 CPY #$04
|
|
4950 BCC .4
|
|
4960 CPY #$19
|
|
4970 BCS .4
|
|
4980 CPY #$07
|
|
4990 BCC .5
|
|
5000 CPY #$16
|
|
5010 BCC .4
|
|
5020 .5 AND #$7F
|
|
5030 .4 STA TEMP1
|
|
5040 LDA #$08
|
|
5050 STA HEIGHT
|
|
5060 .1 LDY TEMP3
|
|
5070 LDA (SCRPNT1),Y
|
|
5080 STA POINTER1+1
|
|
5090 CLC
|
|
5100 ADC #$60
|
|
5110 STA POINTER4+1
|
|
5120 LDA (SCRPNT2),Y
|
|
5130 STA POINTER1
|
|
5140 STA POINTER4
|
|
5150 LDY FOODX
|
|
5160 LDA TEMP1
|
|
5170 STA (POINTER1),Y
|
|
5180 STA (POINTER4),Y
|
|
5190 INY
|
|
5200 EOR #$7F
|
|
5210 STA (POINTER1),Y
|
|
5220 STA (POINTER4),Y
|
|
5230 INY
|
|
5240 EOR #$7F
|
|
5250 STA (POINTER1),Y
|
|
5260 STA (POINTER4),Y
|
|
5270 LDX TEMP4
|
|
5280 CPX #$02
|
|
5290 BEQ .6
|
|
5300 CPX #$05
|
|
5310 BEQ .6
|
|
5320 INY
|
|
5330 EOR #$7F
|
|
5340 STA (POINTER1),Y
|
|
5350 STA (POINTER4),Y
|
|
5360 .6 INC TEMP3
|
|
5370 DEC HEIGHT
|
|
5380 BNE .1
|
|
5390 RTS
|
|
5400 CARRY.VERT
|
|
5410 BEQ .3
|
|
5420 LDA FOODBYT2,X
|
|
5430 CMP TABLE171,X
|
|
5440 BCC .8
|
|
5450 LDA MANSTATE
|
|
5460 CMP #$0B
|
|
5470 BNE .4
|
|
5480 LDA #$02
|
|
5490 STA MANSTATE
|
|
5500 .4 LDA MANY
|
|
5510 AND #$07
|
|
5520 BEQ .5
|
|
5530 CMP #$04
|
|
5540 BEQ .5
|
|
5550 .8 RTS
|
|
5560 .3 LDA FOODBYT2,X
|
|
5570 CMP TABLE171,X
|
|
5580 BCS .8
|
|
5590 LDA MANSTATE
|
|
5600 CMP #$0C
|
|
5610 BNE .4
|
|
5620 LDA #$04
|
|
5630 STA MANSTATE
|
|
5640 BNE .4
|
|
5650 .5 LDA TABLE152,X
|
|
5660 STA WIDTH
|
|
5670 LDA FOODBYT1,X
|
|
5680 STA FOODX
|
|
5690 TAY
|
|
5700 LDA FOODBYT2,X
|
|
5710 STA FOODY
|
|
5720 CLC
|
|
5730 ADC TABLE155,X
|
|
5740 TAX
|
|
5750 JSR CHECK.HORIZ.BLOCKS
|
|
5760 BNE .8
|
|
5770 LDX TEMP4
|
|
5780 LDA TABLE152,X
|
|
5790 STA WIDTH
|
|
5800 LDA FOODY
|
|
5810 CMP TABLE156,X
|
|
5820 BEQ .6
|
|
5830 CLC
|
|
5840 ADC TABLE157,X
|
|
5850 STA FOODBYT2,X
|
|
5860 STA FOODY
|
|
5870 CLC
|
|
5880 ADC TABLE153,X
|
|
5890 TAX
|
|
5900 LDY FOODX
|
|
5910 JSR VACATE.ROW
|
|
5920 LDX TEMP4
|
|
5930 LDA FOODY
|
|
5940 CLC
|
|
5950 ADC TABLE153,X
|
|
5960 JSR ERASE.HORIZ.BLOCKS
|
|
5970 LDX TEMP4
|
|
5980 TXA
|
|
5990 ORA #$10
|
|
6000 STA TEMP4
|
|
6010 LDA TABLE152,X
|
|
6020 STA WIDTH
|
|
6030 LDA FOODX
|
|
6040 PHA
|
|
6050 LDA FOODY
|
|
6060 PHA
|
|
6070 CLC
|
|
6080 ADC TABLE161,X
|
|
6090 STA FOODY
|
|
6100 JSR CHECK.ONE.ROW
|
|
6110 PLA
|
|
6120 STA FOODY
|
|
6130 PLA
|
|
6140 STA FOODX
|
|
6150 LDA TEMP4
|
|
6160 AND #$07
|
|
6170 STA TEMP4
|
|
6180 TAX
|
|
6190 JSR PLOT.FOOD2.Z
|
|
6200 LDA TABLE167,X
|
|
6210 JMP UPDATE.VERT.DESTBYTS2.Z
|
|
6220 .6 LDA TABLE152,X
|
|
6230 EXT1
|
|
6240 STA WIDTH
|
|
6250 STA TEMP1
|
|
6260 LDX FOODY
|
|
6270 LDY FOODX
|
|
6280 JSR VACATE.ROW
|
|
6290 INX
|
|
6300 LDY FOODX
|
|
6310 LDA TEMP1
|
|
6320 STA WIDTH
|
|
6330 JSR VACATE.ROW
|
|
6340 LDA FOODY
|
|
6350 JSR ERASE.HORIZ.BLOCKS
|
|
6360 LDY FOODY
|
|
6370 INY
|
|
6380 TYA
|
|
6390 JSR ERASE.HORIZ.BLOCKS
|
|
6400 LDX TEMP4
|
|
6410 LDA TABLE158,X
|
|
6420 STA FOODY
|
|
6430 STA FOODBYT2,X
|
|
6440 LDA TABLE160,X
|
|
6450 STA WIDTH
|
|
6460 PHA
|
|
6470 LDA FOODX
|
|
6480 PHA
|
|
6490 LDA TEMP4
|
|
6500 ORA #$50
|
|
6510 STA TEMP4
|
|
6520 JSR CHECK.ONE.ROW
|
|
6530 PLA
|
|
6540 STA FOODX
|
|
6550 PLA
|
|
6560 STA WIDTH
|
|
6570 LDA FOODX
|
|
6580 PHA
|
|
6590 JSR CHECK.ONE.ROW
|
|
6600 PLA
|
|
6610 STA FOODX
|
|
6620 DEC FOODY
|
|
6630 LDA TEMP4
|
|
6640 AND #$07
|
|
6650 STA TEMP4
|
|
6660 TAX
|
|
6670 LDA TABLE158,X
|
|
6680 STA FOODY
|
|
6690 JSR PLOT.FOOD2.Z
|
|
6700 LDA #$81
|
|
6710 STA FOODBYT3,X
|
|
6720 LDA TABLE152,X
|
|
6730 STA WIDTH
|
|
6740 LDY TABLE164,X
|
|
6750 .13 LDA TABLE165,Y
|
|
6760 STA DESTBYT1,Y
|
|
6770 LDA TABLE166,Y
|
|
6780 STA DESTBYT2,Y
|
|
6790 INY
|
|
6800 DEC WIDTH
|
|
6810 BNE .13
|
|
6820 LDA #$00
|
|
6830 STA GRAB.FOOD
|
|
6840 STA BYFOOD
|
|
6850 STA ANTPOSITIONS,X
|
|
6860 RTS
|
|
6870 CHECK.ROWS
|
|
6880 LDA FOODX
|
|
6890 PHA
|
|
6900 LDA WIDTH
|
|
6910 PHA
|
|
6920 JSR CHECK.ONE.ROW
|
|
6930 PLA
|
|
6940 STA WIDTH
|
|
6950 PLA
|
|
6960 STA FOODX
|
|
6970 PHA
|
|
6980 LDA WIDTH
|
|
6990 PHA
|
|
7000 DEC FOOD.HEIGHT
|
|
7010 JSR CHECK.ONE.ROW
|
|
7020 PLA
|
|
7030 STA WIDTH
|
|
7040 PLA
|
|
7050 STA FOODX
|
|
7060 DEC FOOD.HEIGHT
|
|
7070 BEQ .9
|
|
7080 PHA
|
|
7090 LDA WIDTH
|
|
7100 PHA
|
|
7110 JSR CHECK.ONE.ROW
|
|
7120 PLA
|
|
7130 STA WIDTH
|
|
7140 PLA
|
|
7150 STA FOODX
|
|
7160 DEC FOOD.HEIGHT
|
|
7170 BEQ .9
|
|
7180 PHA
|
|
7190 JSR CHECK.ONE.ROW
|
|
7200 PLA
|
|
7210 STA FOODX
|
|
7220 .9 LDA TEMP4
|
|
7230 AND #$07
|
|
7240 STA TEMP4
|
|
7250 TAX
|
|
7260 LDA FOODBYT2,X
|
|
7270 STA FOODY
|
|
7280 .LI ON
|
|
7290 RTS
|
|
7300 .LI OFF
|