20.02.2015, 06:47
EDIT:
I should have done it like this^. This is perfect and compatible.
pawn Код:
public OnPlayerText(playerid,text[])
{
new string[128], name[MAX_PLAYER_NAME];
GetPlayerName(playerid, name, sizeof name);
if(PInfo[playerid][Level] > 1 && text[0] == '.')
{
format(string, sizeof(string),"[ADMIN CHAT] %s[%d]: %s", name, playerid, text[1]);
MessageToAdmins(COLOR_MEDIUMSEAGREEN, string);
return 0;
}
if(PInfo[playerid][pAdminDuty])
{
format(string, sizeof string, "Administrator %s: %s", name, text);
SendClientMessageToAll(COLOR_GOLD, string);
return 0;
}
return 1;
}