PDA

View Full Version : Color problem


Mister0
05/03/2016, 09:48 AM
Hello I try to define the color of player like that

new Color[4];

stock PlayerColor(factionid)
{
format(Color[1],40,"0xFFFFFFC8");
format(Color[2],40,"0x0080C0C8");
format(Color[3],40,"0x0000A0C8");
return 1;
}

For see if color works I try to make this sendclientmessage, but , don't work is color black when he send me the message, whta is wrong?

format(string,123,"Color: %s ",PlayerColor(PlayerInfo[playerid][pMember]));
SendClientMessage(playerid,PlayerColor(PlayerInfo[playerid][pMember]),string);

Vince
05/03/2016, 01:17 PM
Colors are numbers and they should be treated as such. Your function also does nothing but return 1 (0x00000001) a.k.a. black.