Advertisement
Guest User

Untitled

a guest
May 30th, 2010
164
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 8.00 KB | None | 0 0
  1. irccmd_players(conn, channel[], user[], params[])
  2. {
  3.     #pragma unused params, user
  4.    
  5.     new counter = 0,
  6.         players[SLOTS],
  7.         PlayerNames[1024],
  8.         string[1024];
  9.  
  10.     for(new i=0; i<SLOTS; i++)
  11.     {
  12.         if(IsPlayerConnected(i))
  13.         {
  14.             players[counter] = i;
  15.             counter++;
  16.         }
  17.     }
  18.    
  19.     if(!counter){
  20.        format(string, 64, "6Connected Players[%d]: 14No Players Online!", counter);
  21.         ircSay(conn, channel, string);
  22.     }
  23.     else
  24.     {
  25.         if(counter <= 30)
  26.         {
  27.             for(new i=0; i<=counter; i++)
  28.             {
  29.                 if(IsPlayerConnected(players[i]))
  30.                 {
  31.                     if(pData[players[i]][pAdmin] > 0)
  32.                     {
  33.                         if(pData[players[i]][pAdmin] == 1 || pData[players[i]][pAdmin] == 2)
  34.                         {
  35.                             format(PlayerNames, sizeof(PlayerNames),"%s 1,7%s", PlayerNames, PlayerName(players[i]));
  36.                         }
  37.                         else if(pData[players[i]][pAdmin] == 3 || pData[players[i]][pAdmin] == 4)
  38.                         {
  39.                             format(PlayerNames, sizeof(PlayerNames),"%s 1,8%s", PlayerNames, PlayerName(players[i]));
  40.                         }
  41.                         else if(pData[players[i]][pAdmin] == 5)
  42.                         {
  43.                             format(PlayerNames, sizeof(PlayerNames),"%s 1,3%s", PlayerNames, PlayerName(players[i]));
  44.                         }
  45.                     }
  46.                     else
  47.                     {
  48.                         format(PlayerNames, sizeof(PlayerNames),"%s 1,0%s", PlayerNames, PlayerName(players[i]));
  49.                     }
  50.                 }
  51.             }
  52.            
  53.             format(string, sizeof(string), "6Connected Players[%d]:1,0%s", counter, PlayerNames);
  54.             ircSay(BotSwitcher(), channel, string);
  55.         }
  56.         else
  57.         {
  58.             if(counter > 30 && counter < 61)
  59.             {
  60.                 for(new i=0; i<=30; i++)
  61.                 {
  62.                     if(IsPlayerConnected(players[i]))
  63.                     {
  64.                         if(pData[players[i]][pAdmin] > 0)
  65.                         {
  66.                             if(pData[players[i]][pAdmin] == 1 || pData[players[i]][pAdmin] == 2)
  67.                             {
  68.                                 format(PlayerNames, sizeof(PlayerNames),"%s 1,7%s", PlayerNames, PlayerName(players[i]));
  69.                             }
  70.                             else if(pData[players[i]][pAdmin] == 3 || pData[players[i]][pAdmin] == 4)
  71.                             {
  72.                                 format(PlayerNames, sizeof(PlayerNames),"%s 1,8%s", PlayerNames, PlayerName(players[i]));
  73.                             }
  74.                             else if(pData[players[i]][pAdmin] == 5)
  75.                             {
  76.                                 format(PlayerNames, sizeof(PlayerNames),"%s 1,3%s", PlayerNames, PlayerName(players[i]));
  77.                             }
  78.                         }
  79.                         else
  80.                         {
  81.                             format(PlayerNames, sizeof(PlayerNames),"%s 1,0%s", PlayerNames, PlayerName(players[i]));
  82.                         }
  83.                     }
  84.                 }
  85.  
  86.                 format(string, sizeof(string), "6Connected Players[%d]:1,0 %s", counter, PlayerNames);
  87.                 ircSay(BotSwitcher(), channel, string);
  88.                
  89.                 for(new i=31; i<=60; i++)
  90.                 {
  91.                     if(IsPlayerConnected(players[i]))
  92.                     {
  93.                         if(pData[players[i]][pAdmin] > 0)
  94.                         {
  95.                             if(pData[players[i]][pAdmin] == 1 || pData[players[i]][pAdmin] == 2)
  96.                             {
  97.                                 format(PlayerNames, sizeof(PlayerNames),"%s 1,7%s", PlayerNames, PlayerName(players[i]));
  98.                             }
  99.                             else if(pData[players[i]][pAdmin] == 3 || pData[players[i]][pAdmin] == 4)
  100.                             {
  101.                                 format(PlayerNames, sizeof(PlayerNames),"%s 1,8%s", PlayerNames, PlayerName(players[i]));
  102.                             }
  103.                             else if(pData[players[i]][pAdmin] == 5)
  104.                             {
  105.                                 format(PlayerNames, sizeof(PlayerNames),"%s 1,3%s", PlayerNames, PlayerName(players[i]));
  106.                             }
  107.                         }
  108.                         else
  109.                         {
  110.                             format(PlayerNames, sizeof(PlayerNames),"%s 1,0%s", PlayerNames, PlayerName(players[i]));
  111.                         }
  112.                     }
  113.                 }
  114.  
  115.                 format(string, sizeof(string), "1,0 %s", PlayerNames);
  116.                 ircSay(BotSwitcher(), channel, string);
  117.                
  118.             }
  119.             else if(counter > 60)
  120.             {
  121.                 for(new i=0; i<=30; i++)
  122.                 {
  123.                     if(IsPlayerConnected(players[i]))
  124.                     {
  125.                         if(pData[players[i]][pAdmin] > 0)
  126.                         {
  127.                             if(pData[players[i]][pAdmin] == 1 || pData[players[i]][pAdmin] == 2)
  128.                             {
  129.                                 format(PlayerNames, sizeof(PlayerNames),"%s 1,7%s", PlayerNames, PlayerName(players[i]));
  130.                             }
  131.                             else if(pData[players[i]][pAdmin] == 3 || pData[players[i]][pAdmin] == 4)
  132.                             {
  133.                                 format(PlayerNames, sizeof(PlayerNames),"%s 1,8%s", PlayerNames, PlayerName(players[i]));
  134.                             }
  135.                             else if(pData[players[i]][pAdmin] == 5)
  136.                             {
  137.                                 format(PlayerNames, sizeof(PlayerNames),"%s 1,3%s", PlayerNames, PlayerName(players[i]));
  138.                             }
  139.                         }
  140.                         else
  141.                         {
  142.                             format(PlayerNames, sizeof(PlayerNames),"%s 1,0%s", PlayerNames, PlayerName(players[i]));
  143.                         }
  144.                     }
  145.                 }
  146.  
  147.                 format(string, sizeof(string), "6Connected Players[%d]:1,0 %s", counter, PlayerNames);
  148.                 ircSay(BotSwitcher(), channel, string);
  149.  
  150.                 for(new i=31; i<=60; i++)
  151.                 {
  152.                     if(IsPlayerConnected(players[i]))
  153.                     {
  154.                         if(pData[players[i]][pAdmin] > 0)
  155.                         {
  156.                             if(pData[players[i]][pAdmin] == 1 || pData[players[i]][pAdmin] == 2)
  157.                             {
  158.                                 format(PlayerNames, sizeof(PlayerNames),"%s 1,7%s", PlayerNames, PlayerName(players[i]));
  159.                             }
  160.                             else if(pData[players[i]][pAdmin] == 3 || pData[players[i]][pAdmin] == 4)
  161.                             {
  162.                                 format(PlayerNames, sizeof(PlayerNames),"%s 1,8%s", PlayerNames, PlayerName(players[i]));
  163.                             }
  164.                             else if(pData[players[i]][pAdmin] == 5)
  165.                             {
  166.                                 format(PlayerNames, sizeof(PlayerNames),"%s 1,3%s", PlayerNames, PlayerName(players[i]));
  167.                             }
  168.                         }
  169.                         else
  170.                         {
  171.                             format(PlayerNames, sizeof(PlayerNames),"%s 1,0%s", PlayerNames, PlayerName(players[i]));
  172.                         }
  173.                     }
  174.                 }
  175.  
  176.                 format(string, sizeof(string), "1,0 %s", PlayerNames);
  177.                 ircSay(BotSwitcher(), channel, string);
  178.  
  179.                 for(new i=61; i<=counter; i++)
  180.                 {
  181.                     if(IsPlayerConnected(players[i]))
  182.                     {
  183.                         if(pData[players[i]][pAdmin] > 0)
  184.                         {
  185.                             if(pData[players[i]][pAdmin] == 1 || pData[players[i]][pAdmin] == 2)
  186.                             {
  187.                                 format(PlayerNames, sizeof(PlayerNames),"%s 1,7%s", PlayerNames, PlayerName(players[i]));
  188.                             }
  189.                             else if(pData[players[i]][pAdmin] == 3 || pData[players[i]][pAdmin] == 4)
  190.                             {
  191.                                 format(PlayerNames, sizeof(PlayerNames),"%s 1,8%s", PlayerNames, PlayerName(players[i]));
  192.                             }
  193.                             else if(pData[players[i]][pAdmin] == 5)
  194.                             {
  195.                                 format(PlayerNames, sizeof(PlayerNames),"%s 1,3%s", PlayerNames, PlayerName(players[i]));
  196.                             }
  197.                         }
  198.                         else
  199.                         {
  200.                             format(PlayerNames, sizeof(PlayerNames),"%s 1,0%s", PlayerNames, PlayerName(players[i]));
  201.                         }
  202.                     }
  203.                 }
  204.                 format(string, sizeof(string), "1,0 %s", PlayerNames);
  205.                 ircSay(BotSwitcher(), channel, string);
  206.             }
  207.         }
  208.     }
  209.     return 1;
  210. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement