import type { MmaFigures } from "../leagues/combat.ts"; import { type MBox, type MMark, type Parts } from "./parts.ts"; /** One gate of the cage: the flat it is in, the two ends of its opening, and the way it opens (outward). */ export interface CageGate { side: "north" | "south"; /** The number of the flat it is in, counted from the first corner. */ flat: number; from: readonly [number, number]; to: readonly [number, number]; } /** What a cage plan is. */ export interface CageLayout { parts: Parts; /** The platform, which is the surface's own box: the cage's canvas and the apron round it. */ platform: MBox; extent: MBox; centre: [number, number]; /** The cage's width across the flats, and the distance from its middle to a post. */ width: number; apothem: number; corner: number; /** The posts, one at each corner of the cage, as points on the platform. */ posts: [number, number][]; /** The gates, and the steps (the boxes outside the platform's edge, where a gate faces). */ gates: CageGate[]; steps: MBox[]; /** The height of the platform over the floor of the building and of the fence over the canvas, in metres. */ height: number; fence: number; marks: MMark[]; ranges: Record; } /** The width the options ask for, held to 20 feet to 32 feet. */ export declare const cageWidth: (asked: number | undefined, fig: MmaFigures) => number; /** The platform's height the options ask for, held to 0 to 4 feet. */ export declare const cageHeight: (asked: number | undefined, fig: MmaFigures) => number; /** The fence's height the options ask for, held to 5 feet to 7 feet. */ export declare const fenceHeight: (asked: number | undefined, fig: MmaFigures) => number; /** The plan of the cage the options ask for. */ export declare function cageParts(fig: MmaFigures, o: { width: number; height: number; fence: number; gates: boolean; steps: boolean; }): CageLayout;