Skip to content
VICE ROLEPLAY Türkçe
Vice Roleplay/SA-MP guide/Commands, codes and IDs

Commands, codes and IDs

SA-MP colour codes: how to use {FFFFFF} in chat and text

How {RRGGBB} colour codes work in SA-MP, a ready-made colour table, GameText codes such as ~r~ and the 0xRRGGBBAA format used in scripts.

Vice Roleplay · Sources checked:

Vice at night.
Vice at night.

In SA-MP you change text colour with a six-digit HEX code in curly brackets: {FF0000}red. The colour starts where you write the code and lasts until the next code. Many servers do not let players colour their own chat, so these codes are mostly used in server messages, dialogs and 3D text.

Ready-made colours

ColourHEXCode to type
WhiteFFFFFF{FFFFFF}
Black000000{000000}
GreyAFAFAF{AFAFAF}
RedFF0000{FF0000}
Dark redAA3333{AA3333}
OrangeFF9900{FF9900}
YellowFFFF00{FFFF00}
GoldFFD700{FFD700}
Green00FF00{00FF00}
Dark green33AA33{33AA33}
Cyan00FFFF{00FFFF}
Light blue33CCFF{33CCFF}
Blue0000FF{0000FF}
Purple9900FF{9900FF}
PinkFF66CC{FF66CC}
Brown8B4513{8B4513}

GameText codes

Big on-screen texts (GameText) and some textdraws use a different system: letters between tildes.

CodeMeaning
~r~Red
~g~Green
~b~Blue
~y~Yellow
~p~Purple
~w~White
~l~Black
~h~Makes the colour lighter; can be stacked
~n~New line

For scripters: 0xRRGGBBAA

Functions such as SendClientMessage take colours as 0xRRGGBBAA; the last two digits are transparency (alpha). The names below are common defines in many gamemodes.

NameValue
COLOR_WHITE0xFFFFFFAA
COLOR_GREY0xAFAFAFAA
COLOR_RED0xAA3333AA
COLOR_GREEN0x33AA33AA
COLOR_YELLOW0xFFFF00AA
COLOR_LIGHTBLUE0x33CCFFAA
COLOR_ORANGE0xFF9900AA

If a colour does not show: the code must be exactly six digits, inside curly brackets and without #. If it still does not work, the server probably blocks colours in that place.

Sources and scope

This article was prepared with AI assistance after checking the sources and Vice rules. Example scenes were written for explanation and do not describe actual player incidents. Current server rules and on-screen requirements take precedence.

    Need help?

    Include the step you are stuck on and any error message in a ticket. Never send your password.

    Support / Ticket ↗