import { Component } from './Component'; import { ComponentMap } from './EntityHandle'; export interface EntityProp { id: string; components?: ComponentMap; bitmask: number; } export interface EntityDecoratorComponent { component: { new (config?: { [x: string]: any; }): any; }; config?: { [x: string]: any; }; } export interface Entity extends EntityProp { get(comp: { new (...args: any[]): T; } | string): T; getAll(): { [id: string]: Component; }; has(comp: { new (...args: any[]): T | Component | object; } | string): boolean; add(component: T | Component | object): void; remove(component: { new (...args: any[]): T | Component | object; } | string): boolean; dispose(): this; }