I got a few questions with the $2002.5 flag (8 sprite flag). Not really concerned too much with them... but I figure I'd see if I can get my understanding clarified anyway.
1) Is it set when the 8th sprite is found? or the 9th? BT's doc gives the impression it's done on the 9th... but it seems like the 8th would make a whole lot more sense.
2) If Sprite rendering is off... it would never be set, correct?
3) Do any games actually check this flag?
Thanks
1) It's on the 9th sprite. The PPU can render 8 sprites on a scanline and if it has to render more than that it get's rid of the lower priorty ones and sets this bit "telling" that it's dropped sprites.
2)Good question. I'd assume that it isn't, but I have no idea.
3)I think that many games check this bit probably for their OAM shuffling routine. When this bit gets set that would let em know to start shuffling their sprites. I guess they could also use it for some sort of tming routine, but that's best suited for the Sprite 0 hit. I've seen some demos that check this bit too.
>>3) Do any games actually check this flag?
Not sure, but at least one game relies on only 8 sprites being drawn: Castlevania 2. See
this post from the old message board and the follow up post for details.
I just added the option of enabling/disabling the 8 sprite limit in my emulator today for this reason. By default, I draw all sprites, since it eliminates a lot of flickering in some games.
James
James wrote:
I just added the option of enabling/disabling the 8 sprite limit in my emulator today for this reason. By default, I draw all sprites, since it eliminates a lot of flickering in some games.
At which PPU cycle does your emulator fetch pattern table data for sprites beyond the 8th?
>>At which PPU cycle does your emulator...
My PPU emulation is scanline based.
In a "scanline based" engine, how do you handle MMC2 (Punch-Out!!) or MMC4 (Family War)?
tepples wrote:
how do you handle MMC2 (Punch-Out!!) or MMC4 (Family War)?
Don't know -- I haven't written the code for those mappers yet.
tepples wrote:
In a "scanline based" engine, how do you handle MMC2 (Punch-Out!!) or MMC4 (Family War)?
It is not too hard to get MMC2 going on a scanline-based engine; as for the other game, I really don't know. What the heck does it do that is so special?
Hyde: MMC4 is almost exactly like MMC2. Check the wiki.
I don't believe scanline-based or not should make much difference when emulating MMC2.