mirror of https://github.com/mgba-emu/mgba.git
GB: Ending HDMAs should clear isHdma bit
This commit is contained in:
parent
dd39a0add4
commit
cf27d88696
|
@ -366,6 +366,9 @@ void _GBMemoryHDMAService(struct GB* gb) {
|
|||
gb->memory.io[REG_HDMA4] = gb->memory.hdmaDest;
|
||||
if (gb->memory.isHdma) {
|
||||
--gb->memory.io[REG_HDMA5];
|
||||
if (gb->memory.io[REG_HDMA5] == 0xFF) {
|
||||
gb->memory.isHdma = false;
|
||||
}
|
||||
} else {
|
||||
gb->memory.io[REG_HDMA5] |= 0x80;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue