VehicleClientChecked by LS:MP

setTyreHealth

SET_TYRE_HEALTH0x74C68EF97645E79D

The GTA V native SET_TYRE_HEALTH of the VEHICLE namespace, as LS:MP client scripts call it: the global function setTyreHealth, in JavaScript and in Lua.

SignatureJavaScript
setTyreHealth(vehicle: Vehicle, wheelIndex: number, health: number): void
SignatureLua
setTyreHealth(vehicle: Vehicle, wheelIndex: integer, health: number)

Usage

JavaScript
setTyreHealth(vehicle, wheelIndex, health);
Lua
setTyreHealth(vehicle, wheelIndex, health)

Parameters

ParameterTypeJavaScriptLua
vehicleVehiclenumberinteger
wheelIndexintnumberinteger
healthfloatnumbernumber

Returns

Nothing. In JavaScript the call evaluates to undefined.

On LS:MP

ℹ
Checked by LS:MP

wheelIndex must be between 0 and 7; health must be a finite number. Otherwise the call is ignored: nothing reaches the game, and no error is raised.

Notes

From the community native database. Names are LS:MP’s; samples may be written for C++ or another framework.

setTyreWearRate must be active, otherwise values set to <1000.0f will default to 350.0f

Usable wheels:
0: wheel_lf
1: wheel_rf
2: wheel_lm1
3: wheel_rm1
4: wheel_lr
5: wheel_rr

Reference

Namespace
Vehicle VEHICLE
In the game
void SET_TYRE_HEALTH(Vehicle vehicle, int wheelIndex, float health)
Hash
0x74C68EF97645E79D
Introduced
Game build 1868 legacy numbering
Formerly
_SET_TYRE_HEALTH

Open in the interactive natives reference