GB, GBA Serialize: Fix loading two states in a row

This commit is contained in:
Vicki Pfau 2019-02-22 22:22:06 -08:00
parent 595e73aec6
commit fc33aec7bb
3 changed files with 3 additions and 2 deletions

View File

@ -15,6 +15,7 @@ Bugfixes:
- GBA DMA: Fix Display Start DMAs
- GBA DMA: Fix DMA start/end timing
- Qt: Fix window icon on X11
- GB, GBA Serialize: Fix loading two states in a row
Misc:
- GBA Video: Improve sprite cycle counting (fixes mgba.io/i/1274)

View File

@ -138,7 +138,7 @@ bool GBDeserialize(struct GB* gb, const struct GBSerializedState* state) {
if (error) {
return false;
}
gb->timing.root = NULL;
mTimingClear(&gb->timing);
LOAD_32LE(gb->timing.masterCycles, 0, &state->masterCycles);
gb->cpu->a = state->cpu.a;

View File

@ -128,7 +128,7 @@ bool GBADeserialize(struct GBA* gba, const struct GBASerializedState* state) {
if (error) {
return false;
}
gba->timing.root = NULL;
mTimingClear(&gba->timing);
LOAD_32(gba->timing.masterCycles, 0, &state->masterCycles);
size_t i;