mirror of
https://github.com/esx-framework/esx_core.git
synced 2026-08-30 17:58:54 +00:00
add tank health
This commit is contained in:
@@ -559,6 +559,7 @@ ESX.Game.GetVehicleProperties = function(vehicle)
|
||||
|
||||
bodyHealth = ESX.Math.Round(GetVehicleBodyHealth(vehicle), 1),
|
||||
engineHealth = ESX.Math.Round(GetVehicleEngineHealth(vehicle), 1),
|
||||
tankHealth = ESX.Math.Round(GetVehiclePetrolTankHealth(vehicle), 1),
|
||||
|
||||
fuelLevel = ESX.Math.Round(GetVehicleFuelLevel(vehicle), 1),
|
||||
dirtLevel = ESX.Math.Round(GetVehicleDirtLevel(vehicle), 1),
|
||||
@@ -648,6 +649,7 @@ ESX.Game.SetVehicleProperties = function(vehicle, props)
|
||||
if props.plateIndex then SetVehicleNumberPlateTextIndex(vehicle, props.plateIndex) end
|
||||
if props.bodyHealth then SetVehicleBodyHealth(vehicle, props.bodyHealth + 0.0) end
|
||||
if props.engineHealth then SetVehicleEngineHealth(vehicle, props.engineHealth + 0.0) end
|
||||
if props.tankHealth then SetVehiclePetrolTankHealth(vehicle, props.tankHealth + 0.0) end
|
||||
if props.fuelLevel then SetVehicleFuelLevel(vehicle, props.fuelLevel + 0.0) end
|
||||
if props.dirtLevel then SetVehicleDirtLevel(vehicle, props.dirtLevel + 0.0) end
|
||||
if props.color1 then SetVehicleColours(vehicle, props.color1, colorSecondary) end
|
||||
|
||||
Reference in New Issue
Block a user