20.04.2011, 16:55
You can't use strcmp & zcmd at the same time, you need to use one of them, however I suggest zcmd & sscanf.
pawn Код:
COMMAND:report(playerid, params[])
{
new string[128], pID, reporter[MAX_PLAYER_NAME], reported[MAX_PLAYER_NAME];
if(sscanf(params, "us[128]", pID, params[0])) return SendClientMessage(playerid, -1, "Usage: /report <playerid/playername> <reason>");
if(pID == INVALID_PLAYER_ID) return SendClientMessage(playerid, -1, "This player not connected");
GetPlayerName(playerid, reporter, sizeof(reporter));
GetPlayerName(pID, reported, sizeof(reported));
format(string, sizeof(string), "%s reports %s for: %s",reporter, reported, params[2]);
WhoToSend?Admins?(-1, string); // Edit this
return 1;
}