Dialogs aren't working
#1

For some reason the "register" dialog isn't working.. but the "login" one works fine. The dialog or the text don't even show up.
http://mj.pastebin.com/m37c50a64
Help please..
Reply
#2

pawn Код:
public OnPlayerRequestClass(playerid, classid)
{
//      new string[126];
        PlayerPlaySound(playerid, 1068, 0.0, 0.0, 0.0);
        PlayerInfo[playerid][pModel] = Peds[classid][0];
        SetPlayerCameraPos(playerid, 404.1285,-1482.6891,95.8624);
        SetPlayerCameraLookAt(playerid, 331.3541,-1518.4325,55.5734);
        SetPlayerPos(playerid, 328.2976,-1514.4808,34.1154);
        //PlayerPlaySound(playerid, 1187, 0.0, 0.0, 0.0);
        PlayerInfo[playerid][pModel] = Peds[classid][0];
        SetPlayerTeamFromClass(playerid,classid);
        if (RegistrationStep[playerid] == 0 && gPlayerLogged[playerid] != 1)
        {
               ClearChatbox(playerid, 10);
               //format(string, sizeof(string), "Welcome to Los Santos Life Roleplay. Please proceed to logging in or registering.");
               //SendClientMessage(playerid, COLOR_YELLOW, string);
               if (gPlayerAccount[playerid] == 1)
               {
                  new loginstring[128];
                  new loginname[64];
                  GetPlayerName(playerid,loginname,sizeof(loginname));
                  format(loginstring,sizeof(loginstring),"Welcome, %s\nThat name is registered.\nYou can now login:",loginname);
                  ShowPlayerDialog(playerid,12346,DIALOG_STYLE_INPUT,"Login",loginstring,"Login","Exit");
           SendClientMessage(playerid, COLOR_GREEN, "____________________________________________________");
           SendClientMessage(playerid, COLOR_GREY, "Welcome back to Los Santos Life Roleplay! Please enter");
           SendClientMessage(playerid, COLOR_GREY, "your password in the box below, and then click 'login'!");
           SendClientMessage(playerid, COLOR_GREEN, "____________________________________________________");
      }
      else if (gPlayerAccount[playerid] == 0)
      {
           new regstring[128];
           new regname[64];
           GetPlayerName(playerid,regname,sizeof(regname));
           format(regstring,sizeof(regstring),"Welcome, %s\nYou dont have an account.\nPlease register:",regname);
           ShowPlayerDialog(playerid,12345,DIALOG_STYLE_INPUT,"Register",regstring,"Register","Exit");
       SendClientMessage(playerid, COLOR_GREEN, "______________________________________________________________");
           SendClientMessage(playerid, COLOR_GREY, "Halt! You do not have an account registered in our databse!");
           SendClientMessage(playerid, COLOR_GREY, "Please type your password in the box below, and then click 'register'");
           SendClientMessage(playerid, COLOR_GREEN, "______________________________________________________________");
        }
    }
    return 1;
}
Fix the indentation.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)