From da98253489b1334f9d23f477ec8fa2a76e664aa6 Mon Sep 17 00:00:00 2001 From: Javier Degirolmo Date: Sat, 7 Apr 2012 20:28:18 -0300 Subject: Bugfixes (especially killing FM channels), panning is restored, version bumped up to 0.9 - going to look mainly for bugs now... --- src-z80/core/sfx.z80 | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'src-z80/core/sfx.z80') diff --git a/src-z80/core/sfx.z80 b/src-z80/core/sfx.z80 index d008f0b..6eb844d 100644 --- a/src-z80/core/sfx.z80 +++ b/src-z80/core/sfx.z80 @@ -299,6 +299,24 @@ ClearSFX: ld b, (hl) call SetFMVolLoad pop bc + + ld a, b + and $04 + rrca + ld iyl, a + + push bc ; Restore BGM FM panning + ld a, b + ld h, RAM_BGMFMPan>>8 + add RAM_BGMFMPan&$FF + ld l, a + ld a, b + ld b, (hl) + and $03 + add $B4 + ld (iy+0), b + ld (iy+1), a + pop bc PollPCM inc b -- cgit v1.2.3