stackUpMovesfunction
Every move the seat to play may make: each card that fits a building pile, from the hand, the stock or a discard pile; each card of the hand on each discard pile; and a pass when the hand is empty.
Import it
import { stackUpMoves } from "@johnmorrisdotca/toranpu/stack-up";
Definition
function stackUpMoves(game: StackUpGame): StackUpMove[]
Parameters
| Name | Type | Description |
|---|---|---|
game | StackUpGame | The current native game; applying a move returns a new state. |
Returns
StackUpMove[]
Every move the seat to play may make.
Examples
import { stackUpMoves, startStackUp } from "@johnmorrisdotca/toranpu/stack-up";
console.log(stackUpMoves(startStackUp(15, ["Aki", "Ben"], undefined, 42)!).length);24What it prints (run when this page was built)