VehicleClient3 outputs

getVehicleCustomPrimaryColour

GET_VEHICLE_CUSTOM_PRIMARY_COLOUR0xB64CF2CCA9D95F52

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

SignatureJavaScript
getVehicleCustomPrimaryColour(vehicle: Vehicle): [
  r: number,
  g: number,
  b: number
]
SignatureLua
getVehicleCustomPrimaryColour(vehicle: Vehicle): integer, integer, integer

Usage

JavaScript
const [r, g, b] = getVehicleCustomPrimaryColour(vehicle);
Lua
local r, g, b = getVehicleCustomPrimaryColour(vehicle)

Parameters

ParameterTypeJavaScriptLua
vehicleVehiclenumberinteger

Returns

3 values, in this order: an array in JavaScript, multiple return values in Lua.

#ValueTypeJavaScriptLuaDescription
1rintnumberintegeroutput
2gintnumberintegeroutput
3bintnumberintegeroutput

Reference

Namespace
Vehicle VEHICLE
In the game
void GET_VEHICLE_CUSTOM_PRIMARY_COLOUR(Vehicle vehicle, int* r, int* g, int* b)
Hash
0xB64CF2CCA9D95F52

Open in the interactive natives reference