|
Hmmm.. it has been so long since I did nametable loading I am forgetting the quirks. Say I wanted to cycle through nametables by pressing the start button. I can load the first two, but the third one gets all corrupted. I think I am forgetting something simple, but here is the basic idea I am going with:
jsr ldtitle ;completely loads 2 nametables (one at $2000, one at $2800)
;this sets up the PPU lda #%10001000 sta $2000 lda #%00011110 sta $2001
jsr pollstrt ;poll for press start jsr waitv2 ;wait for vblank jsr swapnam0 ;swap nametables so we see 2nd screen ;(it works good so far) jsr load1st ;loads the 3rd nametable at $2000 which is offscreen ;at this moment. This is the corrupted one. jsr pollstrt ;Wait for press start jsr waitv2 ;Wait for vblank jsr swapnam0 ;swap nametables so we see screen 3 ;However it looks like crap.
See what I'm getting at here? Do I have to turn off backgrounds or something while loading the third nametable?
-Pulper
|