feat(ttt): added draw status in ttt match history
This commit is contained in:
parent
830f251537
commit
f87a991441
7 changed files with 36 additions and 17 deletions
|
|
@ -104,7 +104,8 @@
|
|||
"enum": [
|
||||
"winX",
|
||||
"winO",
|
||||
"other"
|
||||
"other",
|
||||
"draw"
|
||||
]
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@ const TTTHistoryResponse = {
|
|||
playerX: Type.Object({ id: Type.String(), name: Type.String() }),
|
||||
playerO: Type.Object({ id: Type.String(), name: Type.String() }),
|
||||
date: Type.String(),
|
||||
outcome: Type.Enum(['winX', 'winO', 'other']),
|
||||
outcome: Type.Enum(['winX', 'winO', 'other', 'draw']),
|
||||
}),
|
||||
),
|
||||
}),
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ export type GameUpdate = {
|
|||
|
||||
boardState: CellState[];
|
||||
currentPlayer: 'X' | 'O';
|
||||
gameState: 'winX' | 'winO' | 'concededX' | 'concededO' | 'draw' | 'ongoing';
|
||||
gameState: 'winX' | 'winO' | 'draw' | 'ongoing';
|
||||
}
|
||||
|
||||
export type GameMove = {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue