Separate out concrete part of world

This commit is contained in:
2022-07-25 12:10:50 +01:00
parent 3354d108be
commit b2efbd2b3e
134 changed files with 933 additions and 930 deletions
+3 -3
View File
@@ -86,12 +86,12 @@ fullModuleName :: ItemModuleType -> String
fullModuleName = fromMaybe "EMPTYMODULE" . moduleName
toggleCombineInv :: World -> World
toggleCombineInv w = case _hudElement (_hud w) of
DisplayInventory CombineInventory {} -> w & hud . hudElement .~ DisplayInventory NoSubInventory
toggleCombineInv w = case _hudElement (_hud (_cWorld w)) of
DisplayInventory CombineInventory {} -> w & cWorld . hud . hudElement .~ DisplayInventory NoSubInventory
_ -> w & enterCombineInv
enterCombineInv :: World -> World
enterCombineInv w = w & hud . hudElement .~ DisplayInventory (CombineInventory mi)
enterCombineInv w = w & cWorld . hud . hudElement .~ DisplayInventory (CombineInventory mi)
where
mi = 0 <$ listToMaybe (combineItemListYou w)