13.07.2012, 19:56
pawn Код:
CMD:procurados(playerid, params[])
{
static arm[500]; arm[0] = '\0';
static str[500]; str[0] = '\0';
static Nome[24]; Nome[0] = '0';
new count;
new preso[32];
for(new i=0;i<MAX_PLAYERS;i++) {
if(IsPlayerConnected(i){
if(procurado[i] > 0) {
count++;
GetPlayerName(i, Nome, sizeof(Nome));
if(Prisao[i]==1)preso="{00FF00}Sim";
if(Prisao[i]==0)preso="{FF0000}Nгo";
format(str, sizeof(str),"{FFFFFF}Nome: {FF0000}%s {FFFFFF}[%i] {FF0000}(Nнvel: %d) {FFFFFF}| Preso: %s{FFFFFF}\n", Nome, i, GetPlayerWantedLevel(i), preso);
strcat(arm, str);
}
}
if(count<=0)return ShowPlayerDialog(playerid, 10, DIALOG_STYLE_MSGBOX, "===== {FF0000}Procurados{FFFFFF} ======", "{00FF00}Nenhum suspeito online", "OK", "");
if(count>0)ShowPlayerDialog(playerid, 10, DIALOG_STYLE_MSGBOX, "===== {FF0000}Procurados{FFFFFF} ======", arm, "OK", "");
return 1;
}