VelocityIntegrationOptions
Defined in: src/modules/motion/motion.ts:31
Options for makeVelocityIntegrationSystem: name, an optional boundary, tag-scoping, and onMove / runAfter hooks.
Type Parameters
Section titled “Type Parameters”TCtx extends VelocityIntegrationTickCtx
Properties
Section titled “Properties”boundary?
Section titled “boundary?”
optionalboundary?:VelocityIntegrationBoundary
Defined in: src/modules/motion/motion.ts:33
optionalname?:string
Defined in: src/modules/motion/motion.ts:32
onMove?
Section titled “onMove?”
optionalonMove?: (ctx,id,prev,next) =>void
Defined in: src/modules/motion/motion.ts:51
Invoked once per entity whose position actually changed this tick,
after any boundary handling. The prev snapshot is a plain value
object, not the store entry itself, so it is safe to retain. Provides
an escape hatch for games that keep a separate spatial index or
dirty-flag queue in sync; the motion module itself does not touch
either.
Parameters
Section titled “Parameters”TCtx
Readonly<Position>
Readonly<Position>
Returns
Section titled “Returns”void
runAfter?
Section titled “runAfter?”
optionalrunAfter?:string[]
Defined in: src/modules/motion/motion.ts:34
optionaltag?:TagDef
Defined in: src/modules/motion/motion.ts:42
Integrate only entities carrying this tag (in addition to having
Position + Velocity). Unset integrates every velocity entity. The
marker/query-filter idiom (like this engine’s own kinematics
dynamicTag) — so a game that runs kinematics over its bodies
can still integrate a disjoint set without double-integrating them.