mirror of https://github.com/mgba-emu/mgba.git
GB, GBA Core: Reset audio when loading mVL states so audio sync works
This commit is contained in:
parent
25beafcc11
commit
aec8b82756
|
@ -818,6 +818,7 @@ static bool _GBVLPLoadState(struct mCore* core, const void* buffer) {
|
|||
|
||||
GBVideoDeserialize(&gb->video, state);
|
||||
GBIODeserialize(gb, state);
|
||||
GBAudioReset(&gb->audio);
|
||||
|
||||
// Make sure CPU loop never spins
|
||||
GBHalt(gb->cpu);
|
||||
|
|
|
@ -838,6 +838,7 @@ static bool _GBAVLPLoadState(struct mCore* core, const void* state) {
|
|||
gba->cpu->memory.store16(gba->cpu, BASE_IO | REG_IE, 0, NULL);
|
||||
GBAVideoDeserialize(&gba->video, state);
|
||||
GBAIODeserialize(gba, state);
|
||||
GBAAudioReset(&gba->audio);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue