mirror of
https://github.com/libretro/nestopia.git
synced 2025-10-14 02:07:20 +08:00
NstPpu: Make fast 0x2007 reads of palette RAM more accurate
This commit is contained in:
@@ -1069,21 +1069,22 @@ namespace Nes
|
||||
|
||||
if ((address & 0x3F00) == 0x3F00) // Palette
|
||||
{
|
||||
if (fastread)
|
||||
{
|
||||
io.latch = cache;
|
||||
}
|
||||
io.latch = (io.latch & 0xC0) | (palette.ram[address & 0x1F] & Coloring());
|
||||
mask = 0x3F;
|
||||
}
|
||||
else // Non-Palette
|
||||
{
|
||||
io.latch = io.buffer;
|
||||
io.latch = fastread ? cache : io.buffer;
|
||||
}
|
||||
|
||||
UpdateDecay(mask);
|
||||
|
||||
io.buffer = (address >= 0x2000 ? nmt.FetchName( address ) : chr.FetchPattern( address ));
|
||||
|
||||
if (fastread)
|
||||
io.latch = cache;
|
||||
|
||||
return io.latch;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user