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

Function

getVehicleGravity

ServerVehiclesIdentical to MTA:SA

Returns the vehicle's gravity direction stored with setVehicleGravity (0, 0, -1 by default).

Syntax

float, float, float getVehicleGravity(vehicle vehicle)

Arguments

vehiclevehicle
The vehicle.

Returns

x, y, z.

Example

local vehicle = createVehicle(411, 2000, -1690, 13.5)
local gx, gy, gz = getVehicleGravity(vehicle)

See also