Skip to main content

SimulationFrame

@zylem/game-lib


@zylem/game-lib / runtime / SimulationFrame

Interface: SimulationFrame

Defined in: node_modules/.pnpm/@zylem+behaviors@0.8.9_@types+react@19.3.0_react@19.3.0_three@0.185.1/node_modules/@zylem/behaviors/dist/core.d.ts:218

Snapshot of one update() call: how many fixed steps ran, the live render buffer view, the previous-step render copy + interpolation alpha for smooth rendering, and the translated events from every step taken.

Properties​

alpha​

alpha: number

Defined in: node_modules/.pnpm/@zylem+behaviors@0.8.9_@types+react@19.3.0_react@19.3.0_three@0.185.1/node_modules/@zylem/behaviors/dist/core.d.ts:224

Interpolation alpha in [0, 1): fraction of a fixed step accumulated.


deltaTime​

deltaTime: number

Defined in: node_modules/.pnpm/@zylem+behaviors@0.8.9_@types+react@19.3.0_react@19.3.0_three@0.185.1/node_modules/@zylem/behaviors/dist/core.d.ts:220

Wall-clock delta handed to update().


events​

events: SimulationEvent[]

Defined in: node_modules/.pnpm/@zylem+behaviors@0.8.9_@types+react@19.3.0_react@19.3.0_three@0.185.1/node_modules/@zylem/behaviors/dist/core.d.ts:231

Typed events from all steps taken this update, oldest first.


previousRender​

previousRender: Float32Array

Defined in: node_modules/.pnpm/@zylem+behaviors@0.8.9_@types+react@19.3.0_react@19.3.0_three@0.185.1/node_modules/@zylem/behaviors/dist/core.d.ts:228

Copy of the render buffer as of the step before the last one.


render​

render: Float32Array

Defined in: node_modules/.pnpm/@zylem+behaviors@0.8.9_@types+react@19.3.0_react@19.3.0_three@0.185.1/node_modules/@zylem/behaviors/dist/core.d.ts:226

Live render buffer (post-step poses), STAGE_RENDER_STRIDE floats per slot.


renderStride​

renderStride: number

Defined in: node_modules/.pnpm/@zylem+behaviors@0.8.9_@types+react@19.3.0_react@19.3.0_three@0.185.1/node_modules/@zylem/behaviors/dist/core.d.ts:229


stepsTaken​

stepsTaken: number

Defined in: node_modules/.pnpm/@zylem+behaviors@0.8.9_@types+react@19.3.0_react@19.3.0_three@0.185.1/node_modules/@zylem/behaviors/dist/core.d.ts:222

Number of fixed steps executed (0 when accumulating).