unknow command [+rep]
#1

i have a problem with this command

pawn Код:
CMD:members(playerid, params[])
{
    if(PlayerData[playerid][Group] >= 0)
    {
        new string[1024];
        for(new i = 0; i < MAX_PLAYERS; i++)
        {
            if(IsPlayerConnected(i))
            {
                if(PlayerData[i][Group] == PlayerData[playerid][Group])
                {
                    format(string, sizeof(string), "%s\n%s (%s)", string, GetPlayerNameEx(i), GetPlayerGroupRank(i));
                }
            }
        }
        ShowPlayerDialog(playerid, 9999, DIALOG_STYLE_LIST, "Member(s) online", string, "OK", "");
    }
    else return SendClientMessage(playerid, COLOR_WHITE, "You are not in a faction.");
    return 1;
}
it's show me unknow command
plz help
Reply
#2

Код:
CMD:members(playerid, params[])
{
      new string[128], wmsg[1028] = "";
      if(PlayerData[playerid][Group] == 0) return SendClientMessage(playerid, -1, "You are not in a Faction.");
      for(new I = 0; I < MAX_PLAYERS; I++)
      {
             if(IsPlayerConnected(I))
             {
                        if(PlayerData[I][Group] == PlayerData[playerid][Group])
                        {
                                     format(string, sizeof(string), "%s - %s\n", GetPlayerNameEx(I), GetPlayerGroupRan(I));   
                                     strcat(wmsg, string);
                                     ShowPlayerDialog(playerid, 9999, DIALOG_STYLE_LIST, "Member(s) online", wmsg, "OK", "");
                       }
            } 
     }
     return 1;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)