[POMOC]Dialog

Započeo [Samp-School]Vaskeâ„¢, Maj 14, 2012, 17:04:24 POSLE PODNE

prethodna tema - sledeća tema

0 članova i 1 gost pregledaju ovu temu.

Skripta koju koristim: Balkan Exotic(EDIT)
Problem: Hocu da napravim jedan dialog za listu admina do 4 lvl a neznam kako da ih stavim u onaj prozorcic.Druga stvar je to da ne zelim da budu ispisana imena Head Admina Vlasnika...itd ili Gamemastera e sad kako to da napravim.

Jel zelis komandu kada se kuca npr./admini da izadje imena admina i koji nisu online ili imena svih admina koji su na srv :(

Zelim listu online admina ali samo do 4 lvl .Ne zelim imena Gamemastera i lvl 1338,itd.
if (strcmp(cmd, "/admini", true) == 0)
{
        if(IsPlayerConnected(playerid))
    {
        SendClientMessage(playerid, COLOR_RED, " ");
        SendClientMessage(playerid, COLOR_RED, "Lista Admina");
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
    if(PlayerInfo[i][pAdmin] >= 1 && PlayerInfo[i][pAdmin] < 1341)
    {
        new admtext[64];
          if(PlayerInfo[i][pAdmin] == 4) { admtext = "Admin lvl 4"; }
        else if(PlayerInfo[i][pAdmin] == 3) { admtext = "Admin lvl 3"; }
else if(PlayerInfo[i][pAdmin] == 2) { admtext = "Admin lvl 2"; }
else if(PlayerInfo[i][pAdmin] == 1) { admtext = "Admin lvl 1"; }
else { admtext = "Gamemaster"; }
GetPlayerName(i, sendername, sizeof(sendername));
if(AdminDuty[i] == 0)
{
format(string, 256, "%s ( %s )", sendername, admtext);
SendClientMessage(playerid, COLOR_WHITE, string);
}
else
{
    format(string, 256, "%s ( %s )", sendername, admtext);
SendClientMessage(playerid, COLOR_YELLOW, string);
}
}
}
}
}
return 1;

Probaj ovako :if (strcmp(cmd, "/admins", true) == 0 || strcmp(cmd, "/admini", true) == 0)
{
        if(IsPlayerConnected(playerid))
    {
        SendClientMessage(playerid,COL_RED, "ADMINISTRACIJA");
foreach (Player, i)
{
    if(PlayerInfo[i][pAdmin] >= 1 && PlayerInfo[i][pAdmin] < 1338)
    {
    new admtext[256];
     if(PlayerInfo[i][pAdmin] == 4) { admtext = "4"; }
else if(PlayerInfo[i][pAdmin] == 3) { admtext = "3"; }
else if(PlayerInfo[i][pAdmin] == 2) { admtext = "2"; }
else if(PlayerInfo[i][pAdmin] == 1) { admtext = "1"; }
else { admtext = "1"; }
GetPlayerName(i, sendername, sizeof(sendername));
if(AdminDuty[i] == 1)
{
    format(string, 256, "{F81414}[NA DUZNOSTI]Admin: {FFFFFF}%s | {00C0FF}Level: {FFFFFF}", sendername, admtext);
ShowPlayerDialog(i, 999, DIALOG_STYLE_MSGBOX,"{F81414}Administracija",string,"U redu","");
}
else
{
format(string, 256, "{F81414}Admin: {FFFFFF}%s | {00C0FF}Level: {FFFFFF}%s ", sendername, admtext);
ShowPlayerDialog(i, 998, DIALOG_STYLE_MSGBOX,"{F81414}Administracija",string,"U redu","");
}
}
}
}
return 1;
}