PDA

View Full Version : add more dialogs


GabiXx
29/11/2016, 11:55 PM
I want to add 2 more dialogs after that on register about player sex and email you know..
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
switch( dialogid )
{
case DIALOG_REGISTER:
{
if (!response) return Kick(playerid);
if(response)
{
if(!strlen(inputtext)) return ShowPlayerDialog(playerid, DIALOG_REGISTER, DIALOG_STYLE_PASSWORD, ""COL_WHITE"Registering...",""COL_RED"Ai introdus o parola gresita.\n"COL_WHITE"Scrie o parola pentru a te inregistra.","Register","Quit");
new INI:File = INI_Open(UserPath(playerid));
INI_SetTag(File,"data");
INI_WriteInt(File,"Password",udb_hash(inputtext));
INI_WriteInt(File,"Cash",0);
INI_WriteInt(File,"Admin",0);
INI_WriteInt(File,"Kills",0);
INI_WriteInt(File,"Deaths",0);
INI_WriteInt(File,"Skin",0);
INI_Close(File);
GivePlayerMoney(playerid,10000);
SetPlayerColor(playerid,0xFFFFFFAA);
SetSpawnInfo(playerid,0,PlayerInfo[playerid][pSkin],1283.5896,-1329.5938,13.3824,89.6460,0,0,0,0,0,0);
SpawnPlayer(playerid);
}
}
How i proced? :D

TheRohlikar
30/11/2016, 12:48 AM
after "SpawnPlayer" use "ShowPlayerDialog (https://wiki.sa-mp.com/wiki/ShowPlayerDialog)" function

GabiXx
30/11/2016, 01:03 AM
I want the dialog when he register man, after the dialog with passwor to appear dialog with sex (m/f) and email, no after spawning

TheRohlikar
30/11/2016, 01:14 AM
You have "SpawnPlayer" after clicking button in regsiter dialog, not me. :)

GabiXx
30/11/2016, 01:20 AM
So where i have to add the dialogs and after this to get spawned?

Micko123
30/11/2016, 06:22 AM
You know you made 5 posts in no more than one hour??