03.12.2008, 19:38
Well I walked into a server, where the chat was colorful, example

Thank you!
Example: /imageshack/my.php?image=samp077pc2.jpg
new string[128];
new name[24];
GetPlayerName(playerid,name,sizeof(name));
format(string,sizeof(string),"%s: %s",name,text);
SendClientMessageToAll(whatevercolor,string);
Originally Posted by JaTochNietDan
Well you can just do
pawn Code:
|
Originally Posted by JaTochNietDan
Well you can just do
pawn Code:
|
new string[128]; new name[24]; GetPlayerName(playerid,name,sizeof(name)); format(string,sizeof(string),"%s: %s",name,text); SendClientMessageToAll(GetPlayerColor(playerid),string);
Originally Posted by Servidor_BRASIL
Almost gave, but failed, instead of the color out of the color of the nickname, it leaves black, regardless of the color of the player!
What could it be? Code: public OnPlayerText (playerid, text []) { new string[128]; new name[24]; GetPlayerName(playerid,name,sizeof(name)); format(string,sizeof(string),"%s: %s",name,text); SendClientMessageToAll(GetPlayerColor(playerid),st ring); return 1; } Thank you! |
new string[128], name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(string,sizeof(string),"{0000AA}%s {00AA00}[%i]{FFFFFF}: %s",name,playerid,text);
return SendClientMessageToAll(0xFFFFFFFF,string), 0;