Move equip effect on remove out of record
This commit is contained in:
@@ -4,6 +4,7 @@ module Dodge.Creature.Impulse.UseItem (
|
||||
useItem,
|
||||
) where
|
||||
|
||||
import Dodge.Equipment
|
||||
import Control.Lens
|
||||
import Data.Maybe
|
||||
import Dodge.Data.ComposedItem
|
||||
@@ -127,7 +128,8 @@ toggleEquipmentAt invid cr w = case getEquipmentAllocation invid w of
|
||||
itmat i = _crInv cr IM.! i
|
||||
itm = itmat invid
|
||||
onequip itm' = doItmCrWdWd ((_eeOnEquip . _uequipEffect . _itUse) itm') itm'
|
||||
onremove itm' = doItmCrWdWd ((_eeOnRemove . _uequipEffect . _itUse) itm') itm'
|
||||
--onremove itm' = doItmCrWdWd ((_eeOnRemove . _uequipEffect . _itUse) itm') itm'
|
||||
onremove itm' = effectOnRemove itm'
|
||||
|
||||
toggleExamineInv :: World -> World
|
||||
toggleExamineInv w = case w ^? hud . hudElement . subInventory of
|
||||
|
||||
Reference in New Issue
Block a user