Beispiel #1
0
        private void CalculateDamageRange(MapleItemType itemType, int primaryStat, int secondaryStat, int atk, int damR, bool isFighter)
        {
            WeaponInfo weaponInfo     = ItemConstants.GetWeaponModifierInfo(itemType);
            double     damageModifier = weaponInfo.DamageModifier;

            if (isFighter)
            {
                damageModifier += 0.10;
            }
            int baseMaxDamage = (int)Math.Ceiling(damageModifier * (4 * primaryStat + secondaryStat) * (atk / 100.0f));

            MaxDamage = (int)((damR / 100.0) * baseMaxDamage);
            MinDamage = (int)(((weaponInfo.BaseMastery + MasteryR) / 100.0) * MaxDamage);
        }