02.07.2009, 17:09
Hey,
I tried scripting command which would show online admins.. but I failed..
Here is the code:
It sends many messages to playerid... Any help?
I tried scripting command which would show online admins.. but I failed..
Here is the code:
pawn Код:
if(strcmp(cmdtext,"/admins",true)==0)
{
new AnyAdmins = 0;
for(new i; i<MAX_PLAYERS; i++)
{
new anames[24], string[256];
if (dUserINT(PlayerName(i)).("Adminlvl")>=1)
{
AnyAdmins = 1;
GetPlayerName(i,anames,24);
}
if (AnyAdmins == 1)
{
SystemMsg(playerid,"Admins Online:");
format(string,256,"%s ",anames);
SystemMsg(playerid,string);
}
else
{
SystemMsg(playerid,"No Admins Online");
}
}
return 1;
}