seatOffunction
The seat holding stone right now. Swaps move seats between colours.
Import it
import { seatOf } from "@johnmorrisdotca/narabe";
Definition
function seatOf(state: GameState, stone: Stone): Seat
Parameters
| Name | Type | Description |
|---|---|---|
state | GameState | The current immutable game position. |
stone | Stone | The black or white colour being examined. |
Returns
Seat
The seat holding stone right now. Swaps move seats between colours.
Examples
import { createGame, seatOf } from "@johnmorrisdotca/narabe";
const state = createGame({variant:"freestyle",size:15});
console.log(seatOf(state,"black"));oneWhat it prints (run when this page was built)