Continue inventory tweak
This commit is contained in:
@@ -98,7 +98,7 @@ data Intention = Intention
|
||||
--deriving (Eq, Show, Read) --Generic, Flat)
|
||||
|
||||
crSel :: Creature -> ManipulatedObject
|
||||
crSel = _isel . _crManipulation
|
||||
crSel = _manObject . _crManipulation
|
||||
|
||||
makeLenses ''Creature
|
||||
makeLenses ''CreatureTargeting
|
||||
|
||||
@@ -19,17 +19,23 @@ data LoadAction
|
||||
|
||||
data Manipulation -- should be ManipulatedObject?
|
||||
-- = InvSel {_isel :: SelPos}
|
||||
= Manipulator {_isel :: ManipulatedObject}
|
||||
= Manipulator {_manObject :: ManipulatedObject
|
||||
, _invRegex :: Maybe String
|
||||
}
|
||||
| Brute
|
||||
deriving (Eq, Ord, Show, Read) --Generic, Flat)
|
||||
|
||||
data ManipulatedObject
|
||||
= SelItem { _ispItem :: Int
|
||||
, _iselAction :: InvSelAction}
|
||||
= InInventory {_inInventory :: InventoryManipulation}
|
||||
| SelNothing
|
||||
| SelCloseObject {_ispCloseObject :: Int}
|
||||
deriving (Eq, Ord, Show, Read) --Generic, Flat)
|
||||
|
||||
data InventoryManipulation
|
||||
= SortInventory
|
||||
| SelItem { _ispItem :: Int, _iselAction :: InvSelAction}
|
||||
deriving (Eq, Ord, Show, Read) --Generic, Flat)
|
||||
|
||||
data InvSelAction
|
||||
= NoInvSelAction
|
||||
| ReloadAction {_actionProgress :: Int, _reloadAction :: LoadAction}
|
||||
@@ -43,10 +49,12 @@ data LeftInvSel = LeftInvSel
|
||||
makeLenses ''LoadAction
|
||||
makeLenses ''ManipulatedObject
|
||||
makeLenses ''Manipulation
|
||||
makeLenses ''InventoryManipulation
|
||||
makeLenses ''LeftInvSel
|
||||
makeLenses ''InvSelAction
|
||||
deriveJSON defaultOptions ''LoadAction
|
||||
deriveJSON defaultOptions ''InvSelAction
|
||||
deriveJSON defaultOptions ''InventoryManipulation
|
||||
deriveJSON defaultOptions ''ManipulatedObject
|
||||
deriveJSON defaultOptions ''Manipulation
|
||||
deriveJSON defaultOptions ''LeftInvSel
|
||||
|
||||
@@ -57,7 +57,6 @@ data SelectionSection a = SelectionSection
|
||||
, _ssDescriptor :: String
|
||||
}
|
||||
|
||||
|
||||
data Regex = UnavailableRegex
|
||||
| EmptyRegex
|
||||
| Regex {_regexString :: String}
|
||||
|
||||
Reference in New Issue
Block a user