14.12.2014, 22:35
Hey, so I was wondering how to do the same thing but for (/b) chat.
So administrator name would be orange and then the text would be grey.
Normal players the whole line would be grey.
Here's the (/b) command:
So administrator name would be orange and then the text would be grey.
Normal players the whole line would be grey.
Here's the (/b) command:
pawn Код:
//Orange For Admin Name - F6970C
//if(Player[playerid][AdminLevel] >= 1)
command(b, playerid, params[])
{
new Message[128], string[128];
if(sscanf(params, "z", Message))
{
SendClientMessage(playerid, WHITE, "SYNTAX: /b [message]");
}
else
{
if(strlen(Message) < 1 || !IsPlayerConnectedEx(playerid))
{
return 1;
}
else
{
if(Player[playerid][PrisonID] == 1)
{
SendClientMessage(playerid, WHITE, "You may not use this channel right now.");
}
else
{
format(string, sizeof(string), "%s: ((%s)) ", GetName(playerid), Message);
NearByMessage(playerid, WHITE, string);
}
}
}
return 1;
}