Skip to content
Newer
Older
100644 19 lines (16 sloc) 548 Bytes
56bb623 @roman Making a Main.hs that will wrap the HaskBan.hs module
roman authored
1 module Main where
8654d01 @roman Adding the new version of the SokobanMonad
roman authored
2 import qualified Data.ByteString as BS
3 import Control.Monad (liftM)
4 import Control.Monad.State (runStateT)
b5282da @roman Updating to the last 'working' version
roman authored
5 import HaskBan.Monad (runSokobanMonad)
8654d01 @roman Adding the new version of the SokobanMonad
roman authored
6 import HaskBan.Parser
7 import HaskBan.Types
b745b0f @roman Fixing the compilation of the Main file
roman authored
8 import qualified HaskBan as HB
8654d01 @roman Adding the new version of the SokobanMonad
roman authored
9 import Data.IntMap ((!))
56bb623 @roman Making a Main.hs that will wrap the HaskBan.hs module
roman authored
10
8654d01 @roman Adding the new version of the SokobanMonad
roman authored
11 main :: IO ()
12 main = do
b5282da @roman Updating to the last 'working' version
roman authored
13 sokobanInfo <- readSokobanInfo
14 (a, s) <- runSokobanMonad HB.main sokobanInfo
8654d01 @roman Adding the new version of the SokobanMonad
roman authored
15 return ()
56bb623 @roman Making a Main.hs that will wrap the HaskBan.hs module
roman authored
16
b5282da @roman Updating to the last 'working' version
roman authored
17 readSokobanInfo :: IO SokobanInfo
18 readSokobanInfo = (getSokobanInfo . (!0) . parseSokoMaps) `liftM` (BS.readFile "input.in")
Something went wrong with that request. Please try again.