16.10.2013, 04:06
try this with that cmd
i guess that the problem is in register dialog
show me the regiter dialog pls
pawn Код:
CMD:setlevel(playerid, params[])
{
new id, level, string[128], string2[128], name[MAX_PLAYER_NAME], name2[MAX_PLAYER_NAME];
if(pInfo[playerid][pAdmin] < 5) return SendClientMessage(playerid, -1, "Nono:You don't have the required level to execute this command");
if(sscanf(params, "ud", id, level)) return SendClientMessage(playerid, -1, "Nana: use /setlevel [ID] [level]");
if(level > 6) return SendClientMessage(playerid, -1, "No: Level cant be above 6");
if(id == INVALID_PLAYER_ID) return SendClientMessage(playerid, -1, "No: That ID isn't connected");
else
{
GetPlayerName(playerid, name, sizeof(name));
GetPlayerName(id, name2, sizeof(name2));
pInfo[id][Adminlevel] = level;
format(string, sizeof(string), "Admin %s has promoted you to admin level %d", name, level);
format(string2, sizeof(string2), "You have promoted %s to admin level %d", name2, level);
SendClientMessage(id, -1, string);
SendClientMessage(playerid, -1, string2);
}
return true;
}
i guess that the problem is in register dialog
show me the regiter dialog pls