Native referenceFiveM

CREATE_CAM

0xC3981DCE61D9E13F CAM
FUNCTION SIGNATURE
Cam CREATE_CAM(char* camName, BOOL active);
Property Value
Native Name CREATE_CAM
Hash 0xC3981DCE61D9E13F
Return Type Cam
Parameters camName (char*), active (BOOL)

Description: Creates a camera with the specified cam name, You can use SET_CAM_ natives to manipulate the camera.
Make sure to call RENDER_SCRIPT_CAMS once the camera is created, or this won't have any visible effect.

Camera names:

  • DEFAULT_SCRIPTED_CAMERA
  • DEFAULT_ANIMATED_CAMERA
  • DEFAULT_SPLINE_CAMERA
  • DEFAULT_SCRIPTED_FLY_CAMERA
  • TIMED_SPLINE_CAMERA
  • CUSTOM_TIMED_SPLINE_CAMERA
  • ROUNDED_SPLINE_CAMERA
  • SMOOTHED_SPLINE_CAMERA

Parameters

  • camName (char*) — A string representing the camera type, the game will convert the string into a joaat hash upon native execution.
  • active (BOOL) — Set to true if you wish to make this new camera the active camera.

Examples

local cam = CreateCam("DEFAULT_SCRIPTED_CAMERA", true)
const cam = CreateCam("DEFAULT_SCRIPTED_CAMERA", true);
int cam = CreateCam("DEFAULT_SCRIPTED_CAMERA", true);
Back to CAM