跳转到内容

InferParam

此内容尚不支持你的语言。

InferParam<P> = P extends QueryDescriptor<infer C> ? QueryInstance<C> : P extends ResDescriptor<infer T> ? T : P extends ResMutDescriptor<infer T> ? ResMutInstance<T> : P extends CommandsDescriptor ? CommandsInstance : P extends EventWriterDescriptor<infer T> ? EventWriterInstance<T> : P extends EventReaderDescriptor<infer T> ? EventReaderInstance<T> : P extends RemovedQueryDescriptor<infer _T> ? RemovedQueryInstance<_T> : P extends GetWorldDescriptor ? World : never

Defined in: ecs/system.ts:106

One parameter’s declaration resolved to the value a system body receives. InferParams maps this over a whole list; a request this does not recognise resolves to never, which is what makes a bad parameter a type error at the definition rather than a surprise at the call.

P