Allow sounds to play after death
This commit is contained in:
@@ -110,6 +110,7 @@ updateRenderSplit win u = do
|
||||
playSoundUnlessRewinding :: Universe -> IO (M.Map SoundOrigin Sound)
|
||||
playSoundUnlessRewinding u = case w ^. timeFlow of
|
||||
NormalTimeFlow -> playSoundAndUpdate (_soundData $ _preloadData u) (_playingSounds w) (newSoundsToPlay u)
|
||||
RespawnDelay{} -> playSoundAndUpdate (_soundData $ _preloadData u) (_playingSounds w) (newSoundsToPlay u)
|
||||
_ -> stopAllSounds >> return M.empty
|
||||
where
|
||||
w = _uvWorld u
|
||||
|
||||
+1
-1
@@ -880,7 +880,7 @@ checkEndGame uv = case w ^? timeFlow . respawnDelay of
|
||||
& uvWorld . timeFlow .~ NormalTimeFlow
|
||||
& uvWorld %~ respawn
|
||||
Just _ -> uv & uvWorld . timeFlow . respawnDelay -~ 1
|
||||
_ | null (you w ^? crHP . _HP) -> uv & uvWorld . timeFlow .~ RespawnDelay 50
|
||||
_ | null (you w ^? crHP . _HP) -> uv & uvWorld . timeFlow .~ RespawnDelay 100
|
||||
_ -> uv
|
||||
where
|
||||
w = _uvWorld uv
|
||||
|
||||
Reference in New Issue
Block a user