restartGamefunction
Restarts the same seed/date or original witnessed challenge board and queue.
Import it
import { restartGame } from "@johnmorrisdotca/houseki/colour-chains";
Definition
function restartGame(state: GameState): GameState
Parameters
| Name | Type | Description |
|---|---|---|
state | GameState | The immutable native state to read or transition; the input is retained. |
Returns
GameState
Restarts the same seed/date or original witnessed challenge board and queue.
Examples
import { createGame, restartGame } from "@johnmorrisdotca/houseki/colour-chains";
const state=createGame({seed:"docs"});
console.log(restartGame(state).phase);fallingWhat it prints (run when this page was built)