Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Main entry point for the console interface to the game.
Documentation
direction :: String -> Maybe Direction Source
Converts a string into a direction.
>>>
direction "\ESC[D"
Just West>>>
direction "<"
Nothing
getChars :: IO (Maybe String) Source
Gets up to three characters from standard input. If the input corresponds
to an arrow key, it will be returned. Otherwise Nothing
will be returned.
Will only consume enough input to determine if the input is an arrow key or
not.