Go back to JSON encoding

This commit is contained in:
2022-08-21 21:23:59 +01:00
parent dd62e30026
commit f1ef75f511
95 changed files with 9 additions and 586 deletions
-6
View File
@@ -11,9 +11,6 @@ module Dodge.Data.Item.Use.Consumption (
module Dodge.Data.Item.Use.Consumption.LoadAction,
) where
import TH.Derive
import Data.Store
import Data.Binary
import Flat
import Control.Lens
import Data.Aeson
@@ -32,7 +29,6 @@ data HeldConsumption
}
| NoConsumption
deriving (Eq, Show, Read, Generic, Flat)
$($(derive [d| instance Deriving (Store HeldConsumption) |]))
data LeftConsumption
= AutoRecharging
@@ -46,14 +42,12 @@ data LeftConsumption
, _wpCharge :: Int
}
deriving (Eq, Show, Read, Generic, Flat)
$($(derive [d| instance Deriving (Store LeftConsumption) |]))
newtype ItAmount = ItAmount {_getItAmount :: Int}
-- deriving (Eq, Ord, Read, Show, Num, Real, Generic, Flat)
deriving newtype (Eq, Ord, Read, Show, Num, Real, Enum, Integral)
deriving stock (Generic)
deriving anyclass (Flat)
$($(derive [d| instance Deriving (Store ItAmount) |]))
makeLenses ''HeldConsumption
makeLenses ''LeftConsumption