Jump to content
  • 0
Sign in to follow this  
Rafaly

YCMD:admins

Question

Salutare! As dorii sa aflu si eu cum as putea sa creez un Tag permanent pentru admini sau / si vipi.(Fondator NUME: Salut,Owner: NUME : Salut)si cum pot adauga la comanda admins rankul fiecarui nivel de admin in parte!

Va las aici comanda sa va fie mai usor.Multumesc anticipat !

YCMD:admins(playerid, params[], help) {
    new string[128];
    format(string, sizeof(string), "---------------- Admini conectati ----------------");
    SCM(playerid, COLOR_SERVER, string);
    if(PlayerInfo[playerid][pAdmin] < 1) {
        foreach(PlayerAdmins, i) {
            if(PlayerInfo[pScripter] > 0) format(string, sizeof(string), "(%d) %s - %s", i, PlayerInfo[pUsername], PlayerInfo[pAdmin] < 8 ? ("Scripter") : ("Fondator"));
            format(string, sizeof(string), "(%d) %s - admin level %d", i, PlayerInfo[pUsername], PlayerInfo[pAdmin]);
            SCM(playerid, -1, string);
        }
    }
    else {
        foreach(PlayerAdmins, i) {
            if(GetPVarInt(i, "Cover") == 1) format(string, sizeof(string), "(%d) %s - admin level %d [afk: %d] [cover: %s]", i, PlayerInfo[pUsername], PlayerInfo[pAdmin], AFKSeconds, GetName(i));
            else if(Spectate != 255) format(string, sizeof(string), "(%d) %s - admin level %d [afk: %d] [spec: %s]", i, PlayerInfo[pUsername], PlayerInfo[pAdmin], AFKSeconds, GetName(Spectate));
            else format(string, sizeof(string), "(%d) %s - admin level %d [afk: %d]", i, PlayerInfo[pUsername], PlayerInfo[pAdmin], AFKSeconds);
            SCM(playerid, -1, string);
        }        
    }
    SCM(playerid, COLOR_SERVER, "--------------------------------------------------------");
    SCM(playerid, COLOR_WHITE, "Daca ai vreo problema, poti folosi /report. Pentru intrebari legate de joc poti folosi /n.");    
    SCM(playerid, COLOR_SERVER, "--------------------------------------------------------");
    return true;
}

 

Share this post


Link to post
Share on other sites

4 answers to this question

Recommended Posts

  • 0

Cu o functie simpla.
 

stock GetRankAdmin( rank )
{
    new Rankname[ 55 ];

    switch( rank )
    {
        case 0: Rankname = "Player";
        case 1: Rankname = "Junior-Admin";
        case 2: Rankname = "Senior-Admin";
        case 3: Rankname = "Head Admin";
        case 4: Rankname = "Master-Admin";
        case 5: Rankname = "Co-Fondator";
        case 6: Rankname = "Fondator";
        case 7: Rankname = "Scripter";
    }
    return ( Rankname ) ;
}

O folosesti in sintaxa asa: GetRankAdmin(PlayerInfo[playerid][pAdmin]). Ex:
 

new string[64];
format(string, sizeof(string), "%s %s a dat 15000$.", GetRankAdmin(PlayerInfo[playerid][pAdmin]), GetName(playerid));

Sper ca te-am ajutat.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...

Important Information

This site uses cookies. By continuing browsing, you agree to the use of this information. For more details, see Terms of Use and Privacy Policy.