Fixed a timer regression, fixes timer_if in DMG mode. Relates to #54

This commit is contained in:
Lior Halphon 2018-03-31 15:52:31 +03:00
parent 73dc3560a5
commit 0d0d9ccdae
1 changed files with 1 additions and 1 deletions

View File

@ -145,7 +145,7 @@ static void GB_timers_run(GB_gameboy_t *gb, uint8_t cycles)
} }
GB_set_internal_div_counter(gb, 0); GB_set_internal_div_counter(gb, 0);
GB_SLEEP(gb, div, 1, 2); GB_SLEEP(gb, div, 1, 3);
while (true) { while (true) {
advance_tima_state_machine(gb); advance_tima_state_machine(gb);
GB_set_internal_div_counter(gb, gb->div_counter + 4); GB_set_internal_div_counter(gb, gb->div_counter + 4);