Add Binary instances

This commit is contained in:
2022-08-21 10:58:19 +01:00
parent 386a2b4732
commit 1ce7d4a72d
95 changed files with 345 additions and 3 deletions
+3
View File
@@ -5,6 +5,7 @@
module Dodge.Data.Corpse where
import Data.Binary
import Flat
import LinearHelp ()
import Control.Lens
@@ -15,6 +16,7 @@ import ShapePicture.Data
data CorpseResurrection = NoResurrection
deriving (Eq, Ord, Show, Read, Generic, Flat)
instance Binary CorpseResurrection
data Corpse = Corpse
{ _cpID :: Int
@@ -24,6 +26,7 @@ data Corpse = Corpse
, _cpRes :: CorpseResurrection
}
deriving (Eq, Ord, Show, Read, Generic, Flat)
instance Binary Corpse
makeLenses ''Corpse
deriveJSON defaultOptions ''CorpseResurrection