isaac-typescript-definitions
Version:
TypeScript definitions for The Binding of Isaac: Repentance.
52 lines • 1.49 kB
TypeScript
/**
* This is represented as an object instead of an enum due to limitations with TypeScript enums. (We
* want this type to be a child of the `BitFlag` type.)
*
* @enum
* @notExported
* @rename TargetFlag
*/
declare const TargetFlagInternal: {
/**
* Allow switching to a better target even if we already have one.
*
* 1 << 0 (1)
*/
readonly ALLOW_SWITCHING: number;
/**
* Do not prioritize enemies that are close to the familiar's owner.
*
* 1 << 1 (2)
*/
readonly DONT_PRIORITIZE_ENEMIES_CLOSE_TO_PLAYER: number;
/**
* Prioritize enemies with higher HP.
*
* 1 << 2 (4)
*/
readonly PRIORITIZE_ENEMIES_WITH_HIGH_HP: number;
/**
* Prioritize enemies with higher HP.
*
* 1 << 3 (8)
*/
readonly PRIORITIZE_ENEMIES_WITH_LOW_HP: number;
/**
* Give a lower priority to our current target. (This makes it more likely for the familiar to
* switch between targets.)
*
* 1 << 4 (16)
*/
readonly GIVE_LOWER_PRIORITY_TO_CURRENT_TARGET: number;
};
type TargetFlagValue = BitFlag & {
readonly __targetFlagBrand: symbol;
};
type TargetFlagType = {
readonly [K in keyof typeof TargetFlagInternal]: TargetFlagValue;
};
export declare const TargetFlag: TargetFlagType;
export type TargetFlag = TargetFlagType[keyof TargetFlagType];
export declare const TargetFlagZero: BitFlags<TargetFlagValue>;
export {};
//# sourceMappingURL=TargetFlag.d.ts.map