Quote:
Originally Posted by [Full]Garfield[XDB]
tenta:
pawn Код:
dcmd_admins(playerid, params[] { #pragma unused params for(new i = 0; i < GetMaxPlayers(); ++i) { if(IsPlayerConnected(i))//PlayerInfo[v][Level] > 1 { if(IsPlayerAdmin(i)) { new string[128], Nome[MAX_PLAYER_NAME] ; GetPlayerName(i, Nome, sizeof(Nome)); format(string, sizeof(string),"Adminstradores On-Line:%s\n",Nome); SendClientMessage(playerid, AZUL, string); PlayerPlaySound(playerid, 1083, 0.0, 0.0, 0.0); } else { SendClientMessage(playerid, COR,"Nenhum Adminstrador Connectedd."); } else { SendClientMessage(playerid, COR,"Nenhum Adminstrador Connectedd."); } } return 1; }
|
So ta dando 500x "Nenhum administrador conectted", mas fora isso Ok :P. Se pude me dizer como solucionar, vlws P:
CODIGO FICOU ASSIM:
pawn Код:
dcmd_admins(playerid, params[])
{
#pragma unused params
for(new i = 0; i < MAX_PLAYERS; ++i)//for(new i = 0; i < GetMaxPlayers(); ++i)
{
if(IsPlayerConnected(i))//PlayerInfo[v][Level] > 1
{
if(PlayerInfo[i][Level] > 1)
{
new string[128],Nome[MAX_PLAYER_NAME]; GetPlayerName(i, "Nome", MAX_PLAYER_NAME);
format(string, sizeof(string),"Adminstradores On-Line:%s\n",Nome);
SendClientMessage(playerid, AZUL, string); PlayerPlaySound(playerid, 1083, 0.0, 0.0, 0.0);
}
}
else
{
SendClientMessage(playerid, AZUL,"Nenhum admin online");
}
}
return 1;
}