Skip to main content

CameraGetRotation

This function was added in DSL 10

Description

Returns the current rotation angles of the camera in the game world.

function CameraGetRotation() --[[ ... ]] end

Parameters

None.

Return Values

  • pitch: number - The pitch angle of the camera.
  • roll: number - Always zero (0).
  • yaw: number - The yaw angle of the camera.

Example

local pitch, roll, yaw = CameraGetRotation()
print(pitch, roll, yaw)