Dialog popping up
#1

Well there is a dialog(originaly made by cuervo in raven's RP) where you have to accept terms to join the server, EVERY time you connect..and after that Login or Register dialog pops up.. And I can't find a way to remove it entirely from the script...
you can find that dialog by searching for "Prihvaćam"..

Also I created function ShowVideo which should be few textdraws before login thing, but previously mentioned dialog bugs it..

http://pastebin.com/pHzhTG8s
Reply
#2

Just remove the ShowPlayerDialog line and put your ShowVideo there ?
Reply
#3

Quote:
Originally Posted by Nero_3D
Посмотреть сообщение
Just remove the ShowPlayerDialog line and put your ShowVideo there ?
but when I remove that dialog, notthing appears because it needs authentication that you accepted those terms

EDIT: I edited it a bit, and somehow it worked, but now my textdraws don't show up..
I also got a problem with timer, it doesn't delay that dialog from popping up
Reply
#4

There's probably a public called, try calling that public.
Reply
#5

Quote:
Originally Posted by maramizo
Посмотреть сообщение
There's probably a public called, try calling that public.
Can you write example code?
Reply
#6

Should be somewhat like this :
pawn Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
    if(dialogid == 1)
    {
        if(!response) return SendClientMessage(playerid, 0xFFFFFFFF, "You canceled!"); Kick(playerid);
        if (response == 1)
        {
            SendClientMessage(playerid, 0xFFFFFFFF, "You agreed to the terms");
            PublicCallBackHere(playerid); // Should be something like this
            return 1;
    }
    return 0;
}
Reply
#7

Quote:
Originally Posted by maramizo
Посмотреть сообщение
Should be somewhat like this :
pawn Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
    if(dialogid == 1)
    {
        if(!response) return SendClientMessage(playerid, 0xFFFFFFFF, "You canceled!"); Kick(playerid);
        if (response == 1)
        {
            SendClientMessage(playerid, 0xFFFFFFFF, "You agreed to the terms");
            PublicCallBackHere(playerid); // Should be something like this
            return 1;
    }
    return 0;
}
Finaly I managed to bypass the s***...

and can you tell me why doesn't my timer delay function?
pawn Код:
public ShowVideo(playerid)
{
    if(PlayerStep[playerid] == 1)
    {
        TextDrawShowForPlayer(playerid, Textdraw5);
        TextDrawShowForPlayer(playerid, Textdraw101);
        TextDrawShowForPlayer(playerid, Textdraw101);
        TextDrawShowForPlayer(playerid, Textdraw102);
        TextDrawShowForPlayer(playerid, Textdraw103);
        TextDrawShowForPlayer(playerid, Textdraw104);
        TextDrawShowForPlayer(playerid, Textdraw105);
        TextDrawShowForPlayer(playerid, Textdraw106);
        TextDrawShowForPlayer(playerid, Textdraw107);
        PlayerStep[playerid] = 2;
        ShowVideo(playerid);
        SetTimerEx("PlayerStep", 10000, false, "i", playerid);
        return true;
    }
    else if(PlayerStep[playerid] == 2)
    {
        ShowPlayerDialog(playerid, 1246, DIALOG_STYLE_INPUT,"Dobrodoљao, Molimo te da se Registriraљ","Napiљi lozinku da bi se Registrirao.","Registriraj","Napusti");
    }
    return 1;
}
timer suppose to delay PlayerStep 2 from initiating.. but it keeps failing
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)