Work on inventory management
This commit is contained in:
+3
-3
@@ -6,6 +6,7 @@ Description : Simulation update
|
||||
-}
|
||||
module Dodge.Update (updateUniverse) where
|
||||
|
||||
import Dodge.InputFocus
|
||||
import Dodge.DisplayInventory
|
||||
import Dodge.ScrollValue
|
||||
import Color
|
||||
@@ -25,7 +26,7 @@ import Dodge.DrWdWd
|
||||
import Dodge.EnergyBall
|
||||
import Dodge.Flame
|
||||
import Dodge.Flare
|
||||
import Dodge.InputFocus
|
||||
--import Dodge.InputFocus
|
||||
import Dodge.Inventory
|
||||
import Dodge.Item.Location
|
||||
import Dodge.Laser.Update
|
||||
@@ -145,10 +146,9 @@ updateUseInput u = case u ^? uvScreenLayers . _head of
|
||||
Just (DisplayTerminal tmid) | inTermFocus (_uvWorld u) -> updateKeysInTerminal tmid u
|
||||
Just (CombineInventory sm)
|
||||
| inregex sm -> doSubInvRegexInput u
|
||||
_ | ininvregex -> doInvRegexInput u
|
||||
_ | inInvRegex (u ^. uvWorld) -> doInvRegexInput u
|
||||
_ -> M.foldlWithKey' updateKeyInGame u pkeys
|
||||
where
|
||||
ininvregex = False
|
||||
inregex sm = fromMaybe False $ do
|
||||
i <- sm ^? smSelPos . _Just
|
||||
si <- sm ^? smShownItems . ix i
|
||||
|
||||
Reference in New Issue
Block a user