This repository has been archived on 2023-06-24. You can view files and clone it, but you cannot make any changes to it's state, such as pushing and creating new issues, pull requests or comments.
2022FuncProg-project3-RPGEn.../lib/RPGEngine/Input/Win.hs

16 lines
No EOL
434 B
Haskell

module RPGEngine.Input.Win
( handleInputWin
) where
import RPGEngine.Input.Core (InputHandler, handleAnyKey)
import RPGEngine.Data (Game (..), State (Menu))
------------------------------ Exported ------------------------------
handleInputWin :: InputHandler Game
handleInputWin = handleAnyKey goToMenu
----------------------------------------------------------------------
goToMenu :: Game -> Game
goToMenu g = g{ state = Menu }