/** * THE WEST COAST'S SIDE BRANCHES, shared shape (T88, 2026-10-14; plan `.cursor/task-plans/2026-10-14-t88-west-coast-branches.md`): the Shale Teeth (shaleTeeth.ts), the Reedwheel Fan * (reedwheelFan.ts) and the Knucklebone Isles (knuckleboneIsles.ts) are laid in the Western strip's second growth (constants.ts WESTERN_CHUNKS_X 30 -> 38, x 2496-2751) and in the * sea between the reaches and it. Each is one `WestBranchLayout`: a local frame (origin x0, z0), land polygons, holes, roads, bare-earth patches, shallow pools, terrace scarps, * kit pieces, signs, seams, stations, quest props, forage hints and the places a player is sent to. One generic backend placer (backend westBranch.ts) lays any of them, * so a branch is data. Every number inside a layout is a WORLD tile unless a function says "local". */ import type { LanternWakeBox, LanternWakePiece, LanternWakePoint } from './lanternWake.js'; import { type WesternPolygon } from './westernKingdoms.js'; import type { ForageKind } from './foragePatches.js'; export type WestBranchId = 'shale' | 'reedwheel' | 'knucklebone'; export type BranchPath = { id: string; w: number; pts: readonly LanternWakePoint[]; }; export type BranchSeam = { id: string; x: number; z: number; style: 'coal' | 'iron' | 'gold' | 'silver'; }; export type BranchStation = { id: string; kind: 'furnace' | 'anvil' | 'campfire'; x: number; z: number; }; export type BranchSign = { id: string; x: number; z: number; text: string; }; export type BranchQuestProp = { readonly id: string; readonly x: number; readonly z: number; readonly style: string; }; /** A forage patch hint: the placer takes the nearest sand or grass tile to it that is bare, walkable and has a tile to pick from. */ export type BranchForageHint = { id: string; x: number; z: number; forage: ForageKind; }; /** An entity a branch lays beside the kit's pieces: a skiff (`caveentrance`, style `hbrowboat-`) or a dig mound. */ /** A cable ferry skiff: a click on `id`'s entity (a `caveentrance`, style `hbrowboat-`) carries the player to dest (same region: no cover). */ export type BranchFerry = { id: string; x: number; z: number; style: string; destX: number; destZ: number; name: string; label: string; text: string; }; export type BranchEntity = { id: string; kind: string; x: number; z: number; style: string; scale?: number; }; export type WestBranchLayout = { id: WestBranchId; name: string; /** The local frame's origin: local (0, 0) is this world tile. */ x0: number; z0: number; /** The branch's whole box (its discovery zone, the claim on the program board), world tiles. */ box: LanternWakeBox; /** The land's ground height and its two beach steps down to the sea. */ groundHeight: number; beachHeights: readonly [number, number]; /** Land, local coordinates: every polygon is land; every hole is carved back to water. */ land: readonly WesternPolygon[]; holes: readonly WesternPolygon[]; /** * World boxes of land the branch joins at its edge (the Redclay Hook's east coast, Saltmere's): counted as land for the beach rings so the join has no * sand step across it. They are not laid by the branch (the reach's own placer laid them). */ attach: readonly LanternWakeBox[]; /** The height of a land tile in the interior (local), e.g. the Shale Teeth's terraces. Absent: `groundHeight` everywhere. */ heightAt?: (lx: number, lz: number) => number; paths: readonly BranchPath[]; /** Bare-earth patches (laid as Dirt), world boxes. */ dirt: readonly LanternWakeBox[]; /** Shallow pools inside the land (water, a little below the ground), world boxes. */ pools: readonly LanternWakeBox[]; /** How far a pool sits below its ground. */ poolDepth: number; /** Terrace scarps: rows of blocked stone across the land (roads cross them through gaps), world boxes. */ scarps: readonly LanternWakeBox[]; pieces: readonly LanternWakePiece[]; signs: readonly BranchSign[]; seams: readonly BranchSeam[]; stations: readonly BranchStation[]; questProps: readonly BranchQuestProp[]; forage: readonly BranchForageHint[]; /** Extra entities (skiffs, dig mounds) the placer lays as they are. */ entities: readonly BranchEntity[]; /** Ground cut off from the rest by water (a quest or a skill spot on it is reached by a ferry): its box and where the ferry lands. */ detached: ReadonlyArray<{ id: string; box: LanternWakeBox; landing: { x: number; z: number; }; }>; /** The cable ferries (each end is its own entry; the skiff entities are in `entities`). */ ferries: readonly BranchFerry[]; /** Fixed tide snapper spot hints (the backend takes the nearest water tile with standable ground within two tiles). */ fishHints: readonly { x: number; z: number; }[]; /** The standing places a smoke, a teleport and a person's tile can rely on. */ stands: Readonly>; /** What to look at from each stand (the admin teleport links' notes), by stand name. */ standNotes: Readonly>; /** Scatter chances per land tile. */ scatter: { tree: number; rock: number; tuft: number; reed: number; treeStyle: string; }; /** The counter one of its people keeps (the person's FairFolkId, the shop's title, what it sells and buys: existing goods at the other traders' prices). */ shop?: { person: string; title: string; stock: ReadonlyArray<{ kind: string; price: number; }>; buys: Readonly>; }; /** What the game guide says of the branch (backend westBranchGuide.ts builds the page's text from it and the data). */ guide: { levels: string; /** How a player gets there, in a sentence or two. */ how: string; /** What lies there, in a sentence or two. */ places: string; /** Where each person stands, by FairFolkId. */ peopleAt: Readonly>; /** The quest ids in chain order. */ questLine: readonly string[]; /** Where each creature kind is found. */ creatureAt: Readonly>; }; /** Sub-zones for the discovery cards, smallest first. */ zones: readonly { id: string; label: string; box: LanternWakeBox; }[]; }; /** A branch's local frame. */ export declare function branchFrame(x0: number, z0: number): { at: (lx: number, lz: number) => { x: number; z: number; }; pt: (lx: number, lz: number) => LanternWakePoint; pts: (list: ReadonlyArray) => LanternWakePoint[]; box: (a: number, b: number, c: number, d: number) => LanternWakeBox; local: (x: number, z: number) => { x: number; z: number; }; }; /** Is the world tile land of this layout (inside a land polygon, outside every hole)? */ export declare function inBranchLand(layout: WestBranchLayout, x: number, z: number): boolean; export declare function inBranchBox(layout: WestBranchLayout, x: number, z: number, pad?: number): boolean; export declare function inBox(b: LanternWakeBox, x: number, z: number, pad?: number): boolean; /** What a branch's creature table row holds (the same shape as the reaches' tables). */ export type BranchCreature = { name: string; level: readonly [number, number]; maxHit: number; healthScale: number; scale: number; note: string; }; export type BranchWildlifeSpot = { readonly kind: string; readonly x: number; readonly z: number; readonly leash: number; }; export type BranchPace = { speed: number; idleChance: number; pause: readonly [number, number]; }; export type BranchDrop = { itemKind: string; chance: number; minQty: number; maxQty: number; }; //# sourceMappingURL=westBranch.d.ts.map