import type { Cell, GameSettings, VariantSpec } from "../types.ts"; import type { RockLayout, RockRules } from "./rocks.types.ts"; /** * The obstacle games' furniture as rules to tune. * * Obstacle Five scatters six dead points and two hotspots, and nothing says * why six or why two. John, 2026-09-16: make the numbers parameters, playtest * every combination with the computer players, and name only the two or three * that play well. So this module lays out rocks from a `RockRules` and a seed, * and lands them on a board — at the start or partway through — and decides * nothing about which combinations are games. `obstacles.playtest.test.ts` * is what asks that, and the two it named are rows in `VARIANT_SPECS` with a * `rocks` field: Scattered Rocks and Rockfall. */ /** A rock game's rules, read off its spec, or null for a game with no rocks. */ export declare function rockRulesOf(spec: VariantSpec): RockRules | null; /** * Where this game's rocks and hotspots go, from its own seed, or null for a * game with no rocks — or rules its board cannot hold, which * `rocks.test.ts` refuses for every board a rock game is offered on. */ export declare function rockLayoutFor(settings: GameSettings): RockLayout | null; /** * Where a game's rocks and hotspots go, from its seed, or null when the rules * cannot be laid out on this board: a garden whose rocks do not divide by four * or whose hotspots do not pair, or more furniture than the board has room for. * Null rather than a best effort, because a layout quietly short of what the * rules asked for would be playtested as though it were what they asked for. * * The centre point is never furniture, as with the star-point layout: the * middle of the board stays contestable. */ export declare function rockLayout(rules: RockRules, size: number, seed: number): RockLayout | null; /** * A board with the layout's furniture landed on it, as a new board. A rock or * hotspot falling on a point a stone already holds is lost: the stone stays. * That only happens when the rocks arrive mid-game, and it is the choice that * never takes a stone off the board by chance. */ export declare function landRocks(board: readonly Cell[], size: number, layout: RockLayout): Cell[];