Clash Blueprint Engine API
    Preparing search index...

    Interface RuleSet

    The parsed, indexed form of a rule pack that the validation engine consumes. Built once from JSON so validation is pure lookups, not repeated array scans.

    interface RuleSet {
        allowances: ReadonlyMap<string, BuildingAllowance>;
        gridSize: number;
        required: readonly RequiredBuilding[];
        spatial: readonly (
            | {
                metric: "chebyshev"
                | "manhattan"
                | "euclidean";
                minDistance: number;
                severity: "error" | "warning" | "suggestion";
                target: { id: string } | { category: string };
                type: "minSpacing";
            }
            | {
                buffer: number;
                severity: "error"
                | "warning"
                | "suggestion";
                target?: { id: string } | { category: string };
                type: "edgeBuffer";
            }
            | {
                severity: "error"
                | "warning"
                | "suggestion";
                target: { id: string } | { category: string };
                tolerance: number;
                type: "centered";
            }
            | {
                maxDistance: number;
                metric: "chebyshev"
                | "manhattan"
                | "euclidean";
                near: { id: string } | { category: string };
                severity: "error" | "warning" | "suggestion";
                target: { id: string } | { category: string };
                type: "proximity";
            }
        )[];
        tier: number;
        wallLimit: number;
    }
    Index
    allowances: ReadonlyMap<string, BuildingAllowance>
    gridSize: number
    required: readonly RequiredBuilding[]
    spatial: readonly (
        | {
            metric: "chebyshev"
            | "manhattan"
            | "euclidean";
            minDistance: number;
            severity: "error" | "warning" | "suggestion";
            target: { id: string } | { category: string };
            type: "minSpacing";
        }
        | {
            buffer: number;
            severity: "error"
            | "warning"
            | "suggestion";
            target?: { id: string } | { category: string };
            type: "edgeBuffer";
        }
        | {
            severity: "error"
            | "warning"
            | "suggestion";
            target: { id: string } | { category: string };
            tolerance: number;
            type: "centered";
        }
        | {
            maxDistance: number;
            metric: "chebyshev"
            | "manhattan"
            | "euclidean";
            near: { id: string } | { category: string };
            severity: "error" | "warning" | "suggestion";
            target: { id: string } | { category: string };
            type: "proximity";
        }
    )[]

    Optional geometric constraints; empty for packs that declare none.

    tier: number
    wallLimit: number