Commit before partial cleanup, continue weapon effect refactor
This commit is contained in:
@@ -62,9 +62,13 @@ stateUpdate f =
|
||||
, updateInv -- upInv must be called before invSideEff 22.05.23
|
||||
, invSideEff
|
||||
, equipmentEffects
|
||||
, heldItemEffects
|
||||
, heldAimEffects
|
||||
]
|
||||
|
||||
heldItemEffects :: Creature -> World -> World
|
||||
heldItemEffects _ = id
|
||||
|
||||
heldAimEffects :: Creature -> World -> World
|
||||
heldAimEffects cr = fromMaybe id $ do
|
||||
guard (crIsAiming cr)
|
||||
@@ -270,6 +274,8 @@ updateAutoRecharge it = case it ^? itUse . leftConsumption of
|
||||
| l < m -> it & itUse . leftConsumption . arProgress -~ 1
|
||||
_ -> it
|
||||
|
||||
--itemGetTargeting :: LabelDoubleTree ComposeLinkType Item
|
||||
|
||||
-- I feel like there should be a centralised function that supersumes this
|
||||
-- i.e. a function that deals with all states that depend upon item positioning
|
||||
-- in the inventory
|
||||
|
||||
Reference in New Issue
Block a user