Blank Button.
#1

Hello. I have to report this BUG.

When the dialogue is too much character and it is empty the button shows up as "".



pawn Код:
CMD:topgangs(playerid, params[])
{
    new
        id,
        resp[8],
        nazwa[32],
        DBResult:result,
        dialog[3000] = " ** Lista gangуw: **\n"
    ;

    result = db_query(Global, "SELECT `name`, `respect` FROM `Gangi` ORDER BY `respect` DESC LIMIT 40");

    do
    {
        id++;
        db_get_field(result, 0, nazwa, sizeof(nazwa));
        db_get_field(result, 1, resp, sizeof(resp));
        format(dialog, sizeof dialog, "%s\n\t{FFFF00}%d. %s\t\t\t{FAEAA9}p. %s", dialog, id, nazwa, resp);
    }
    while(db_next_row(result));

    format(dialog, sizeof dialog, "%s\n___________________________________", dialog);
    ShowPlayerDialog(playerid, DIALOG_INFO, DIALOG_STYLE_MSGBOX, "Top Gangуw", dialog, "", "Zamknij");

    db_free_result(result);
    return 1;
}
It is suggested to fix it in version 0.3d
This is done intentionally or something wrong in my code?
Does anyone understand what I mean?
Reply
#2

Lol...

Код:
ShowPlayerDialog(playerid, DIALOG_INFO, DIALOG_STYLE_MSGBOX, "Top Gangуw", dialog, "", "Zamknij");
Do you notice the "" I've just highlighted in Red? That's your reason.
Reply
#3

The first button mustn't be null. If you want to use single button you must put that button as the first button, instead of the second one.
Reply
#4

Ok, thanks..
To close.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)