diff options
| author | sik | 2017-07-23 03:20:35 -0300 |
|---|---|---|
| committer | sik | 2017-07-23 03:20:35 -0300 |
| commit | 3aacf3d2cedfdeca49ceb57533389870bfc688a9 (patch) | |
| tree | a46d166fa9270700e8e159ca9ae455ac24472771 /src-z80/player/fm.z80 | |
| parent | a679ba38190bfed6ae150a12e819ad7527c495d1 (diff) | |
Now with pausing and other niceties
Diffstat (limited to 'src-z80/player/fm.z80')
| -rw-r--r-- | src-z80/player/fm.z80 | 30 |
1 files changed, 23 insertions, 7 deletions
diff --git a/src-z80/player/fm.z80 b/src-z80/player/fm.z80 index 505e849..d5d49ba 100644 --- a/src-z80/player/fm.z80 +++ b/src-z80/player/fm.z80 @@ -432,7 +432,13 @@ LoadFMDirect: ;**************************************************************************** SetFMVolSFX: - call SetFMVolSFXEvent ; We're just a wrapper + push af + PollPCM + call GetParam ; Get new volume + PollPCM + pop af + + call SetFMVolLoad ; We're just a wrapper jp ProcessSFXRun ; End of subroutine SetFMVolBGM: @@ -487,12 +493,21 @@ SetFMVolBGM: call SetFMVolLoad ; We're just a wrapper jp ProcessBGMRun ; End of subroutine -SetFMVolSFXEvent: - push af - PollPCM - call GetParam ; Get new volume - PollPCM - pop af +;---------------------------------------------------------------------------- +; input a = channel ID +; input b = new volume level +;---------------------------------------------------------------------------- + +SetFMVolTempLoad: + push bc + push de + push hl + jp SetFMVolDoIt + +;---------------------------------------------------------------------------- +; input a = channel ID (bottom 3 bits) +; input b = new volume level +;---------------------------------------------------------------------------- SetFMVolLoad: push bc @@ -508,6 +523,7 @@ SetFMVolLoad: ld (hl), b pop af +SetFMVolDoIt: push af ld h, RAM_FMData>>8 ; Get address of FM data add RAM_FMData&$FF |
