SA-MP Forums Archive
How to make /changes in dialog - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: How to make /changes in dialog (/showthread.php?tid=376662)



How to make /changes in dialog - NinjaChicken - 11.09.2012

well basically in my server i have a /changes cmd and there are too many items to list so how can i have it so when someone types /changes a dialog pops up allowing them to scroll through them all?


Re: How to make /changes in dialog - clarencecuzz - 11.09.2012

When they do /changes can't you just show a msgbox, then have a button saying 'Next', and if they click it (response), then open the next /changes dialog?


Re: How to make /changes in dialog - RanSEE - 11.09.2012

Do you mean when player types /changes it show changes in your gamemode/server?
'You can use long dialog box for those.

pawn Код:
new mydialog[1612];
// Continue with strcat.

or

new mydialogstext[13][] = {
"1. Free Condoms now",
"2. Added Rape ",
"3. Added Anti Hack.",
"4. Gay detection",
"5. Added Porn Zones",
"6. Added Popcorn",
"7. Korean not allowed system",
"8. USA ",
"9. Spanish language",
"10.pooping",
"11. Plump ",
"12. Banana",

};
//continue with strcat...
You can always add a "Next" button, no matter how long the text is D:


Re: How to make /changes in dialog - clarencecuzz - 11.09.2012

Yes but he's saying that when he uses DIALOG_STYLE_MSGBOX, the input is too long and the message box goes off the screen, the only style with a scroll feature in my knowledge is the DIALOG_STYLE_LIST style, which wouldn't be very appealing as a 'Server Changes' feature. So the only real way to do it, is to use multiple dialogs.


Re: How to make /changes in dialog - Audiophr3ak - 11.09.2012

pawn Код:
#define DIALOG_CHANGES 1
public OnPlayerCommandText(playerid, cmdtext[])
{
    if(!strcmp(cmdtext, "/changes", true))
    {
        ShowPlayerDialog(playerid, DIALOG_CHANGES, DIALOG_STYLE_LIST, "Changes", "Item_1\ntem_2\ntem_3", "Select", "Close");
    }
    return 1;
}



Re: How to make /changes in dialog - clarencecuzz - 11.09.2012

What does that have to do with anything?