Alignment Dialog
#1

Hello,
i wrote this code:
pawn Код:
#include <a_samp>

new Text[][] = {//Is not constant text
    "Something",
    "Something else",
    "Other"
};

new Text2[][] = {
    "Yes",
    "No",
    "Yes"
};

public OnPlayerSpawn(playerid)
{
    new string[256];
    for(new i;i<sizeof(Text);i++)
    {
        strcat(string,Text[i]);
        if(strlen(Text[i]) < 4) strcat(string,"\t");
        if(strlen(Text[i]) < 8) strcat(string,"\t");
        if(strlen(Text[i]) < 12) strcat(string,"\t");
        if(strlen(Text[i]) < 16) strcat(string,"\t");
        strcat(string,Text2[i]);
        strcat(string,"\n");
    }
    ShowPlayerDialog(playerid,0,DIALOG_STYLE_LIST,"Caption",string,"OK","Cancel");
    return 1;
}
dialog looks like this:

But I need to look like this:

how to do it using tabs?
Reply


Messages In This Thread
Alignment Dialog - by ATomas - 18.03.2014, 13:17
Re: Alignment Dialog - by MP2 - 18.03.2014, 19:36

Forum Jump:


Users browsing this thread: 1 Guest(s)