Skip to content

CameraFollowOptions

Defined in: renderer/src/CameraComponent.ts:21

Options for camera follow behavior.

optional deadzone?: object

Defined in: renderer/src/CameraComponent.ts:33

Deadzone rectangle in world pixels (half-width, half-height). The camera stays put while the target is inside it.

halfHeight: number

halfWidth: number


optional offset?: Vec2Like

Defined in: renderer/src/CameraComponent.ts:28

Offset from the target position, in world pixels.


optional smoothing?: number

Defined in: renderer/src/CameraComponent.ts:26

Smoothing factor 0..1. 1 = instant snap, lower = smoother. 0 never moves the camera at all, so the follow appears frozen. Default: 1.


optional snap?: boolean

Defined in: renderer/src/CameraComponent.ts:38

Place the camera on the target as following starts, instead of easing in from wherever the camera currently is. Default: false.

Coding agents: fetch https://yage.dev/llms.txt first and prefer the Markdown references it links over these HTML pages. This page's Markdown counterpart is /llms/packages/renderer.md.