Pause and resume sounds when pausing game
This commit is contained in:
+6
-7
@@ -1,12 +1,11 @@
|
||||
module Preload
|
||||
( cleanUpPreload
|
||||
)
|
||||
where
|
||||
module Preload (
|
||||
cleanUpPreload,
|
||||
) where
|
||||
|
||||
import Data.Preload
|
||||
import Preload.Render
|
||||
import Sound.Data
|
||||
|
||||
import qualified SDL.Mixer as Mix
|
||||
import Sound.Data
|
||||
|
||||
cleanUpPreload :: PreloadData -> IO ()
|
||||
cleanUpPreload pd = do
|
||||
@@ -14,4 +13,4 @@ cleanUpPreload pd = do
|
||||
cleanUpSoundPreload $ _soundData pd
|
||||
|
||||
cleanUpSoundPreload :: SoundData -> IO ()
|
||||
cleanUpSoundPreload _ = Mix.closeAudio
|
||||
cleanUpSoundPreload _ = Mix.closeAudio >> putStrLn "Audio closed"
|
||||
|
||||
Reference in New Issue
Block a user