diff --git a/jecs.d.ts b/jecs.d.ts index 597840d..08f2b9a 100644 --- a/jecs.d.ts +++ b/jecs.d.ts @@ -4,7 +4,7 @@ * and cannot be used used as a component to associate any kind of data with itself. */ export type Id = number & { - readonly __nominal_Id: unique symbol, + readonly __nominal_Id: unique symbol; }; /* @@ -24,6 +24,7 @@ export type Tag = Id & { */ export type Entity = Tag & { readonly __nominal_Entity: unique symbol; + readonly __type_TData: TData; }; type InferComponent = TValue extends Entity ? TData : never; @@ -133,7 +134,7 @@ export class World { * @param component Target Component * @param value Component Value */ - set(entity: Id, component: TComponent, value: InferComponent>): void; + set(entity: Id, component: Entity, value: NoInfer): void; /** * Removes a component from the given entity