Add Binary instances
This commit is contained in:
@@ -5,6 +5,7 @@
|
||||
|
||||
module Dodge.Data.HUD where
|
||||
|
||||
import Data.Binary
|
||||
import Flat
|
||||
import LinearHelp ()
|
||||
import Control.Lens
|
||||
@@ -16,6 +17,7 @@ data HUDElement
|
||||
= DisplayInventory {_subInventory :: SubInventory}
|
||||
| DisplayCarte
|
||||
deriving (Eq, Ord, Show, Read, Generic, Flat)
|
||||
instance Binary HUDElement
|
||||
|
||||
data SubInventory
|
||||
= NoSubInventory
|
||||
@@ -25,6 +27,7 @@ data SubInventory
|
||||
| LockedInventory
|
||||
| DisplayTerminal {_termID :: Int}
|
||||
deriving (Eq, Ord, Show, Read, Generic, Flat)
|
||||
instance Binary SubInventory
|
||||
|
||||
data HUD = HUD
|
||||
{ _hudElement :: HUDElement
|
||||
@@ -33,6 +36,7 @@ data HUD = HUD
|
||||
, _carteRot :: Float
|
||||
}
|
||||
deriving (Eq, Ord, Show, Read, Generic, Flat)
|
||||
instance Binary HUD
|
||||
|
||||
makeLenses ''HUD
|
||||
makeLenses ''HUDElement
|
||||
|
||||
Reference in New Issue
Block a user