OnDialogResponse.
#1

I have a dialog list, and one of them is 'Next Page'.

Under OnDialogResponse, how could i make it so it would know it is selecting 'Next Page'?

I tried this.

if(inputtext == "Next Page")
{
//blabla.
}

Got an error.

So how could i do that?

-----------

And also, in the same list, i have these:

Username (earnt $0)
username (earnt $0)
username (earnt $0).
etc .. about 12 of them (These are loaded from mysql databases)

How could i make it onDialogResponse, it only tracks 'username', and not the space after it?

Thanks.
Reply
#2

firstly use [ pawn] [ /pawn] 2ndly i will help with your first problem
if it is DIALOG_STYLE_LIST or DIALOG_STYLE_MSGBOX
use this
pawn Код:
if(dialogid == DIALOGHERE)
{
if(response)
{
switch(listitem) //the player has press next page
{
ShowPlayerDialog(playerid,dialogid,DIALOG_STYLE_...,DIALOGNAME,etc);
}
}
}
hope i helped
Reply
#3

Quote:
Originally Posted by vassilis
Посмотреть сообщение
firstly use [ pawn] [ /pawn] 2ndly i will help with your first problem
if it is DIALOG_STYLE_LIST or DIALOG_STYLE_MSGBOX
use this
pawn Код:
if(dialogid == DIALOGHERE)
{
if(response)
{
switch(listitem) //the player has press next page
{
ShowPlayerDialog(playerid,dialogid,DIALOG_STYLE_...,DIALOGNAME,etc);
}
}
}
hope i helped
I've fixed it myself, thanks for helping, although that code would not work at all, since in the dialog, has 12 rows above 'next page'.

thanks though.
Reply
#4

Sorry, either you misread or i didn't type out what i needed.

It's dynamic, it's from mysql. I need to get the username from the row, so it can't be static (like the one you showed me.)

Thanks ..
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)