Skip to content

RefDef beta ​

TypeAlias of @v12-engine/client

ts
export type RefDef = {
    name: string;
} | {
    param: string;
} | {
    query: {
        type?: string;
        owner?: 'me' | 'enemy' | number;
        near?: string | RefDef;
        within?: number;
        nearest?: boolean | string | RefDef;
        name?: string;
    };
} | {
    region: string;
} | {
    camera: string;
} | {
    code: string;
};

How a cinematic finds a thing it talks of by name (refs.hero): a unit named on the map, a param, the unit that answers a query of the game's state, a region's centre, a camera of the map, or code of the view's (A5 resolves them, when they are asked for, so the unit nearest the gate when the clip runs is the one taken)