NES: fix credits sequence in metal slader glory. this may have impact in other MMC5 programs; not tested
This commit is contained in:
parent
3e5945660f
commit
235f92c82e
|
@ -686,18 +686,20 @@ namespace BizHawk.Emulation.Cores.Nintendo.NES
|
||||||
{
|
{
|
||||||
if (NES.ppu.ppur.status.cycle != 336)
|
if (NES.ppu.ppur.status.cycle != 336)
|
||||||
return;
|
return;
|
||||||
if (!NES.ppu.reg_2001.PPUON)
|
|
||||||
return;
|
|
||||||
|
|
||||||
int sl = NES.ppu.ppur.status.sl + 1;
|
int sl = NES.ppu.ppur.status.sl + 1;
|
||||||
|
|
||||||
//not a visible scanline
|
if (!NES.ppu.reg_2001.PPUON || sl >= 241)
|
||||||
if (sl >= 241)
|
|
||||||
{
|
{
|
||||||
|
// whenever rendering is off for any reason (vblank or forced disable
|
||||||
|
// the irq counter resets, as well as the inframe flag (easily verifiable from software)
|
||||||
in_frame = false;
|
in_frame = false;
|
||||||
|
irq_counter = 0;
|
||||||
|
irq_pending = false;
|
||||||
|
SyncIRQ();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!in_frame)
|
if (!in_frame)
|
||||||
{
|
{
|
||||||
in_frame = true;
|
in_frame = true;
|
||||||
|
@ -710,6 +712,7 @@ namespace BizHawk.Emulation.Cores.Nintendo.NES
|
||||||
irq_counter++;
|
irq_counter++;
|
||||||
if (irq_counter == irq_target)
|
if (irq_counter == irq_target)
|
||||||
{
|
{
|
||||||
|
Console.WriteLine("IRQ @{0}", irq_target);
|
||||||
irq_pending = true;
|
irq_pending = true;
|
||||||
SyncIRQ();
|
SyncIRQ();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue