跳转到内容

defineSystem

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

defineSystem<P>(params, fn, options?): SystemDef

Defined in: ecs/system.ts:221

Declare a system: what it reads and writes, and the function to run.

Ordering declared here travels with the definition, so it applies wherever the system is registered — including the top-level addSystem, which takes no options of its own. Edges given again at the registration site (or on the enclosing SystemSet) are added to these, not replaced.

P extends readonly SystemParam[]

[...P[]]

(…args) => void | Promise<void>

SystemOptions

SystemDef