Skip to content

Camera

State typessource

Fields

adjusted_focus_x

number

source

adjusted_focus_y

number

source

bounds_bottom

number

source

bounds_left

number

source

bounds_right

number

source

bounds_top

number

source

calculated_focus_x

number

source

calculated_focus_y

number

source

focus_offset_x

number

source

focus_offset_y

number

source

focus_x

number

source

focus_y

number

source

focused_entity_uid

integer

if set to -1, you have free control over camera focus through focus_x, focus_y

source

inertia

number

This is a bad name, but it represents the camera tweening speed. [0..5] where 0=still, 1=default (move 20% of distance per frame), 5=max (move 5*20% or 100% aka instantly to destination per frame)

source

peek_layer

integer

source

peek_timer

integer

amount of frames to freeze camera in place and move to the peek_layer during the peek you can freely set camera position no matter if focused_entity_uid is set to -1 or not

source

shake_amplitude

number

source

shake_countdown

integer

source

shake_countdown_start

integer

source

shake_multiplier_x

number

source

shake_multiplier_y

number

source

uniform_shake

boolean

source

vertical_pan

number

source

Methods

get_bounds

function Camera:get_bounds(): AABB

Returns AABB

source

set_bounds

function Camera:set_bounds(bounds: AABB)
bounds: AABB
source