Admins list dialog
#2

pawn Код:
new
        Rank[ 40 ],
        msgColor,
        Duty[ 10 ]
        count,
        str[ 128 ]
    ;
    Inter_SendClientMessage(playerid, green, " ");
    Inter_SendClientMessage(playerid, green, "___________ |- Online Admins -| ___________");
    Inter_SendClientMessage(playerid, green, " ");

    for ( new i = 0 ; i < MAX_PLAYERS ; ++ i ) {
        if (!IsPlayerConnected( i )) continue;
        if (AccInfo[i][Hide]) continue;
        if (AccInfo[i][Level] < 1) continue;
        if (!IsPlayerAdmin(i)) {
            switch (AccInfo[i][Level]) {
                case 1: {
                    Rank = "Basic Moderator";
                    msgColor = Color_Basic_Moderator;
                }
                case 2: {
                    Rank = "Moderator";
                    msgColor = Color_Moderator;
                }
                case 3: {
                    Rank = "Master Moderator";
                    msgColor = Color_Master_Moderator;
                }
                case 4: {
                    Rank = "Administrator";
                    msgColor = Color_Administrator;
                }
                case 5: {
                    Rank = "Master Administrator";
                    msgColor = Color_Master_Administrator;
                }
                default: {
                    Rank = "Professional Admin";
                    msgColor = Color_Professional_Admin;
                }
            }
        }
        else Rank = "RCON Administrator";
       
        if (AccInfo[i][OnDuty]) Duty = "Playing";
        else Duty = "On Duty!";
       
        format( str , 128 , "Level: %d - %s (Id:%i) | %s | %s", AccInfo[i][Level] , PlayerName2(i) , i , Rank , Duty );
        Inter_SendClientMessage( playerid , msgColor , str );
       
        count ++;
   
    }

    if ( count < 1 ) {
        Inter_SendClientMessage(playerid,red,"No admin online in the list");
        Inter_SendClientMessage(playerid, green, " _______________________________________");
    }
Reply


Messages In This Thread
Admins list dialog - by [LoS]YoUnG_KiD - 23.08.2012, 14:02
Re: Admins list dialog - by ReVo_ - 23.08.2012, 14:54
Re: Admins list dialog - by [LoS]YoUnG_KiD - 24.08.2012, 04:07
Re: Admins list dialog - by Shetch - 24.08.2012, 04:15
Re: Admins list dialog - by [KHK]Khalid - 24.08.2012, 04:55
Re: Admins list dialog - by Shetch - 24.08.2012, 04:56

Forum Jump:


Users browsing this thread: 2 Guest(s)