irccmd
#1

hey guys i added the irc to my admin system so i need make this cmd to irc cmd please help

CMD:

PHP код:
CMD:admins(playerid,params[])
{
   new 
IsOnline 0;
   
strdel(JLstring,0,500);
   foreach(
Playeri)
   {
      if (
pInfo[i][pLevel] >= && pInfo[i][AHide] == 0)
      {
               switch(
pInfo[i][pLevel])
              {
                  case 
1: {
                  
LevelName ADMIN_LEVEL_1;
                  
LevelColor LEVEL_1_COLOR;
                  }
                  case 
2: {
                  
LevelName ADMIN_LEVEL_2;
                  
LevelColor LEVEL_2_COLOR;
                  }
                  case 
3: {
                  
LevelName ADMIN_LEVEL_4;
                  
LevelColor LEVEL_3_COLOR;
                  }
                  case 
4: {
                  
LevelName ADMIN_LEVEL_3;
                  
LevelColor LEVEL_4_COLOR;
                  }
                  case 
5: {
                  
LevelName ADMIN_LEVEL_5;
                  
LevelColor LEVEL_5_COLOR;
                  }
                  default: {
                  
LevelName ADMIN_LEVEL_6;
                  
LevelColor LEVEL_6_COLOR;
                  }
              }
              if (
IsPlayerAdmin(i)) format(Jstring128"%s [%d] - [Level: %d] (RCON Administrator)\n",GetName(i),i,pInfo[i][pLevel]);
              else 
format(Jstring128"%s [%d] - [Level %d]\n",GetName(i),i,pInfo[i][pLevel]);
              
strcat(JLstringJstringsizeof(JLstring));
              
IsOnline++;
        }
   }
   if (
IsOnline == 0)
   
ShowPlayerDialog(playerid,JDIALOGS+165,DIALOG_STYLE_MSGBOX,"{00FFE6}XtremeX. Online admins","{FF0000}No admins are online!" ,"OK","");
   else
   {
       if(
IsOnline == 1ShowPlayerDialog(playerid,JDIALOGS+165,DIALOG_STYLE_MSGBOX,"{00FFE6}1 XtremeX admin online",JLstring ,"OK","");
       else 
format(Jstring128"{00FFE6}%d XtremeX Admin Online",IsOnline), ShowPlayerDialog(playerid,JDIALOGS+165,DIALOG_STYLE_MSGBOX,Jstring,JLstring ,"OK","");
   }
   
strdel(JLstring,0,500);
   return 
1;

Reply
#2

any help pls
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)