ServersYour serverFor creatorsForumFAQDocumentationSecurity
Download the launcher
  1. Documentation
  2. Server functions
  3. getVehicleTurretPosition

Function

getVehicleTurretPosition

ServerVehiclesIdentical to MTA:SA

Returns the turret rotation stored with setVehicleTurretPosition (horizontal, vertical in radians; 0, 0 by default).

Syntax

float, float getVehicleTurretPosition(vehicle vehicle)

Arguments

vehiclevehicle
The vehicle.

Returns

Horizontal and vertical rotation.

Example

local tank = createVehicle(432, 300, 1900, 18)
local h, v = getVehicleTurretPosition(tank)

See also