new kFile[256];
new string235[2012];
for(new i; i < MAX_RACES; i ++)
{
format(kFile, sizeof(kFile), "/initest/%s.ini", RaceListName[i]);
while(strcmp(RaceListName[i]))
{
strcat(string235, RaceListName[i], sizeof(string235));
}
}
ShowPlayerDialog(playerid,10729,DIALOG_STYLE_MSGBOX,"Ini Names",string235,"Close","");
The only way to list the files in a directory (well, not the only way, but the only way that doesn't hang your PC for several hours) is using a plugin such as y_files:
https://sampforum.blast.hk/showthread.php?tid=177028 If you follow the chain of links (I should really fix that), you end up here for an example: https://sampforum.blast.hk/showthread.php?tid=60282 |