mwg API
    Preparing search index...

    Interface UnitSelectorOptions

    interface UnitSelectorOptions {
        canTarget?: (
            attacker: SelectableUnit,
            target: SelectableUnit,
        ) => boolean;
        disabled?: (unit: SelectableUnit) => boolean;
        side?: string;
        units: readonly SelectableUnit[];
    }
    Index
    canTarget?: (attacker: SelectableUnit, target: SelectableUnit) => boolean

    narrows the targets once an attacker is chosen (adjacency, range, fog)

    disabled?: (unit: SelectableUnit) => boolean

    further narrows who may be chosen at all (a unit that has already acted, say)

    side?: string

    only units on this side may attack; every enabled unit when omitted

    units: readonly SelectableUnit[]