Refactor inventory management, add tweak, combine and inspect modes
This commit is contained in:
+14
-1
@@ -96,7 +96,14 @@ data World = World
|
||||
, _sideEffects :: [PreloadData SoundOrigin -> IO (PreloadData SoundOrigin)]
|
||||
, _doneSideEffects :: [PreloadData SoundOrigin -> IO (PreloadData SoundOrigin)]
|
||||
, _debugFlags :: DebugFlags
|
||||
, _inventoryMode :: InventoryMode
|
||||
}
|
||||
data InventoryMode
|
||||
= TopInventory
|
||||
| TweakInventory
|
||||
| CombineInventory
|
||||
| InspectInventory
|
||||
deriving (Eq, Ord, Show)
|
||||
data CrGroupParams = CrGroupParams
|
||||
{ _crGroupParamID :: Int
|
||||
, _crGroupIDs :: IS.IntSet
|
||||
@@ -390,13 +397,19 @@ data Ammo
|
||||
= ShellAmmo
|
||||
{ _amPayload :: Point2 -> World -> World
|
||||
, _amString :: String
|
||||
, _amPjMove :: Item -> Creature -> [Projectile -> World -> World]
|
||||
, _amPjMove :: [PjParam]
|
||||
, _amPjDraw :: Projectile -> Picture
|
||||
, _amParamSel :: Int
|
||||
}
|
||||
| BulletAmmo
|
||||
{ _amString :: String
|
||||
}
|
||||
| GenericAmmo
|
||||
data PjParam = PjParam
|
||||
{ _pjMoveParam :: Int -> Item -> Creature -> Projectile -> World -> World
|
||||
, _pjIntParam :: Int
|
||||
, _pjDisplayParam :: Int -> String
|
||||
}
|
||||
data Projectile
|
||||
= Projectile
|
||||
{ _pjPos :: Point2
|
||||
|
||||
Reference in New Issue
Block a user