first thing is first. I run through the init code. that stores a #$00 into the PPUMASK and the PPUCTRL I establish the oamdma area. zero out memory, put sprites at FF. etc
then, to give an overview of my program, I load everything in by scenes. scenes are arrays that contain a place, and people.
I get to the people part, and first load their palettes. everything works. then I load in their sprites. their sprites are in the ram at $0200. after I do that I return to the main loop (where i dont CLI, but i have tried it both ways), turn on the PPUMASK for rendering (00011110 inside vblank), then enable the ppu with 8x16 sprites, background pattern table at 1 and NMI enabled (%10110100 also in vblank). then jump right into main loop
I have also put code in the nmi that saves the a,x,y registers, loads #$00 into OAMADDR, and then loads #$02 into OAMDMA, then restores registers
and nothing, at all
In the fceux ppu viewer, I get the background. all the colors are loaded in. my sprites. and in the ram I see all the sprites there as well. I colored in every sprite just in case I was using the wrong pattern table (8x16 will use even numbers in my case, but I know that).
I have tried putting a write to OAMDMA after loading the sprites, I have tried making them 8x8. I have also turned on the ppu in other nametables just to see if they were written to another nametable. I just don't know what else to try. I'm really confused...
This data all shows up starting at $0200 in the ram as well. so either it is not being updated every frame or its just not working. Thanks guys I've spent all day on this
Code: Select all
spriteData:
;head
.byte $20, $00, $00, $08; formatted by y axis, sprite number, no rotation/palette 0/no priority
.byte $20, $02, $00, $10
.byte $20, $00, $40, $17; some have rotation
;body
.byte $30, $04, $01, $08; some use different palettes
.byte $30, $06, $01, $10
.byte $30, $08, $01, $18
;legs
.byte $40, $0a, $01, $08
.byte $40, $0c, $01, $10
.byte $40, $0a, $41, $17