14.08.2016, 20:05
Hi I'm making a command to see the online admins on the server , this is the code
Then to try it in the server gives me so

What I want is when the player put / admins, you show admins who are connected as in the picture below

Thank you for your attention and your help
Код:
CMD:admins(){
new string[256];
new fstring[64];
for(new i=0; i<MAX_PLAYERS; i++)
{
if(Admin[playerid]>= 0)
{
GetPlayerName(i,adminname, sizeof(adminname));
format(fstring, sizeof(fstring),"%s (%i) - {FF0000}Level: %i{FFFFFF}\n", adminname, i,Admin[playerid]);
strcat(string, fstring, sizeof(string));
}
}
ShowPlayerDialog(playerid,1,DIALOG_STYLE_MSGBOX,"Online Admins",string,"OK","");
return 1;
}
Then to try it in the server gives me so

What I want is when the player put / admins, you show admins who are connected as in the picture below

Thank you for your attention and your help


