16.10.2013, 10:23
Hello. I have one little problem and I don't know what to do. What do I have to do so the script allows me to use {FFFFFF} (hex colors) In-Game chat. It just doesn't work. Thanks!
Can you show us what you've attempted up to now so we can correct it?
|
format(string, sizeof(string), "The word after the colon will be white: {FFFFFF}White");
SendClientMessage(playerid, COLOR_RED, string);
You can't live add color embeed, only with scripts.
https://sampwiki.blast.hk/wiki/Colour_Em...olor_embedding |
ReColor(text[])
{
new
pos = -1;
while ((pos = strfind(text, "(", false, pos + 1)) != -1)
{
new
c = pos + 1,
n = 0,
ch;
// Note that the order of these is important!
while ((ch = text[c]) && n != 6)
{
if (!('a' <= ch <= 'f' || 'A' <= ch <= 'F' || '0' <= ch <= '9'))
{
break;
}
++c;
++n;
}
if (n == 6 && ch == ')')
{
text[pos] = '{';
text[c] = '}';
}
}
}
ReColor(text);