chore(ppu): flatten if statement

This commit is contained in:
Rekai Nyangadzayi Musuka 2021-04-24 02:13:56 -05:00
parent 2586314f9a
commit 1343e8e52e
1 changed files with 4 additions and 6 deletions

View File

@ -82,13 +82,11 @@ impl Ppu {
self.obj_buffer.clear();
self.stat.set_mode(Mode::HBlank);
} else if self.control.lcd_enabled() {
// Only Draw when the LCD Is Enabled
self.draw(self.cycles.into());
} else {
if self.control.lcd_enabled() {
// Only Draw when the LCD Is Enabled
self.draw(self.cycles.into());
} else {
self.reset();
}
self.reset();
}
}
Mode::HBlank => {