{-# OPTIONS_HADDOCK hide #-}

module Graphics.Gloss.Internals.Interface.Simulate.State
        ( State (..)
        , stateInit )
where

-- | Simulation state
data State
 =      State
        { -- | The iteration number we're up to.
          State -> Integer
stateIteration        :: !Integer

        -- | How many simulation setps to take for each second of real time
        , State -> Int
stateResolution       :: !Int

        -- | How many seconds worth of simulation we've done so far
        , State -> Float
stateSimTime          :: !Float  }


-- | Initial control state
stateInit :: Int -> State
stateInit :: Int -> State
stateInit Int
resolution
        = State :: Integer -> Int -> Float -> State
State
        { stateIteration :: Integer
stateIteration                = Integer
0
        , stateResolution :: Int
stateResolution               = Int
resolution
        , stateSimTime :: Float
stateSimTime                  = Float
0 }