Is it hard to ad a new dialog box in my current register/login script
#1

Good morning all,
I have a question, and i'm hoping you can help me.

With the release of the current 0.3 samp version i noticed on a few servers a nice dialog box to register and login to a server.

I got a rpg server wich still uses a /register /login commands.
I would be nice if i can change the current /register /login commands. into a nice dialog box.
I already checked the wiki regarding dialog boxes, but can someone give a some tips how to adjust my /register commands into a box?

Thanks for your help!
Reply
#2

Its not really hard. You just need to know what your doing.

pawn Код:
DIALOG_STYLE_PASSWORD
is great to use its the same as DIALOG_STYLE_INPUT. but it replace a "*" when typing a letter or number

EDIT:

use this format to create dialog

pawn Код:
ShowPlayerDialog(playerid, dialogid, DIALOG_STYLE_xxx, "Tittle", "Inside the dialog", "Button1", "Button2");
you can define the dialogid by doing

pawn Код:
#define DIALOGTEST 1
pawn Код:
ShowPlayerDialog(playerid, DIALOGTEST, //othercodes here);
Use OnDialogResponse and copy your register and login function and put ondialogresponse should be like this

pawn Код:
if(dialogid == /* the id of your dialog */)
{
      //Your Register Function here
}

if(dialogid == /* the id of your dialog */)
{
     //Your Login Function Here
}
remember add this ondialogresponse
Reply
#3

Thanks you so much Joker

I will try this as soon im home!
Reply
#4

No Problem.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)