Skip to content

CameraManager

@vimp-mp/types 2.0.1

Interface · Client API

Creates scripted cameras and exposes the gameplay camera.

ts
interface CameraManager

Members

all

ts
readonly all: Array<Camera>

Script cameras created via create; does not include the gameplay camera.

count

ts
readonly count: number

Number of active scripted cameras.

create

ts
create(name: string, position: Vec3, rotation: Vec3, fov: number): Camera

Creates a scripted camera with the supplied transform and field of view.

getById

ts
getById(id: number): Camera | null

Returns the scripted camera with id, or null when it does not exist.

getGameplayCamera

ts
getGameplayCamera(): Camera

Returns the singleton wrapper for GTA's gameplay camera.

renderScriptCams

ts
renderScriptCams(render: boolean, ease?: boolean, easeTime?: number, freezePreviousCamera?: boolean): void

Enables or disables rendering through scripted cameras.

VIMP developer documentation