mirror of
https://github.com/a2-4am/4cade.git
synced 2024-11-30 13:50:45 +00:00
build address table at runtime
This commit is contained in:
parent
9dafce5ae8
commit
5d8c483073
@ -5,6 +5,16 @@
|
|||||||
!to "build/FX/DHGR.FIZZLE",plain
|
!to "build/FX/DHGR.FIZZLE",plain
|
||||||
*=$6000
|
*=$6000
|
||||||
|
|
||||||
|
addrs=$6100
|
||||||
|
|
||||||
|
ldx #$1F ; build address lookup table
|
||||||
|
- txa
|
||||||
|
eor #$20
|
||||||
|
sta addrs, x
|
||||||
|
eor #$80
|
||||||
|
sta addrs+$20, x
|
||||||
|
dex
|
||||||
|
bpl -
|
||||||
ldx #(end-start) ; copy LFSR code to zero page
|
ldx #(end-start) ; copy LFSR code to zero page
|
||||||
- lda start-1, x
|
- lda start-1, x
|
||||||
sta $0, x
|
sta $0, x
|
||||||
@ -51,8 +61,3 @@ exit lda $4000 ; last lousy byte (because LFSR never hits
|
|||||||
rts
|
rts
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
addrs
|
|
||||||
!byte $20,$21,$22,$23,$24,$25,$26,$27,$28,$29,$2A,$2B,$2C,$2D,$2E,$2F
|
|
||||||
!byte $30,$31,$32,$33,$34,$35,$36,$37,$38,$39,$3A,$3B,$3C,$3D,$3E,$3F
|
|
||||||
!byte $A0,$A1,$A2,$A3,$A4,$A5,$A6,$A7,$A8,$A9,$AA,$AB,$AC,$AD,$AE,$AF
|
|
||||||
!byte $B0,$B1,$B2,$B3,$B4,$B5,$B6,$B7,$B8,$B9,$BA,$BB,$BC,$BD,$BE,$BF
|
|
||||||
|
Loading…
Reference in New Issue
Block a user