feat(pong): detect when the client hasnt sent anything in X secs
This commit is contained in:
parent
613bb31100
commit
8eac0a0d4e
5 changed files with 61 additions and 13 deletions
|
|
@ -48,7 +48,7 @@ export interface ServerToClient {
|
|||
updateInformation: (info: UpdateInfo) => void,
|
||||
newGame: (initState: GameUpdate) => void, // <- consider this the gameProc eg not start of game but wait for client to "ready up"
|
||||
gameUpdate: (state: GameUpdate) => void,
|
||||
gameEnd: () => void;
|
||||
gameEnd: (winner: 'left' | 'right') => void;
|
||||
};
|
||||
|
||||
export type SSocket = Socket<ClientToServer, ServerToClient>;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue