2010-06-25, 06:47 AM
50504724 Wrote:only the red part have something error.
I assumed that it may have a special calculate order:
1) calculate the max Damage ,with the stat and weapon Multiplier.
2) round it.
3) multiply rounded Max Damage by mastery, and round it. That is Min Damage.
So 1430.348~1833.779 --> ? ~1834 --> 1834*0.78 ~ 1834 --> 1430.52 ~ 1834 --> 1431 ~ 1834
Makes sense to me:
Code:
int* CalculateDamage(int weaponType, int primaryStat, int secondaryStat)
{
int maxDamage;
int minDamage;
maxDamage = (int) CalculateMaxDamage(weaponType, primaryStat, secondaryStat);
minDamage = CalculateMinDamage(maxDamage);
}The max damage gets converted to an integer when returned from CalculateMaxDamage.
| Weapon Type | Multiplier |
|---|---|
| 1H Sword | 1.10 |
| 1H Axe | 1.10 |
| 1H BW | 1.10 |
| Dagger | 1.30 (str + dex) |
| Wand | 0.88 |
| Staff | 0.88 |
| 2H Sword | 1.28 |
| 2H Axe | 1.26 |
| 2H BW | 1.27 |
| Spear | 1.49 |
| Polearm | 1.49 |
| Bow | 1.15 |
| Crossbow | 1.35 |
| Claw | 2.00 |
| Knuckler | ??? |
| Gun | 1.60 |
Only Knucklers left!
