Examples
import { EulerIntegrator2DPlugin } from '@wimaengine/integrator'
app.registerPlugin(new EulerIntegrator2DPlugin())
// Velocity2D entities are integrated during each Update pass.Function
updateVelocityEuler2D(world: World): voidAdvances each matching 2D linear velocity with its accumulated acceleration.
EulerIntegrator2DPlugin registers this exact function directly in the
repeating AppSchedule.Update schedule. The registration does not specify a system
group, so the schedule’s default group is used.
The query requires Velocity2D and Acceleration2D, in that
order. Each matching velocity is updated in place with acceleration * (1 / 60), then the acceleration is reset to zero in place. Entities
missing either component are skipped. This implementation uses the fixed
1 / 60 step in the source; it does not read Time.delta or
VirtualClock.
import { EulerIntegrator2DPlugin } from '@wimaengine/integrator'
app.registerPlugin(new EulerIntegrator2DPlugin())
// Velocity2D entities are integrated during each Update pass.