Esempio n. 1
0
        internal void HandleLevelUp(BaseClass equippedClass, BaseCharacter currentBC)
        {
            STATChart   tempStatAddition = null;
            ClassPoints tempCP           = null;

            #region
            if (statAddition != null)
            {
                try
                {
                    tempStatAddition = statAddition.ExtractStatChart();
                }
                catch (Exception)
                {
                }
            }

            if (classPoints != null)
            {
                try
                {
                    tempCP = ClassPoints.toClassPoints(classPoints);
                }
                catch (Exception)
                {
                }
            }
            #endregion
            #region
            if (tempStatAddition != null)
            {
                try
                {
                    equippedClass.classStats.AddStatChartWithoutActive(tempStatAddition);
                }
                catch (Exception)
                {
                }
            }

            if (tempCP != null)
            {
                try
                {
                    equippedClass.AddPoints(tempCP);
                }
                catch (Exception)
                {
                }
            }
            #endregion

            additionStat   = tempStatAddition;
            additionPoints = tempCP;
            TBAGW.Utilities.ExpGainScreen.levelUpInfo = this;
        }