SA-MP Forums Archive
The player spawn before the dialog is being called - 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: The player spawn before the dialog is being called (/showthread.php?tid=424247)



The player spawn before the dialog is being called - Don_Cage - 21.03.2013

Where should i put this
pawn Код:
if(PlayerInfo[playerid][pTut] == 0)
            {
                new Tut[] = "1\tI am male!\n2\tI am female!";
                ShowPlayerDialog(playerid, 5013,DIALOG_STYLE_LIST,"So,Are you a male or female?",Tut,"Select","Cancel");
            }
in order to make it show the player while he is still "spectating" ?


Respuesta: The player spawn before the dialog is being called - Xabi - 21.03.2013

Inside the callback OnPlayerConnect(playerid)


Re: The player spawn before the dialog is being called - dusk - 21.03.2013

OnPlayerConnect, then as soon as he connects, he will see the dialog, and only then spawn


Re: The player spawn before the dialog is being called - Don_Cage - 21.03.2013

but the dialog is suposed to be seen after he login but before he spawn and if i put it in OnPlayerConnect it will be seen as soon as he connects and not after he have typed his password and login right?


Respuesta: Re: The player spawn before the dialog is being called - Xabi - 21.03.2013

Quote:
Originally Posted by Don_Cage
Посмотреть сообщение
but the dialog is suposed to be seen after he login but before he spawn and if i put it in OnPlayerConnect it will be seen as soon as he connects and not after he have typed his password and login right?
Then you should make the new dialog after you check the password/login is correct, which will be still in the callback OnPlayerConnect(playerid).


Re: The player spawn before the dialog is being called - Don_Cage - 21.03.2013

I put it last in onplayerconnect and it still show before i have logged in


Respuesta: Re: The player spawn before the dialog is being called - Xabi - 21.03.2013

Quote:
Originally Posted by Don_Cage
Посмотреть сообщение
I put it last in onplayerconnect and it still show before i have logged in
You should put it under the dialog response where it checks if the login/password is correct or not.


Re: The player spawn before the dialog is being called - Don_Cage - 21.03.2013

Could you show me on team viewer please?


Respuesta: The player spawn before the dialog is being called - Xabi - 21.03.2013

Put your login/password check function here, and I edit that to fit your needs.


Re: The player spawn before the dialog is being called - Konstantinos - 21.03.2013

After they log in, show the dialog and when they response, spawn them.