Exemplo n.º 1
0
        private void PopulateControls()
        {
            this.Invalidate();
            UnbindEventHandlers();

            if (Enum.IsDefined(typeof(Enums.Class), _character.ClassID))
            {
                cmbClass.DataSource    = GetClassDataSource();
                cmbClass.SelectedValue = _character.ClassID;
            }
            else
            {
                cmbClass.Text = _character.ClassID.ToString();
            }

            // Set eternal seals before level, since level's range is restricted by eternal seals
            numEternalSeals.Maximum = Model.Character.MaxEternalSealsUsed;
            numEternalSeals.Value   = _character.FixEternalSealsUsed();
            numLevel.Maximum        = _character.GetTheoreticalMaxLevel();
            numLevel.Value          = _character.FixLevel();

            numInternalLevel.Value = _character.InternalLevel;
            numExperience.Value    = _character.Experience;
            numBoots.Value         = Model.Character.FixBoots(_character.Boots);

            BindEventHandlers();
            this.Refresh();
        }
        private void PopulateControls()
        {
            UnbindEventHandlers();

            // Set eternal seals before level, since level's range is restricted by eternal seals
            numEternalSeals.Maximum = _character.GetMaxEternalSealsUsed();
            numEternalSeals.Value   = _character.FixEternalSealsUsed();
            numLevel.Maximum        = _character.GetTheoreticalMaxLevel();
            numLevel.Value          = _character.FixLevel();

            numInternalLevel.Value = _character.InternalLevel;
            numExperience.Value    = _character.Experience;
            //numBoots.Value = Model.Character.FixBoots(_character.Boots);

            BindEventHandlers();
        }