Attempt to make CWorld correct instance of Store
This commit is contained in:
@@ -6,6 +6,8 @@ module Dodge.Data.Item.Effect where
|
||||
import Control.Lens
|
||||
import Data.Aeson
|
||||
import Data.Aeson.TH
|
||||
import TH.Derive
|
||||
import Data.Store
|
||||
|
||||
data ItEffect = ItEffect
|
||||
{ _ieInv :: ItInvEffect --Item -> Creature -> World -> World
|
||||
@@ -27,9 +29,11 @@ data ItInvEffect
|
||||
deriving (Eq, Ord, Show, Read)
|
||||
|
||||
data ItFloorEffect = NoFloorEffect
|
||||
| DefaultFloorEffect
|
||||
deriving (Eq, Ord, Show, Read)
|
||||
|
||||
data ItDropEffect = NoDropEffect
|
||||
| DefaultDropEffect
|
||||
deriving (Eq, Ord, Show, Read)
|
||||
|
||||
makeLenses ''ItEffect
|
||||
@@ -37,3 +41,7 @@ deriveJSON defaultOptions ''ItEffect
|
||||
deriveJSON defaultOptions ''ItInvEffect
|
||||
deriveJSON defaultOptions ''ItFloorEffect
|
||||
deriveJSON defaultOptions ''ItDropEffect
|
||||
$($(derive [d| instance Deriving (Store ItEffect) |]))
|
||||
$($(derive [d| instance Deriving (Store ItInvEffect) |]))
|
||||
$($(derive [d| instance Deriving (Store ItFloorEffect) |]))
|
||||
$($(derive [d| instance Deriving (Store ItDropEffect) |]))
|
||||
|
||||
Reference in New Issue
Block a user