import * as a1lib from "alt1/base"; import ActionbarReader, { LifeState } from "./actionbar"; import { Rect } from "alt1/base"; export { default as ActionbarReader, LifeState } from "./actionbar"; export interface AbilityInfoBare { id: string; icon: ImageData; cooldown: number; } type AbilBarId = "bar0" | "bar1" | "bar2" | "bar3" | "bar4"; type CaptAreas = Partial<{ [T in AbilBarId]: a1lib.RectLike; }>; export default class AbilityReader { bars: AbilityBar[]; mainbar: AbilityBar | null; barstates: { [name: string]: AbilityLoadout; }; captureRect: a1lib.Rect | null; actionbarReader: ActionbarReader; abilityimgs: T[] | null; lifestate: LifeState; hooks: { onbarshown: ((bar: AbilityLoadout) => any) | null; }; static imgs: { smallbarnumber: ImageData | null; settingscog: ImageData | null; }; constructor(abilityimgs: T[]); find(img?: a1lib.ImgRef): number | null; getCaptAreas(): Partial<{ bar0: a1lib.RectLike; bar1: a1lib.RectLike; bar2: a1lib.RectLike; bar3: a1lib.RectLike; bar4: a1lib.RectLike; }>; /** * @deprecated kinda needs rewrite to be efficient, use readallslotsinner manually instead * @param img */ readAllSlots(img?: a1lib.ImgRef): void; readAllSlotsInner(capts: Partial<{ [T in AbilBarId]: ImageData | null; }>, captareas: CaptAreas): void; finishTick(): void; readLife(buffer: ImageData, bufx: number, bufy: number): LifeState | null; overlayState(): void; visibleAbilities(): Generator, void, undefined>; allAbilities(): Generator, void, undefined>; mainbarAbilities(): Generator, void, undefined>; allslots(): Generator, void, undefined>; } interface AbilityBarTypeMeta { sec: boolean; step: { x: number; y: number; }; rowstep: { x: number; y: number; }; rowlen: number; length: number; detect: { x: number; y: number; }; cog?: { x: number; y: number; }; action?: { x: number; y: number; }; num: { x: number; y: number; }; id: string; } declare class AbilityBarSlot { x: number; y: number; index: number; bar: AbilityBar; constructor(x: number, y: number, index: number, bar: AbilityBar); getState(): AbilityState; } interface AbilityLoadout { barid: string; visible: boolean; slots: AbilityState[]; } declare class AbilityBar { static types: { [key: string]: AbilityBarTypeMeta; }; x: number; y: number; bounds: Rect; barid: string; slots: AbilityBarSlot[]; layout: AbilityBarTypeMeta; barstates: { [id: string]: AbilityLoadout; }; reader: AbilityReader; constructor(reader: AbilityReader, x: number, y: number, layout: AbilityBarTypeMeta, barstates: { [id: string]: AbilityLoadout; }); readBarNr(buffer: ImageData, bufx: number, bufy: number): string; overlay(): void; } export declare class AbilityState { static iconwidth: number; static iconheight: number; static overlayState: boolean; nextdetecttry: number; lastcooldown: number; lasttickcooldown: number; tickcooldown: number; cdchange: number; gcd: boolean; donetime: number; hadcd: boolean; cooldown: number; available: boolean; cdfraction: number; ability: T | null; hotkey: string; reader: AbilityReader | null; constructor(reader: AbilityReader); readAbility(data: ImageData, x: number, y: number): void; confirmCdArea(buffer: ImageData, x: number, y: number): boolean; debug: ImageData | null; readClock(buf: ImageData, abilx: number, abily: number): void; readhotkey(buf: ImageData, abilx: number, abily: number): void; overlayState(x: number, y: number): void; getAbility(buf: ImageData, abilx: number, abily: number): T | null; } //# sourceMappingURL=index.d.ts.map