public registerForm()
 {
     regClient = new DBClient();
     cryptSvc = new Crypto();
     newCustomer = new Customer();
     newAddress = new BillingAddress();
     InitializeComponent();
 }
 public ChangePasswdDialog(String uName)
 {
     userName = uName;
     passwdPasses = false;
     pwdClient = new DBClient();
     pwdCrypto = new Crypto();
     InitializeComponent();
 }
 public Dashboard(String uName)
 {
     Username = uName;
     loginClient = new DBClient();
     user = new Customer();
     player = new Player();
     user = this.loginClient.getCustomer(uName);
     player = this.loginClient.getPlayer(uName);
     InitializeComponent();
     this.usernameLbl.Text = user.getUserName();
     this.HealthLbl.Text = player.getVitality().ToString();
     this.DefenseLbl.Text = player.getDefense().ToString();
     this.SpeedLbl.Text = player.getSpeed().ToString();
     this.EXPLbl.Text = player.getExp().ToString();
     this.TotalPlayTimeLbl.Text = player.getPlaytime().ToString();
     this.ServerLbl.Text = player.getLastServer();
     this.TotalKillLbl.Text = player.getTotalKills().ToString();
     this.TotalDeathsLbl.Text = player.getTotalDeaths().ToString();
     this.WelcomeLbl.Text = String.Concat(this.WelcomeLbl.Text, user.getFullName() + '!');
 }
        private void loginBtn_Click(object sender, EventArgs e)
        {
            login = new DBClient();
            secureLogin = new Crypto();

            if (String.Compare(usernameField.Text, "") == 0)
            {

                MessageBox.Show("ERROR: Please enter a username.", "Gate of Gabethulu Launcher", MessageBoxButtons.OK, MessageBoxIcon.Error);
                return;

            }

            else if (login.verifyCredentials(usernameField.Text, secureLogin.generateSHA512PasswordHash(passwdField.Text)))
            {

                login.closeConnection();

                //STILL TRACING THE LACK OF USER NAME BACK TO ITS SOURCE  22222
                //THIS SEEMS TO WORK
                System.Diagnostics.Debug.WriteLine("Luncher usernameField.Text.ToSting() is: " + usernameField.Text.ToString());
                System.Diagnostics.Debug.WriteLine("Luncher usernameField.Text is: " + usernameField.Text);

                Dashboard mainWindow = new Dashboard(usernameField.Text.ToString());
                this.Visible = false;
                mainWindow.Show();

            }

            else
            {

                MessageBox.Show("ERROR:  Credentials not verified!", "Gate of Gabethulu Launcher", MessageBoxButtons.OK, MessageBoxIcon.Error);
                this.usernameField.Text = "";
                this.passwdField.Text = "";
                return;

            }
        }