01.10.2011, 02:22
It compiles alright and everything after I edited it
but when I go ingame and do /makeadmin 0 (my ID) 1 it says Invalid ID...
pawn Code:
CMD:makeadmin(playerid, params[]){
if(PlayerInfo[playerid][pAdmin] < 1) return SendClientMessage(playerid,COLOR_GRAY,"ERROR: You're not authorized to use this command!");
new id, lvl;
if(sscanf(params, "ui", id, lvl)) return SendClientMessage(playerid, COLOR_WHITE, "SYNTAX: /makeadmin [PlayerID/PartOfName] [Level]");
else if(id == INVALID_PLAYER_ID) return SendClientMessage(playerid, COLOR_WHITE, "Invalid ID");
else
{
PlayerInfo[playerid][pAdmin] = lvl;
}
return 1;
}