get Affectionate class to work
This commit is contained in:
parent
13f67c6cd1
commit
786bfe1b21
1 changed files with 3 additions and 2 deletions
|
@ -3,6 +3,7 @@
|
||||||
{-# LANGUAGE ExplicitForAll #-}
|
{-# LANGUAGE ExplicitForAll #-}
|
||||||
{-# LANGUAGE ScopedTypeVariables #-}
|
{-# LANGUAGE ScopedTypeVariables #-}
|
||||||
{-# LANGUAGE RankNTypes #-}
|
{-# LANGUAGE RankNTypes #-}
|
||||||
|
{-# LANGUAGE TypeApplications #-}
|
||||||
module Affection
|
module Affection
|
||||||
( withAffection
|
( withAffection
|
||||||
, get
|
, get
|
||||||
|
@ -38,7 +39,7 @@ import qualified Graphics.Rendering.OpenGL as GL (clear, flush, ClearBuffer(..))
|
||||||
|
|
||||||
-- | Main function which bootstraps everything else.
|
-- | Main function which bootstraps everything else.
|
||||||
withAffection
|
withAffection
|
||||||
:: (Affectionate us)
|
:: forall us. (Affectionate us)
|
||||||
=> AffectionConfig us -- ^ Configuration of the Game and its engine.
|
=> AffectionConfig us -- ^ Configuration of the Game and its engine.
|
||||||
-> IO ()
|
-> IO ()
|
||||||
withAffection AffectionConfig{..} = do
|
withAffection AffectionConfig{..} = do
|
||||||
|
@ -79,7 +80,7 @@ withAffection AffectionConfig{..} = do
|
||||||
-- get current time
|
-- get current time
|
||||||
execTime <- getTime Monotonic
|
execTime <- getTime Monotonic
|
||||||
liftIO $ logIO Debug "Loading initial data container"
|
liftIO $ logIO Debug "Loading initial data container"
|
||||||
gameData <- loadState :: forall us. IO (Data us)
|
gameData <- loadState @us
|
||||||
let initContainer = AffectionData
|
let initContainer = AffectionData
|
||||||
{ drawWindows = windows
|
{ drawWindows = windows
|
||||||
, glContext = contexts
|
, glContext = contexts
|
||||||
|
|
Loading…
Reference in a new issue