11.03.2011, 12:23
can you help me ?
Im using LA-RP btw and i want to add gamesters & admins in dialog.
Here is command:
Im using LA-RP btw and i want to add gamesters & admins in dialog.
Here is command:
pawn Код:
if (strcmp(cmd, "/admins", true) == 0 || strcmp(cmd, "/admini", true) == 0)
{
if(IsPlayerConnected(playerid))
{
SendClientMessage(playerid, COLOR_YELLOW, " ");
SendClientMessage(playerid, COLOR_GREEN, "-|Admins|-");
foreach (Player, i)
{
if(PlayerInfo[i][pAdmin] >= 1 && PlayerInfo[i][pAdmin] < 1341 || PlayerInfo[i][pGm] >=1)
{
new admtext[64];
if(PlayerInfo[i][pAdmin] == 1340) { admtext = "Vlasnik"; }
else if(PlayerInfo[i][pAdmin] == 1339) { admtext = "Suvlasnik"; }
else if(PlayerInfo[i][pAdmin] == 1338) { admtext = "Admin Level 6"; }
else if(PlayerInfo[i][pAdmin] == 1337) { admtext = "Admin Level 5"; }
else if(PlayerInfo[i][pAdmin] == 4) { admtext = "Admin Level 4"; }
else if(PlayerInfo[i][pAdmin] == 3) { admtext = "Admin Level 3"; }
else if(PlayerInfo[i][pAdmin] == 2) { admtext = "Admin Level 2"; }
else if(PlayerInfo[i][pAdmin] == 1) { admtext = "Admin Level 1"; }
else if(PlayerInfo[i][pGm] == 1) { admtext = "GameMaster"; }
else { admtext = "Gamemoderator"; }
GetPlayerName(i, sendername, sizeof(sendername));
if(AdminDuty[i] == 1)
{
format(string, 256, "%s ( %s )", sendername, admtext);
SendClientMessage(playerid, COLOR_YELLOW, string);
}
else if(GmDuty[i] == 1)
{
format(string, 256, "%s ( %s )", sendername, admtext);
SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
}
else
{
format(string, 256, "%s ( %s )", sendername, admtext);
SendClientMessage(playerid, COLOR_WHITE, string);
}
}
}
}
return 1;
}