[Ajuda] /admins nao aparece no serve ;-; - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: Non-English (
https://sampforum.blast.hk/forumdisplay.php?fid=9)
+--- Forum: Languages (
https://sampforum.blast.hk/forumdisplay.php?fid=33)
+---- Forum: Português/Portuguese (
https://sampforum.blast.hk/forumdisplay.php?fid=34)
+---- Thread: [Ajuda] /admins nao aparece no serve ;-; (
/showthread.php?tid=562296)
/admins nao aparece no serve ;-; -
VinnyScript - 08.02.2015
Код:
CMD:admins(playerid, params[])
{
new MyStr[100];
new bool: ademir;
for(new i, PP = GetMaxPlayers(); i < PP; ++i)
{
if(PlayerInfo[i][Admin] >= 1)
{
ademir = true;
new PlayerNami[24];
GetPlayerName(i,PlayerNami,MAX_PLAYER_NAME);
format(str, sizeof(str),"{80FF00}%s [ID:{FFFF00}%d{80FF00}] Level:{FFFF00}%d\n",PlayerNami,i,PlayerInfo[i][Admin]);
new CBDStrLength = strlen(MyStr);
strins(MyStr, str, CBDStrLength);
}
}
if(!ademir)
return ShowPlayerDialog(playerid,12,DIALOG_STYLE_MSGBOX,"Admins","{FF0000}Temos Nenhum Administrador Online!\nCaso Ver Algum Cheaters Denuncie\nEm Nossa Comunidade\nEquipe-cbd.blogspot.com.br","Ok","");
ShowPlayerDialog(playerid,13,DIALOG_STYLE_MSGBOX,"Admins",MyStr,"OK","");
return 1;
}
Ajudem pfv
Re: /admins nao aparece no serve ;-; -
best95 - 08.02.2015
Tente aumentar a string do CMD... talvez resolva!!
Re: /admins nao aparece no serve ;-; -
MultiKill - 08.02.2015
Sу um jogador no servidor com admin, jб ocupa umas 80 cйlulas da string MyStr, aumente as cйlulas da string, e explique melhor o que estб acontecendo.
Re: /admins nao aparece no serve ;-; -
PT - 08.02.2015
PHP код:
CMD:admins(playerid, params[])
{
new MyStr[100], str[150], bool: ademir = false, PlayerNami[MAX_PLAYER_NAME];
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(PlayerInfo[i][Admin] != 0)
{
GetPlayerName(i,PlayerNami,MAX_PLAYER_NAME);
format(str, sizeof(str),"{80FF00}%s [ID:{FFFF00}%d{80FF00}] Level:{FFFF00}%d\n",PlayerNami, i, PlayerInfo[i][Admin]);
strcat(MyStr, str, sizeof(MyStr));
ademir = true;
}
}
if(ademir == false)
return ShowPlayerDialog(playerid,12,DIALOG_STYLE_MSGBOX,"Admins","{FF0000}Temos Nenhum Administrador Online!\nCaso Ver Algum Cheaters Denuncie\nEm Nossa Comunidade\nEquipe-cbd.blogspot.com.br","Ok","");
else ShowPlayerDialog(playerid, 13, DIALOG_STYLE_MSGBOX, "Admins", MyStr, "OK", "");
return 1;
}