HUDClient4 outputs

getHudColour

GET_HUD_COLOUR0x7C9C91AB74A0360F

The GTA V native GET_HUD_COLOUR of the HUD namespace, as LS:MP client scripts call it: the global function getHudColour, in JavaScript and in Lua.

SignatureJavaScript
getHudColour(hudColorIndex: number): [
  r: number,
  g: number,
  b: number,
  a: number
]
SignatureLua
getHudColour(hudColorIndex: integer): integer, integer, integer, integer

Usage

JavaScript
const [r, g, b, a] = getHudColour(hudColorIndex);
Lua
local r, g, b, a = getHudColour(hudColorIndex)

Parameters

ParameterTypeJavaScriptLua
hudColorIndexintnumberinteger

Returns

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

#ValueTypeJavaScriptLuaDescription
1rintnumberintegeroutput
2gintnumberintegeroutput
3bintnumberintegeroutput
4aintnumberintegeroutput

Reference

Namespace
HUD HUD
In the game
void GET_HUD_COLOUR(int hudColorIndex, int* r, int* g, int* b, int* a)
Hash
0x7C9C91AB74A0360F

Open in the interactive natives reference