Dialog returns to the first dialog in secs.
#1

hello everyone. Im tring to script a driving license system. I tried to script in such a way that when i enter the pickup i placed in the diving school itll show me the dialog where it asks mee whether i want to take a theory test or practical.
Everything is fine but i have only prob i.e. it returns back to the first dialog (he theory or practical test options) in 1 sec. i need help with that.



P.S- i had to delete it as i just changed the server to MySQL and i didnt know how to setup the driving things and all.
so i dont have the code atm
Reply
#2

Until y post the code.

UN officially:

Thread Locked
Reply
#3

Until you post the code.

UN officially:

Thread Locked
Reply
#4

Can you show your on dialogresponses? and the dialogs needed for this.
Reply
#5

Код:
if(dialogid == 3)
{
       ShowPlayerDialog(playerid, 4, DIALOG_STYLE_LIST, "Drivingschool:", "Take theory test\n take practical test", "Ok", "Cancel");
        return 1;
}
if(dialogid == 4)
{
      if(responce)
        {
         switch(listitem)
               {
                case 0:
                      {
                       ShowPlayerDialog(playerid, 5, DIALOG_STYLE_LIST, "Which side of the road should you drive?", "Left\nRight","Ok","Cancel");
                       }
                case 1:
                     {
                      SendClientMessage(playerid, red, "WIP");
                      }
                 }
         }
       else
          {
          SendClientMessage(playerid, red, "You cancelled");
          }
return 1;
}
if(dialogid == 5)
{
          if(responce)
           {
            switch(listitem)
                       {
                        case 0:
                               {
                                SendClientMessage(playerid, red, "wrong");
                               }
                         case 1:
                                {
                                 SendClientMessage(playerid, green, "You've got your license");
                                 dlic[playerid]=1;
                                 }
                        }
             }
             else
             {
              SendClientMessage(playerid, red, "You cancelled");
             }
return 1;
}
Reply
#6

Quote:
Originally Posted by THE_KNOWN
Посмотреть сообщение
Код:
if(dialogid == 3)
{
       ShowPlayerDialog(playerid, 4, DIALOG_STYLE_LIST, "Drivingschool:", "Take theory test\n take practical test", "Ok", "Cancel");
        return 1;
}
if(dialogid == 4)
{
      if(responce)
        {
         switch(listitem)
               {
                case 0:
                      {
                       ShowPlayerDialog(playerid, 5, DIALOG_STYLE_LIST, "Which side of the road should you drive?", "Left\nRight","Ok","Cancel");
                       }
                case 1:
                     {
                      SendClientMessage(playerid, red, "WIP");
                      }
                 }
         }
       else
          {
          SendClientMessage(playerid, red, "You cancelled");
          }
return 1;
}
if(dialogid == 5)
{
          if(responce)
           {
            switch(listitem)
                       {
                        case 0:
                               {
                                SendClientMessage(playerid, red, "wrong");
                               }
                         case 1:
                                {
                                 SendClientMessage(playerid, green, "You've got your license");
                                 dlic[playerid]=1;
                                 }
                        }
             }
             else
             {
              SendClientMessage(playerid, red, "You cancelled");
             }
return 1;
}
Help?
Reply
#7

First if all, its response, not responce

Second, remove the returns 1 after each dialog, you dont need that.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)