Cleanup, stop assigning hotkeys to unequipped items
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
module Dodge.ItEffect where
|
||||
|
||||
import qualified IntMapHelp as IM
|
||||
import Control.Lens
|
||||
import Dodge.Data.World
|
||||
import Dodge.Euse
|
||||
@@ -49,7 +50,7 @@ chargeIfInInventory itm cr w =
|
||||
|
||||
chargeIfEquipped :: Item -> Creature -> World -> World
|
||||
chargeIfEquipped itm cr
|
||||
| Just invid == cr ^. crLeftInvSel . lisMPos =
|
||||
| invid `IM.member` (cr ^. crInvHotkeys) =
|
||||
ptrWpCharge %~ (min maxcharge . (+ 1))
|
||||
| otherwise = ptrWpCharge .~ 0
|
||||
where
|
||||
|
||||
Reference in New Issue
Block a user