mirror of
https://github.com/RaySollium99/picodrive.git
synced 2025-09-05 07:17:45 -04:00
fix a corner case with h-int
This commit is contained in:
parent
ee3c39efd2
commit
0a0073dc9f
1 changed files with 8 additions and 7 deletions
|
@ -113,9 +113,7 @@ static int PicoFrameHints(void)
|
||||||
z80_resetCycles();
|
z80_resetCycles();
|
||||||
PsndStartFrame();
|
PsndStartFrame();
|
||||||
|
|
||||||
// Load H-Int counter
|
hint = pv->hint_cnt;
|
||||||
hint = (pv->status & PVS_ACTIVE) ? pv->hint_cnt : pv->reg[10];
|
|
||||||
|
|
||||||
pv->status |= PVS_ACTIVE;
|
pv->status |= PVS_ACTIVE;
|
||||||
|
|
||||||
for (y = 0; ; y++)
|
for (y = 0; ; y++)
|
||||||
|
@ -306,11 +304,14 @@ static int PicoFrameHints(void)
|
||||||
|
|
||||||
PAD_DELAY();
|
PAD_DELAY();
|
||||||
|
|
||||||
if ((pv->status & PVS_ACTIVE) && --hint < 0)
|
if (unlikely(pv->status & PVS_ACTIVE)) {
|
||||||
{
|
if (--hint < 0) {
|
||||||
hint = pv->reg[10]; // Reload H-Int counter
|
hint = pv->reg[10]; // Reload H-Int counter
|
||||||
do_hint(pv);
|
do_hint(pv);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
hint = pv->reg[10];
|
||||||
|
|
||||||
// Run scanline:
|
// Run scanline:
|
||||||
Pico.t.m68c_line_start = Pico.t.m68c_aim;
|
Pico.t.m68c_line_start = Pico.t.m68c_aim;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue