Rainbow colors name convert to text
#1

Код:
//top
new PlayerRainbowColours[63] = {
/*OKStyle*/ 000022, 000044, 000066, 000088, 0000AA, 0000CC, 0000EE,
002200, 002222, 002244, 002266, 002288, 0022AA, 0022CC, 0022EE,
004400, 004422, 004444, 004466, 004488, 0044AA, 0044CC, 0044EE,
006600, 006622, 006644, 006666, 006688, 0066AA, 0066CC, 0066EE,
008800, 008822, 008844, 008866, 008888, 0088AA, 0088CC, 0088EE,
00AA00, 00AA22, 00AA44, 00AA66, 00AA88, 00AAAA, 00AACC, 00AAEE,
00CC00, 00CC22, 00CC44, 00CC66, 00CC88, 00CCAA, 00CCCC, 00CCEE,
00EE00, 00EE22, 00EE44, 00EE66, 00EE88, 00EEAA, 00EECC, 00EEEE,
};
Код:
//OnPlayerText
new colour = PlayerRainbowColours(playerid);
	if(gTeam[playerid] == TEAM_DRIVER)
    {
		SendClientMessageToAllEx(COLOUR_WHITE, ""orange"[Driver]"{colour}"%s (%d): "white"%s", GetPName(playerid), playerid, text);
    }
How to properly write the code?

Edit://

now I change code to this:
Код:
//OnPlayerText
	if(gTeam[playerid] == TEAM_DRIVER)
    {
		SendClientMessageToAllEx(COLOUR_WHITE, ""orange"[Driver]{%06x}%s (%d): "white"%s", GetPlayerColor(playerid) >>> 8, GetPName(playerid), playerid, text);
    }
Now it's better but I see orange text and black nick. Why?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)