diff --git a/src/core/gpu/mod.rs b/src/core/gpu/mod.rs index ad37cb8..5a9d140 100644 --- a/src/core/gpu/mod.rs +++ b/src/core/gpu/mod.rs @@ -513,7 +513,7 @@ impl Gpu { if self.cycles > CYCLES_SCANLINE { self.cycles -= CYCLES_SCANLINE; - if self.current_scanline < DISPLAY_HEIGHT + VBLANK_LINES { + if self.current_scanline < DISPLAY_HEIGHT + VBLANK_LINES - 1 { self.update_vcount(self.current_scanline + 1, irqs); return None; } else {