mirror of https://github.com/mgba-emu/mgba.git
Core: Fix first event scheduling after loading savestate
This commit is contained in:
parent
49ee6dc302
commit
d4d4bfd3d1
1
CHANGES
1
CHANGES
|
@ -1,5 +1,6 @@
|
||||||
0.10.0: (Future)
|
0.10.0: (Future)
|
||||||
Emulation fixes:
|
Emulation fixes:
|
||||||
|
- Core: Fix first event scheduling after loading savestate
|
||||||
- GBA Memory: Fix loading Thumb savestates when in ARM mode
|
- GBA Memory: Fix loading Thumb savestates when in ARM mode
|
||||||
|
|
||||||
0.9.0: (2021-03-28)
|
0.9.0: (2021-03-28)
|
||||||
|
|
|
@ -100,7 +100,10 @@ int32_t mTimingTick(struct mTiming* timing, int32_t cycles) {
|
||||||
if (timing->reroot) {
|
if (timing->reroot) {
|
||||||
timing->root = timing->reroot;
|
timing->root = timing->reroot;
|
||||||
timing->reroot = NULL;
|
timing->reroot = NULL;
|
||||||
*timing->nextEvent = mTimingNextEvent(timing);
|
*timing->nextEvent = mTimingNextEvent(timing);
|
||||||
|
if (*timing->nextEvent <= 0) {
|
||||||
|
return mTimingTick(timing, 0);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
return *timing->nextEvent;
|
return *timing->nextEvent;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue