26.08.2015, 11:48
Hello, I have a problem, I want to make this command in dialogue, how can I do? I tried, did not work and lost the code I did, someone help me? worth more reputation!
PHP код:
if(strcmp(cmd, "/sought", true) == 0)
{
if(IsAMilitares(playerid))
{
if(OnDuty[playerid] != 1 && GetPlayerOrg(playerid) != 2) return SendClientMessage(playerid,COLOR_GRAD1,"ERROR: You do not hit your card.");
SendClientMessage(playerid,COLOR_YELLOW,"Wanted Government:");
for(new i=0; i < GetMaxPlayers(); i++)
{
if(IsPlayerConnected(i))
{
if(AccountData[i][pWantedLevel] > 0)
{
format(string, sizeof(string), "%s - Search Level: %d",GetPlayerNameRP(i),AccountData[i][pWantedLevel]);
SendClientMessage(playerid, -1, string);
}
}
}
return 1;
}
else SendClientMessage(playerid,COLOR_GRAD1,"ERRO: Restricted access only to military.");
return 1;
}