Show online admins [+REP]
#1

Hello, I need command where will be showed all online admins.
Reply
#2

plz use search bar there are alot of commands you will find
Reply
#3

Yes. I searched, but I find only with levels...
Reply
#4

What to you want to show ?

Admin connected with RCON ?

Or admin without RCON ?

If it's without RCON you can do something like this: ( adapt it with your GM):

Код:
CMD:onlineadmin(playerid, params[])
{
	if(pInfo[playerid][Admin] > 1)
	{
		new string[50];
		SendClientMessage(playerid, -1, "Online admin are:");
		foreach(new i : Player)
		{
			if(pInfo[i][Admin] >= 1)
			{
				GetPlayerName(i, joueurdestinataire, sizeof(joueurdestinataire));
				format(string, sizeof(string), "%s | Admin Level: %d", joueurdestinataire, pInfo[i][Admin]);
				SendClientMessage(playerid, -1, string);
			}
		} 
		return 1;
	}
	return SendClientMessage(playerid, Rouge,"Unknown command");
}
Reply
#5

pawn Код:
CMD:admins(playerid, params[])
{
foreach(Player, i) {
if(IsPlayerAdmin(i))
{
SendClientMessage(playerid, -1, "Online Admins:");
format(string, sizeof(string), "Admin %s - ID %d.", GetName(i), i);
SendClientMessage(playerid, -1, string);
}
}
return 1;
}
Untested.
Reply
#6

Quote:
Originally Posted by anou1
Посмотреть сообщение
What to you want to show ?

Admin connected with RCON ?

Or admin without RCON ?

If it's without RCON you can do something like this: ( adapt it with your GM):

Код:
CMD:onlineadmin(playerid, params[])
{
	if(pInfo[playerid][Admin] > 1)
	{
		new string[50];
		SendClientMessage(playerid, -1, "Online admin are:");
		foreach(new i : Player)
		{
			if(pInfo[i][Admin] >= 1)
			{
				GetPlayerName(i, joueurdestinataire, sizeof(joueurdestinataire));
				format(string, sizeof(string), "%s | Admin Level: %d", joueurdestinataire, pInfo[i][Admin]);
				SendClientMessage(playerid, -1, string);
			}
		} 
		return 1;
	}
	return SendClientMessage(playerid, Rouge,"Unknown command");
}
Thanks +Rep
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)