Posts: 227
Threads: 53
Joined: Apr 2013
Reputation:
0
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.
Posts: 288
Threads: 42
Joined: Jun 2009
Reputation:
0
Post a code with your current ranks.
Posts: 227
Threads: 53
Joined: Apr 2013
Reputation:
0
No need, I just want to make new one, on lvl 5 will be developer rank
Posts: 3,351
Threads: 780
Joined: Jan 2010
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);
Posts: 3,351
Threads: 780
Joined: Jan 2010
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.