Dialog_style_list new line
#1

How to make the name of the songs on new lines:

Код:
new SMusic[28];
        for(new i, j = sizeof(Songs); i < j; i++) format(SMusic, sizeof(SMusic), "%s\n", Songs[i][SongName]);
        ShowPlayerDialog(playerid, Dialog_Music, DIALOG_STYLE_LIST, "{0056b6}MUSIC PLAYER", SMusic, "Play", "Exit");
ON THE TOP

Код:
enum SInfo
{
    SongName[28],
    SongURL[200]
};
new Songs[][SInfo] =
{
    {"NameSong", "Link.mp3"},
    {"NameSong2", "Link2.mp3"}
 
};
now shows only the last song name.
Reply
#2

Oops

It's
format(SMusic, sizeof(SMusic), "%s%s\n",SMusic, Songs[i][SongName])
Reply
#3

What array have to make bigger? or?
Reply
#4

Yes, increase the size, probably 40-50 or anything depending on your usage
Reply
#5

I have around 200 songs..... do i have to make it 6000-7000?
Reply
#6

Are you going to display all those songs in the dialog?
Creating it to such a size might cause some problems
Reply
#7

Then what should i do?
Reply
#8

It's called pagination. If you browse a forum and it has 1000 topics, are all 1000 topics listed beneath each other? Of course not. There are several pages so only, say, 50 topics are displayed at once.
Reply
#9

oh. Yeah. Totaly forgot.
Thanks.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)