Fixed silly APU regression (Noise volume envelope ran too fast) Fixes #121

This commit is contained in:
Lior Halphon 2018-11-03 14:33:12 +02:00
parent 96e9ea2d1e
commit a39b314378

View File

@ -274,7 +274,7 @@ void GB_apu_div_event(GB_gameboy_t *gb)
} }
} }
if (gb->apu.is_active[GB_NOISE] && gb->apu.noise_channel.volume_countdown && (gb->io_registers[GB_IO_NR42] & 7)) { if (gb->apu.is_active[GB_NOISE] && gb->apu.noise_channel.volume_countdown == 0 && (gb->io_registers[GB_IO_NR42] & 7)) {
tick_noise_envelope(gb); tick_noise_envelope(gb);
} }
} }