mwg API
    Preparing search index...

    Interface HeuristicCandidate<A>

    interface HeuristicCandidate<A = unknown> {
        action: A;
        can_recruit?: boolean;
        factors?: Readonly<Record<string, number>>;
        id: string;
        name?: string;
        role?: string;
        type?: string;
        unit?: string;
    }

    Type Parameters

    • A = unknown
    Index
    action: A
    can_recruit?: boolean

    whether the acting unit can recruit

    factors?: Readonly<Record<string, number>>

    Aspect-named weights this candidate contributes, e.g. { aggression: 3, village_value: 2 }. distance is special: with a keep_away aspect it is penalised by keepAwayScore.

    id: string

    an id for tracing which candidate won

    name?: string

    the acting unit's own name

    role?: string

    the acting unit's role/function, e.g. leader or courier

    type?: string

    the acting unit's type, when the candidate carries one

    unit?: string

    the unit the action belongs to, matched against Goals by a stage's own weigh