Skip to content

makeFollowCameraSystem

makeFollowCameraSystem<TCtx>(options): SchedulableSystem<TCtx>

Defined in: src/modules/camera/camera.ts:172

Returns a system that, each tick, follows the first targetTag-tagged entity with every cameraTag-tagged CameraDef. Optional deadzone (chase only once the target leaves a centred band), smoothing (ease toward the target — needs ctx.dtMs), and limit* clamping (applied after following).

Multiple target tags are not supported — tag exactly one entity per game. When no target is tagged or it has no position, the tick is a no-op.

TCtx extends CameraFollowTickCtx

CameraFollowOptions

SchedulableSystem<TCtx>