Wycube / gambit

A Game Boy Advance Emulator in C++.
MIT License
5 stars 0 forks source link

FF6 resets right after the game is started #5

Closed Wycube closed 1 year ago

Wycube commented 1 year ago

It appears to be because an hblank interrupt is firing during the vblank interrupt handler, my hblank interrupt timing must be off. Disabling hblank interrupts starts the game, which runs fine albeit with some graphical glitches.

Wycube commented 1 year ago

It seems to be the lack of WAITCNT emulation, so the instructions it's executing from ROM are too fast and the HBlank interrupt doesn't fire at the time it would. That seems to be the cause at least.

Wycube commented 1 year ago

Nevermind, my MSR implementation was just wrong causing nested interrupts with arm/thumb mode changes to not be reset correctly.