How to add new admin names? (Roleplay)
#1

Hey Guys I need some help, How To add new admin names? ex. is Junior admin, General Admin, senior admin, these are the defaults. I want to make Like Elite admin on level/rank 5 can someone help me?I don't want to rename.
Reply
#2

Post a code with your current ranks.
Reply
#3

No need, I just want to make new one, on lvl 5 will be developer rank
Reply
#4

pawn Код:
If(PlayerInfo[playerid][pAdmin] == 5)format(string, sizeof(string),"Elite Admin  %s : %s",GetPlayerNameEx(playerid), params);
Here's an Example
Reply
#5

pawn Код:
if(PlayerInfo[playerid][pAdmin] == 5) format(name, sizeof(name), "Elite Admin");
Reply
#6

Quote:
Originally Posted by Jizz
Посмотреть сообщение
pawn Код:
if(PlayerInfo[playerid][pAdmin] == 5) format(name, sizeof(name), "Elite Admin");
Dear Sir,That is completely wrong,you use The Format function wrongfully and also this will just set his name to elite admin instead of his real name.
Reply
#7

Something like this?

pawn Код:
stock AdminLevelToName(playerid)
{
    new admin[128];
    switch(pInfo[playerid][Admin])
    {
        case 0:
        {
            admin = "Normal Player";
        }
        case 1:
        {
            admin = "Trustee";
        }
        case 2:
        {
            admin = "Moderator";
        }
        case 3:
        {
            admin = "Admin";
        }
        case 4:
        {
            admin = "Head Admin";
        }
        case 5:
        {
            admin = "Owner";
        }
    }
    return admin;
}
(Edit pInfo enum with your own).

When you want show the admin name in /stats do:

pawn Код:
new string[128];
format(string,sizeof(string),"Admin Name: %s",AdminLevelToName(playerid);
SCM(playerid,-1,string);
Reply
#8

Quote:
Originally Posted by Face9000
Посмотреть сообщение
Something like this?

pawn Код:
stock AdminLevelToName(playerid)
{
    new admin[128];
    switch(pInfo[playerid][Admin])
    {
        case 0:
        {
            admin = "Normal Player";
        }
        case 1:
        {
            admin = "Trustee";
        }
        case 2:
        {
            admin = "Moderator";
        }
        case 3:
        {
            admin = "Admin";
        }
        case 4:
        {
            admin = "Head Admin";
        }
        case 5:
        {
            admin = "Owner";
        }
    }
    return admin;
}
(Edit pInfo enum with your own).

When you want show the admin name in /stats do:

pawn Код:
new string[128];
format(string,sizeof(string),"Admin Name: %s",AdminLevelToName(playerid);
SCM(playerid,-1,string);
Yeah, But I want to make a new one with different level and name like if 5 is not used. I'll make it Developer rank but How?
Reply
#9

Quote:
Originally Posted by DouglasRamirez
Посмотреть сообщение
Yeah, But I want to make a new one with different level and name like if 5 is not used. I'll make it Developer rank but How?
Just change the name between ""

So if someone is level 5 remove "Owner" and replace with "Developer" or something.
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)