06.03.2014, 05:30
I'm having a little problem with this code;
And here's names.txt
It prints everything perfectly. But it only shows player4 in the dialog.
pawn Код:
if(fexist("names.txt"))
{
new File:pname = fopen("names.txt");
new str[128];
new string[400];
while(fread(pname, string))
{
format(str,sizeof(str), "%s\n", string);
printf("%s", str);
ShowPlayerDialog(playerid, 1, DIALOG_STYLE_LIST, "Players", str, "Ok", "Cancel");
}
fclose(pname);
}
Код:
player1 player2 player3 player4