diff --git a/src/snes/emulator.rs b/src/snes/emulator.rs index 38bb2cf..89b3de9 100644 --- a/src/snes/emulator.rs +++ b/src/snes/emulator.rs @@ -254,7 +254,7 @@ where } Schedule::PPU => { // 5.3 MHz - Ok(self.cpu.bus.ppu.tick(1)? * 4) + Ok(self.cpu.bus.ppu.tick(24)? * 4) } Schedule::SPC700 => { // 1.024 MHz diff --git a/src/snes/ppu/ppu.rs b/src/snes/ppu/ppu.rs index 5e12e24..2627fc1 100644 --- a/src/snes/ppu/ppu.rs +++ b/src/snes/ppu/ppu.rs @@ -292,18 +292,7 @@ where } } - let batch = if self.vblank { - // Next time slice after VBlank - (Self::CYCLES_PER_SCANLINE * Self::SCANLINES_PER_FRAME) - self.cycles - } else if self.hblank { - // Next time slice after HBlank - Self::CYCLES_PER_SCANLINE - Self::LINE_HBLANK_START - } else { - // Next time slice at HBlank - Self::LINE_HBLANK_START - }; - self.cycles += batch - ticks; - Ok(batch) + Ok(ticks) } }