Extend inv item location information to include "attached" items
This commit is contained in:
@@ -21,11 +21,11 @@ data ItInvEffect
|
||||
| ChargeIfEquipped
|
||||
| ChargeIfInInventory
|
||||
| SetCharge Int
|
||||
| EffectIfHeld ItInvEffect ItInvEffect
|
||||
| EffectRootNotroot ItInvEffect ItInvEffect
|
||||
| CreateHeldLight
|
||||
| CreateShieldWall
|
||||
| RemoveShieldWall
|
||||
| EffectWhileHeld ItInvEffect
|
||||
| EffectWhileRoot ItInvEffect
|
||||
deriving (Eq, Ord, Show, Read) --Generic, Flat)
|
||||
|
||||
data ItFloorEffect = NoFloorEffect
|
||||
|
||||
@@ -23,7 +23,13 @@ data CrInt = CrInt
|
||||
deriving (Eq,Ord,Show,Read)
|
||||
|
||||
data ItemLocation
|
||||
= InInv {_ilCrID :: Int, _ilInvID :: Int, _ilIsRoot :: Bool, _ilIsSelected :: Bool}
|
||||
= InInv
|
||||
{ _ilCrID :: Int
|
||||
, _ilInvID :: Int
|
||||
, _ilIsRoot :: Bool
|
||||
, _ilIsSelected :: Bool
|
||||
, _ilIsAttached :: Bool
|
||||
}
|
||||
| OnTurret {_ilTuID :: Int}
|
||||
| OnFloor {_ilFlID :: NewInt FloorInt}
|
||||
| InVoid
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
module Dodge.Data.Item.Use.Consumption.LoadAction where
|
||||
|
||||
import qualified Data.IntSet as IS
|
||||
import Control.Lens
|
||||
import Data.Aeson
|
||||
import Data.Aeson.TH
|
||||
@@ -30,7 +31,11 @@ data NearbyManipulation
|
||||
|
||||
data InventoryManipulation
|
||||
= SortInventory
|
||||
| SelectedItem { _imSelectedItem :: Int, _imRootItem :: Int}
|
||||
| SelectedItem
|
||||
{ _imSelectedItem :: Int
|
||||
, _imRootItem :: Int
|
||||
, _imAttachedItems :: IS.IntSet
|
||||
}
|
||||
deriving (Eq, Ord, Show, Read) --Generic, Flat)
|
||||
|
||||
data InvSelAction
|
||||
|
||||
Reference in New Issue
Block a user