NES DCM glitch cleanup

-Implemenet for player 2
-make sure only happens on NTSC
This commit is contained in:
alyosha-tas 2017-01-10 10:39:15 -05:00 committed by GitHub
parent ab1a22bf31
commit 9aee377d66
1 changed files with 21 additions and 14 deletions

View File

@ -576,8 +576,9 @@ namespace BizHawk.Emulation.Cores.Nintendo.NES
{
// special hardware glitch case
ret_spec = read_joyport(addr);
if (do_the_reread)
if (do_the_reread && ppu.region==PPU.Region.NTSC)
{
Console.WriteLine("collision 1");
ret_spec = read_joyport(addr);
do_the_reread = false;
}
@ -585,7 +586,6 @@ namespace BizHawk.Emulation.Cores.Nintendo.NES
}
case 0x4017:
{
if (_isVS)
{
byte ret = 0;
@ -599,8 +599,15 @@ namespace BizHawk.Emulation.Cores.Nintendo.NES
}
else
{
return read_joyport(addr);
// special hardware glitch case
ret_spec = read_joyport(addr);
if (do_the_reread && ppu.region == PPU.Region.NTSC)
{
Console.WriteLine("collision 2");
ret_spec = read_joyport(addr);
do_the_reread = false;
}
return ret_spec;
}
default:
//Console.WriteLine("read register: {0:x4}", addr);