Help needed
#1

What am i doing wrong here? (im a begginer please help me understand this)
pawn Код:
dcmd_setadmin(playerid,params[])
{
    if(AdminLvL[playerid] >= 5 || IsPlayerAdmin(playerid))
    {
      new giveplayerid, givelvl;
        if(sscanf(params,"dz",giveplayerid,givelvl))
      {
        SendClientMessage(playerid,COLOR_RED,"Usage: /setadmin [id] [lvl]");
            return 1;
        }
        if(!IsPlayerConnected(giveplayerid))
        {
          new Stringy[128];
            format(Stringy, sizeof(Stringy), "ID (%d) Is not an active player", giveplayerid);
            SendClientMessage(playerid, COLOR_RED, Stringy);
            return 1;
      }
      new Stringy[128];
      format(Stringy, sizeof(Stringy), "You gave ID(%d) LVL %d Admin", giveplayerid,givelvl);
      SendClientMessage(playerid, COLOR_RED, Stringy);
       format(Stringy, sizeof(Stringy), "You are now lvl %d Admin",givelvl);
      SendClientMessage(giveplayerid, COLOR_RED, Stringy);
      AdminLvL[giveplayerid] = givelvl;
       return 1;
       
     
    }
    return 0;
}
I am using DUDB.
Reply


Messages In This Thread
Help needed - by GhOstY93 - 31.10.2009, 21:36
Re: Help needed - by member - 31.10.2009, 21:46
Re: Help needed - by GhOstY93 - 31.10.2009, 21:53
Re: Help needed - by member - 31.10.2009, 22:02
Re: Help needed - by GhOstY93 - 31.10.2009, 22:12
Re: Help needed - by member - 31.10.2009, 22:16
Re: Help needed - by GhOstY93 - 31.10.2009, 22:22

Forum Jump:


Users browsing this thread: 3 Guest(s)