Entities · interface

SystemDefinition

Explained in Entities.

interface SystemDefinition
import type { SystemDefinition } from '@driftengine/entities';

Properties

NameTypeDescription
namereadonlystring
readsreadonlyoptionalreadonly ComponentType[]
writesreadonlyoptionalreadonly ComponentType[]
everyTicksreadonlyoptionalnumberRun once every this many fixed steps. Absent means every step.
More

A stride and never a rate in seconds. A rate in wall-clock time leaves the determinism contract on its first dropped frame: two runs of the same recording would run the system a different number of times. A tick count is the same in every replay of the same input.

afterreadonlyoptionalreadonly string[]Systems this one must run after, by name. A cycle here is refused at build.

Methods

run

run(view: SystemView): void
ParameterTypeDescription
viewSystemView