parent
5cc96cbdba
commit
f3bce99120
18 changed files with 289 additions and 103 deletions
|
@ -6,13 +6,11 @@ import RPGEngine.Data ( Game )
|
|||
import RPGEngine.Parse.StructureToGame ( structureToGame )
|
||||
import GHC.IO (unsafePerformIO)
|
||||
import Text.Parsec.String (parseFromFile)
|
||||
import RPGEngine.Parse.TextToStructure (structure)
|
||||
import RPGEngine.Parse.TextToStructure ( gameFile )
|
||||
|
||||
------------------------------ Exported ------------------------------
|
||||
|
||||
parse :: FilePath -> Game
|
||||
parse filename = structureToGame struct
|
||||
where (Right struct) = unsafePerformIO io
|
||||
io = parseFromFile structure filename
|
||||
|
||||
tempParse = parseFromFile
|
||||
io = parseFromFile gameFile filename
|
Reference in a new issue