VehicleClientChecked by LS:MP

getVehicleClassEstimatedMaxSpeed

GET_VEHICLE_CLASS_ESTIMATED_MAX_SPEED0x00C09F246ABEDD82

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

SignatureJavaScript
getVehicleClassEstimatedMaxSpeed(vehicleClass: number): number
SignatureLua
getVehicleClassEstimatedMaxSpeed(vehicleClass: integer): number

Usage

JavaScript
const value = getVehicleClassEstimatedMaxSpeed(vehicleClass);
Lua
local value = getVehicleClassEstimatedMaxSpeed(vehicleClass)

Parameters

ParameterTypeJavaScriptLua
vehicleClassintnumberinteger

Returns

float JavaScript number, Lua number

On LS:MP

ℹ
Checked by LS:MP

vehicleClass must be between 0 and 22. Otherwise the call is ignored and returns 0.0: nothing reaches the game, and no error is raised.

Reference

Namespace
Vehicle VEHICLE
In the game
float GET_VEHICLE_CLASS_ESTIMATED_MAX_SPEED(int vehicleClass)
Hash
0x00C09F246ABEDD82
Formerly
_GET_VEHICLE_CLASS_MAX_SPEED

Open in the interactive natives reference