Throw a couple of Show instance to ease debugging following the e0003c commit in lib
This commit is contained in:
parent
775abd3ac4
commit
57370d62ee
1 changed files with 4 additions and 4 deletions
|
@ -76,7 +76,7 @@ data FromClient =
|
||||||
| Play {move :: KoiKoi.Move, onGame :: PublicGame}
|
| Play {move :: KoiKoi.Move, onGame :: PublicGame}
|
||||||
| Quit
|
| Quit
|
||||||
| Ping
|
| Ping
|
||||||
deriving (Generic)
|
deriving (Generic, Show)
|
||||||
|
|
||||||
instance FromJSON FromClient
|
instance FromJSON FromClient
|
||||||
instance ToJSON FromClient where
|
instance ToJSON FromClient where
|
||||||
|
@ -146,7 +146,7 @@ instance ToJSON PrivateState where
|
||||||
data PublicPlayer = PublicPlayer {
|
data PublicPlayer = PublicPlayer {
|
||||||
meld :: Hanafuda.Pack
|
meld :: Hanafuda.Pack
|
||||||
, yakus :: KoiKoi.Score
|
, yakus :: KoiKoi.Score
|
||||||
} deriving Generic
|
} deriving (Generic, Show)
|
||||||
|
|
||||||
instance FromJSON PublicPlayer
|
instance FromJSON PublicPlayer
|
||||||
instance ToJSON PublicPlayer where
|
instance ToJSON PublicPlayer where
|
||||||
|
@ -166,7 +166,7 @@ data PublicState = PublicState {
|
||||||
, trick :: [Hanafuda.Card]
|
, trick :: [Hanafuda.Card]
|
||||||
, turns :: Int
|
, turns :: Int
|
||||||
, rounds :: [(PlayerID, KoiKoi.Score)]
|
, rounds :: [(PlayerID, KoiKoi.Score)]
|
||||||
} deriving Generic
|
} deriving (Generic, Show)
|
||||||
|
|
||||||
instance FromJSON PublicState
|
instance FromJSON PublicState
|
||||||
instance ToJSON PublicState where
|
instance ToJSON PublicState where
|
||||||
|
@ -184,7 +184,7 @@ data PublicGame = PublicGame {
|
||||||
, private :: ByteString
|
, private :: ByteString
|
||||||
, public :: PublicState
|
, public :: PublicState
|
||||||
, publicSignature :: ByteString
|
, publicSignature :: ByteString
|
||||||
} deriving Generic
|
} deriving (Generic, Show)
|
||||||
|
|
||||||
instance FromJSON PublicGame
|
instance FromJSON PublicGame
|
||||||
instance ToJSON PublicGame where
|
instance ToJSON PublicGame where
|
||||||
|
|
Loading…
Reference in a new issue