import { IEntity, State, IAction } from './state'; export declare type Handler = (value: any, value2?: any) => void; export interface ISystem { start: (state: State) => void; stop: () => void; add: (entity: IEntity) => void; handles: (...components: string[]) => boolean; remove: (entity: IEntity) => void; update: (entity: IEntity, component: string) => void; configuration: (value: any) => void; has: (entity: IEntity | string) => boolean; tick: (delta: number) => void; watch: (components: { [key: string]: Handler; }) => void; } export declare const Config: (key: string) => (target: any, prop: string, description: PropertyDescriptor) => void; export declare const Component: (...keys: string[]) => (target: any, prop: string, description: PropertyDescriptor) => void; export interface ISystemConstructor { new (): ISystem; } export declare const Components: (...components: string[]) => (constructor: T) => void; export declare class System implements ISystem { protected component_handler: { [key: string]: Handler; }; protected config_handler: { [key: string]: Handler; }; protected config: any; protected state: State; protected entities: { [key: string]: IEntity; }; constructor(); handles(...components: string[]): boolean; watch(components: { [key: string]: Handler; }): void; configuration(config: any): void; start(state: State): void; stop(): void; update(entity: IEntity, component: string): void; add(entity: IEntity): void; remove(entity: IEntity): void; has(entity: IEntity | string): boolean; tick(delta: number): void; protected actions(actionMap: { [key: string]: (action: IAction) => void; }): void; protected dispatch(action: IAction, next?: boolean): void; }