fix(ppu): PPU cycle count increases even if LCDC bit 7 says otherwise
continuous-integration/drone/push Build is passing Details

This commit is contained in:
Rekai Nyangadzayi Musuka 2021-07-12 21:32:50 -05:00
parent afdfcfce2c
commit 192bdffd64
1 changed files with 2 additions and 2 deletions

View File

@ -67,12 +67,12 @@ impl BusIo for Ppu {
impl Ppu { impl Ppu {
pub(crate) fn clock(&mut self) { pub(crate) fn clock(&mut self) {
self.cycle += 1;
if !self.ctrl.lcd_enabled() { if !self.ctrl.lcd_enabled() {
return; return;
} }
self.cycle += 1;
match self.stat.mode() { match self.stat.mode() {
PpuMode::OamScan => { PpuMode::OamScan => {
if self.cycle >= 80.into() { if self.cycle >= 80.into() {