QueryBuilder
此内容尚不支持你的语言。
Defined in: ecs/query.ts:257
A Query before it is handed to a system, narrowable by components the match must or must not have. Each call returns a NEW builder, so narrowing a shared query does not disturb it, and any of them is a valid parameter.
Extends
Section titled “Extends”Type Parameters
Section titled “Type Parameters”C extends readonly QueryArg[]
Methods
Section titled “Methods”filter()
Section titled “filter()”filter(
expr):QueryBuilder<C>
Defined in: ecs/query.ts:263
Attach a composable filter expression. Replaces any prior call.
Parameters
Section titled “Parameters”Returns
Section titled “Returns”QueryBuilder<C>
with()
Section titled “with()”with(…
components):QueryBuilder<C>
Defined in: ecs/query.ts:259
Match only entities that also carry all of these; their data is not yielded.
Parameters
Section titled “Parameters”components
Section titled “components”Returns
Section titled “Returns”QueryBuilder<C>
without()
Section titled “without()”without(…
components):QueryBuilder<C>
Defined in: ecs/query.ts:261
Exclude entities carrying any of these.
Parameters
Section titled “Parameters”components
Section titled “components”Returns
Section titled “Returns”QueryBuilder<C>