HUDClient

setMpGamerTagHealthBarColour

SET_MP_GAMER_TAG_HEALTH_BAR_COLOUR0x3158C77A7E888AB4

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

SignatureJavaScript
setMpGamerTagHealthBarColour(gamerTagId: number, hudColorIndex: number): void
SignatureLua
setMpGamerTagHealthBarColour(gamerTagId: integer, hudColorIndex: integer)

Usage

JavaScript
setMpGamerTagHealthBarColour(gamerTagId, hudColorIndex);
Lua
setMpGamerTagHealthBarColour(gamerTagId, hudColorIndex)

Parameters

ParameterTypeJavaScriptLua
gamerTagIdintnumberinteger
hudColorIndexintnumberinteger

Returns

Nothing. In JavaScript the call evaluates to undefined.

Notes

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

Ranges from 0 to 255. 0 is grey health bar, ~50 yellow, 200 purple.
Should be enabled as flag (2). Has 0 opacity by default.

Reference

Namespace
HUD HUD
In the game
void SET_MP_GAMER_TAG_HEALTH_BAR_COLOUR(int gamerTagId, int hudColorIndex)
Hash
0x3158C77A7E888AB4
Formerly
_SET_MP_GAMER_TAG_HEALTH_BAR_COLOR

Open in the interactive natives reference