ServersYour serverFor creatorsForumFAQDocumentationSecurity
Download the launcher
  1. Documentation
  2. Shared functions
  3. isVehicleWheelOnGround

Function

isVehicleWheelOnGround

Server and clientVehiclesIdentical to MTA:SA

Returns whether a wheel touches the ground.

Syntax

bool isVehicleWheelOnGround(vehicle vehicle, int wheel)

Arguments

vehiclevehicle
The vehicle.
wheelint
Wheel number 0-3.

Returns

true when the wheel touches the ground.

Example

local vehicle = createVehicle(411, 2000, -1690, 13.5)
outputDebugString(tostring(isVehicleWheelOnGround(vehicle, 0)))

Notes

Client. In a client script it reads the game: wheel suspension compression (0 front left, 1 rear left, 2 front right, 3 rear right).

Always the default value. The server does not receive this information from the game yet, so the function returns true.

See also