Fixed TMA writing while reloading.

This commit is contained in:
Lior Halphon 2016-08-06 14:36:33 +03:00
parent 85a33ed8ef
commit d03a1fbd16
1 changed files with 1 additions and 1 deletions

View File

@ -384,7 +384,7 @@ static void write_high_memory(GB_gameboy_t *gb, uint16_t addr, uint8_t value)
case GB_IO_TMA:
gb->io_registers[GB_IO_TMA] = value;
if (gb->tima_reload_state == GB_TIMA_RELOADED) {
if (gb->tima_reload_state != GB_TIMA_RUNNING) {
gb->io_registers[GB_IO_TIMA] = value;
}
return;