Move towards implementing wrist shields
This commit is contained in:
@@ -145,7 +145,9 @@ useUpdate = (useHammer . hammerPosition %~ moveHammerUp)
|
||||
. (useDelay . rateTime %~ decreaseToZero)
|
||||
|
||||
useEquipment :: Creature -> Int -> World -> World
|
||||
useEquipment cr i = _eqUse (_itUse $ _crInv cr IM.! i) cr i
|
||||
useEquipment cr i = _eqUse (_itUse itm) itm cr
|
||||
where
|
||||
itm = _crInv cr IM.! i
|
||||
-- a map updating all inventory items
|
||||
upInv :: Creature -> World -> World
|
||||
upInv cr = creatures . ix (_crID cr) . crInv %~ IM.mapWithKey (itemUpdate cr)
|
||||
|
||||
Reference in New Issue
Block a user