06.11.2012, 16:50
Don't you have to add the dcmd line onplayercommand up top also?
If I was you, I would just use zcmd, foreach, sscanf so for example:
Best of luck.
If I was you, I would just use zcmd, foreach, sscanf so for example:
pawn Код:
CMD:giveallscore(playerid, params[])
{
new escore, string[128];
if(AccInfo[playerid][Level] >= 3)
{
if(sscanf(params, "d", escore)) return SendClientMessage(playerid, -1, "USAGE: /giveallscore amount");
foreach(Player, x)
{
format(string, sizeof(string), "You have been given an extra %d score.", escore);
SendClientMessage(x, -1, string);
SetPlayerScore(x, GetPlayerScore(x) + escore);
}
}
else
{
SendClientMessage(playerid, -1, "You aren't high enough level to use this command.");
}
return 1;
}