summaryrefslogtreecommitdiffstats
path: root/Game.hs
diff options
context:
space:
mode:
authorMatthias Schiffer <matthias@gamezock.de>2010-02-25 03:16:44 +0100
committerMatthias Schiffer <matthias@gamezock.de>2010-02-25 03:16:44 +0100
commitc23e63e66786410f53b9460a6456b7c893d2a234 (patch)
tree213a204572b94a9a864d9da9109a9f2a3f95a6ae /Game.hs
parentb4c3367c63459607f0919e77998d5405634e2003 (diff)
downloadhtanks-c23e63e66786410f53b9460a6456b7c893d2a234.tar
htanks-c23e63e66786410f53b9460a6456b7c893d2a234.zip
Cache textures in game state
Diffstat (limited to 'Game.hs')
-rw-r--r--Game.hs8
1 files changed, 5 insertions, 3 deletions
diff --git a/Game.hs b/Game.hs
index ef760d7..9097bca 100644
--- a/Game.hs
+++ b/Game.hs
@@ -7,17 +7,19 @@ module Game ( GameState(..)
import Level
import Tank
+import Texture
import Control.Monad
import Control.Monad.State
+import qualified Data.Map as M
data GameState = GameState
- { level :: !Level
- , tanks :: ![Tank]
+ { level :: !Level
+ , tanks :: ![Tank]
+ , textures :: !(M.Map Texture TextureObject)
} deriving (Show)
-
newtype Game a = Game (StateT GameState IO a)
deriving (Monad, MonadIO, MonadState GameState)