AdminLevel
#2

Just save their admin variable, if dini:
pawn Код:
dini_IntSet(YOURFILE, "Admin", playerinfo[playerid][AdminLevel]); // Saves admin level 5.
and then load that player's variables:
pawn Код:
dini_Int(YOURFILE, "Admin", Value);
pawn Код:
CMD:test(playerid, params[])
{
    if(playerinfo[playerid][AdminLevel] >= 5) // only admin lvl 5 can use the command
To set them admin level:
pawn Код:
CMD:makeadmin(playerid, params[])
{
    new PID, Level;
    if(sscanf(params, "ui", PID, Level)) return /* Error Message */
    // Add other filters here
    playerinfo[PID][AdminLevel] = Level;
    return 1;
}
Reply


Messages In This Thread
AdminLevel - by Face9000 - 14.12.2010, 21:55
Re: AdminLevel - by [L3th4l] - 14.12.2010, 21:57
Re: AdminLevel - by Face9000 - 14.12.2010, 22:00

Forum Jump:


Users browsing this thread: 1 Guest(s)