pawn Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
new Command[100], Params[100];
if(strfind(cmdtext, " ") != -1) strmid(Command, cmdtext, 1, strfind(cmdtext, " "));
else if(strfind(cmdtext, " ") == -1) format(Command, 100, "%s", cmdtext);
if(strfind(cmdtext, " ") != -1) format(Params, sizeof(Params), "%s", cmdtext[strfind(cmdtext, " ")]);
#define IsParams(%1) strcmp(Params, %1)
#define IsCommand(%1) strcmp(Command, %1)
if(IsCommand("me"))
{
new Str[100];
GetPlayerName(playerid, Str, 24);
format(Str, sizeof(Str), "%s: %s", Str, Params);
SendClientMessageToAll(0xF5F200AA, Str);
return 1;
}
return 0;
}