Stop all sound when stopping time
This commit is contained in:
@@ -116,8 +116,26 @@ data CWCam = CWCam
|
||||
data CWorld = CWorld
|
||||
{ _lWorld :: LWorld
|
||||
, _cwGen :: CWGen
|
||||
, _cwClock :: Int
|
||||
, _pastWorlds :: [LWorld]
|
||||
, _timeFlow :: TimeFlowStatus
|
||||
}
|
||||
|
||||
data TimeFlowStatus
|
||||
= RewindingNow
|
||||
| DeathTime
|
||||
{ _deathDelay :: Int }
|
||||
| RewindingLastFrame
|
||||
| NormalTimeFlow
|
||||
| ScrollTimeFlow
|
||||
{ _scrollSmoothing :: Int
|
||||
, _reverseAmount :: Int
|
||||
, _futureWorlds :: [LWorld]
|
||||
, _scrollItemLocation :: Int
|
||||
}
|
||||
| RewindLeftClick
|
||||
{ _reverseAmount :: Int }
|
||||
|
||||
data LWorld = LWorld
|
||||
{ _cwCam :: CWCam
|
||||
, _creatures :: IM.IntMap Creature
|
||||
@@ -178,6 +196,7 @@ data LWorld = LWorld
|
||||
, _seenLocations :: IM.IntMap (WdP2, String)
|
||||
, _selLocation :: Int
|
||||
, _distortions :: [Distortion]
|
||||
, _lClock :: Int
|
||||
}
|
||||
|
||||
data CWGen = CWGen
|
||||
@@ -202,6 +221,7 @@ makeLenses ''LWorld
|
||||
makeLenses ''WorldBeams
|
||||
makeLenses ''CWCam
|
||||
makeLenses ''CWGen
|
||||
makeLenses ''TimeFlowStatus
|
||||
concat
|
||||
<$> mapM
|
||||
(deriveJSON defaultOptions)
|
||||
@@ -210,4 +230,5 @@ concat
|
||||
, ''CWGen
|
||||
, ''CWorld
|
||||
, ''LWorld
|
||||
, '' TimeFlowStatus
|
||||
]
|
||||
|
||||
@@ -23,7 +23,6 @@ import Dodge.Data.SoundOrigin
|
||||
import Geometry.Data
|
||||
import SDL (MouseButton, Scancode)
|
||||
import Sound.Data
|
||||
import MaybeHelp
|
||||
import System.Random
|
||||
|
||||
data World = World
|
||||
@@ -45,23 +44,9 @@ data World = World
|
||||
, _rSelect :: Point2
|
||||
, _clickMousePos :: Point2
|
||||
, _backspaceTimer :: Int
|
||||
, _timeFlow :: TimeFlowStatus
|
||||
, _rbOptions :: RightButtonOptions
|
||||
, _cwTime :: CWTime
|
||||
}
|
||||
|
||||
data TimeFlowStatus
|
||||
= RewindingNow
|
||||
| RewindingLastFrame
|
||||
| NormalTimeFlow
|
||||
| ScrollTimeFlow
|
||||
{ _scrollSmoothing :: Int
|
||||
, _reverseAmount :: Int
|
||||
, _futureWorlds :: [CWorld]
|
||||
, _scrollItemLocation :: Int
|
||||
}
|
||||
| RewindLeftClick
|
||||
{ _reverseAmount :: Int }
|
||||
-- deriving (Eq, Ord, Show, Read) --Generic, Flat)
|
||||
|
||||
data WorldHammer
|
||||
@@ -69,14 +54,4 @@ data WorldHammer
|
||||
| DoubleMouseHam
|
||||
deriving (Eq, Ord, Show, Read, Enum, Bounded)
|
||||
|
||||
data CWTime = CWTime
|
||||
{ _maybeWorld :: Maybe' CWorld
|
||||
, _pastWorlds :: [CWorld]
|
||||
, _pastWorldsNum :: Int
|
||||
, _worldClock :: Int
|
||||
, _deathDelay :: Maybe Int
|
||||
}
|
||||
|
||||
makeLenses ''World
|
||||
makeLenses ''CWTime
|
||||
makeLenses ''TimeFlowStatus
|
||||
|
||||
Reference in New Issue
Block a user