Skip to content
This repository has been archived by the owner on Feb 19, 2020. It is now read-only.

SetPlayerHUDComponentColour

GtakillerIV edited this page Dec 17, 2014 · 1 revision

SetPlayerHUDComponentColour

Sets a player's HUD component colour

tip Default value is 800.00


Parameters

playerid

The player's id.

componentid

The component id.

colour

The new colour.

You can find a list of the default colours here.

Returns

    0 if player is not connected

Usage

#define COLOR_LIGHTGREEN 	0xA2E864FF

CMD:altermoneycolour(playerid, params[])
{
	//If the player has the SA-MP+ plugin installed
	if(IsUsingSAMPP(playerid))
	{
		//Set the money's color to light green
		SetPlayerHUDComponentColour(playerid, HUD_COMPONENT_MONEY, COLOR_LIGHTGREEN);
	}
	//If not
	else
	{
		SendClientMessage(playerid, -1, "You need the SA-MP+ plugin");
	}
}

See also

ToggleHUDComponentForPlayer

TogglePlayerDriveOnWater

SetPlayerJetpackHeight

Clone this wiki locally