SA-MP Forums Archive
Making these dialogs with "Next Page" and "Close" - 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: Making these dialogs with "Next Page" and "Close" (/showthread.php?tid=495135)



Making these dialogs with "Next Page" and "Close" - rakshith122 - 16.02.2014

Hello People,
I recently was looking on the "dcmd_adcmds" on SFCRRPG gamemode. I added a bunch of commands to that gamemode.

Code:
Removed temporarily
Now, I would like to make "Next Page", if the player clicks on it, half of the commands would be showed in a new dialog on "Next Page" window.
Like when the player clicks on "Next Page" on the screen, it should show the next page of the remaining commands.
Hope you understand,
Thanks in advance.


Re: Making these dialogs with "Next Page" and "Close" - Cvnnor - 16.02.2014

Place this code in OnDialogResponse under the dialog id that you're using for each rule set. I would recommend changing up the ID's of the dialog's (for example: DIALOG_A1CMD & DIALOG_A2CMD) to make it easier to navigate however it's not needed. If you don't get what I am saying then just reply and I will write it out for you.

pawn Code:
if(response) // checks to see if user clicked next page
{
     // ShowPlayerDialog function goes here and then do all that good stuff in OnDialogResponse
}



Re: Making these dialogs with "Next Page" and "Close" - rakshith122 - 16.02.2014

i may try this now. i had an idea of doing this before, but i wanted to ask some people advice about it.
I'll inform if something doesn't work good.
Thanks.


Re: Making these dialogs with "Next Page" and "Close" - rakshith122 - 16.02.2014

But wait, There are 6 admin levels, how can you make next page for each and every level?


Re: Making these dialogs with "Next Page" and "Close" - Cvnnor - 16.02.2014

Send me the current command script and I will write it for you


Re: Making these dialogs with "Next Page" and "Close" - CuervO - 16.02.2014

Show the same dialog id at all times, change the text it displays based on the player page (you can save it in a variable), then increase the page variable each time the player responds to the dialog.

https://sampwiki.blast.hk/wiki/OnDialogResponse
https://sampwiki.blast.hk/wiki/ShowPlayerDialog


Re: Making these dialogs with "Next Page" and "Close" - rakshith122 - 16.02.2014

I actually fixed it now. Before your reply, half of it was done, now its 100% done.
Thanks for your help both!