No need to separate connection and logIn now that names are non-unique and the PlayerID is known from the start
This commit is contained in:
parent
9c5c80fb3a
commit
775abd3ac4
1 changed files with 2 additions and 3 deletions
|
@ -68,11 +68,10 @@ instance ToJSON Hanafuda.Card where
|
||||||
toEncoding = genericToEncoding defaultOptions
|
toEncoding = genericToEncoding defaultOptions
|
||||||
|
|
||||||
data FromClient =
|
data FromClient =
|
||||||
Hello
|
Hello {name :: Text}
|
||||||
| Tadaima {myID :: PlayerID}
|
| Tadaima {myID :: PlayerID, name :: Text}
|
||||||
| Answer {accept :: Bool, to :: PlayerID}
|
| Answer {accept :: Bool, to :: PlayerID}
|
||||||
| Invitation {to :: PlayerID}
|
| Invitation {to :: PlayerID}
|
||||||
| LogIn {name :: Text}
|
|
||||||
| LogOut
|
| LogOut
|
||||||
| Play {move :: KoiKoi.Move, onGame :: PublicGame}
|
| Play {move :: KoiKoi.Move, onGame :: PublicGame}
|
||||||
| Quit
|
| Quit
|
||||||
|
|
Loading…
Reference in a new issue