22.03.2012, 14:03
Hello, i tried to make a list dialog, but it aint working right.It should list all of the sorts from file but it will show only first one.
Код:
CMD:weedsorts(playerid, params[]) { if(IsPlayerConnected(playerid)) { if(PlayerInfo[playerid][pAdmin] == 0) { SendClientMessage(playerid,COLOR_GRAD2,"You are not authorized to use this command!"); return 1; } for(new r = 0; r <= MAX_WEEDS; r++) { new fstring[256]; new string[256]; format(fstring, sizeof(fstring),"Sort: %s\n",WeedInfo[r][wSort]); strcat(string, fstring, sizeof(string)); ShowPlayerDialog(playerid,DIALOG_MANAGEWEED+4,DIALOG_STYLE_LIST,"Weed Sorts",string,"Ok","Cancel"); } } return 1; }