From 202eb2b5cc1c63224ac80be530a46ac1c9aa5c3e Mon Sep 17 00:00:00 2001 From: Lior Halphon Date: Sun, 18 Mar 2018 20:32:19 +0200 Subject: [PATCH] Fix stat_lyc_onoff --- Core/display.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/Core/display.c b/Core/display.c index 18fe3bd..dca6498 100755 --- a/Core/display.c +++ b/Core/display.c @@ -266,11 +266,9 @@ void GB_lcd_off(GB_gameboy_t *gb) gb->display_cycles = 0; /* When the LCD is disabled, state is constant */ - /* When the LCD is off, LY is 0 and STAT mode is 0. - Todo: Verify the LY=LYC flag should be on. */ + /* When the LCD is off, LY is 0 and STAT mode is 0. */ gb->io_registers[GB_IO_LY] = 0; gb->io_registers[GB_IO_STAT] &= ~3; - gb->io_registers[GB_IO_STAT] |= 4; if (gb->hdma_on_hblank) { gb->hdma_on_hblank = false; gb->hdma_on = false; @@ -278,7 +276,6 @@ void GB_lcd_off(GB_gameboy_t *gb) /* Todo: is this correct? */ gb->hdma_steps_left = 0xff; } - gb->stat_interrupt_line = false; gb->oam_read_blocked = false; gb->vram_read_blocked = false;