fix resume() discarding changed music volume

This commit is contained in:
2023-09-16 11:51:10 -06:00
parent 88ed62d573
commit 38ba3063e1

View File

@@ -814,7 +814,9 @@
(unless waitForEnd (cc))))
(method :Void changeSongVolume [:Float volumeMod :Continuation cc]
(set music.volume (* volumeMod musicVolume))
(let [[fade oldMod] (dictGet currentSoundVolumes music)]
(set music.volume (* fade volumeMod musicVolume))
(dictSet currentSoundVolumes music [fade volumeMod]))
(cc))
(method :Void stopSong []