otland/forgottenserver — pull request #711 by raymondtfr (2014-04-05 18:23:39+00:00)
Title: Patch 001

Replacing skills and attack params in monster files for min and max params. Also updated melee formula.

The old formula was too broken, and its damages calculation were lower than current tibia.
This is a simpler formula and adds methods already known and confirmed in Tibia, like the level power (level/5), etc. It also matches tibiastats formula for melee attacks (knights only).

http://www.tibia-stats.com/index.php?akcja=meleDmgCalc
Max dmg: 462

With the old formula, for level 100, skill 100, and 50 weapon attack
((2 * (attackValue * (attackSkill + 5.8) / 25 + (level - 1) / 10.)) / attackFactor);
((2 * (50 * (100 + 5.8) / 25 + (100 - 1) / 10)) / 1) = 443 MAX dmg

Just a curiosity, why is the 'dot operator' included in this old formula, can I call it this way at this context? for what reason it is there?
Thanks in advance.

((0.0885 * (attackValue * attackSkill) + (level / 5)) / attackFactor); = 462
((0.0885 * (50 * 100) + (100 / 5)) / 1) = 462 MAX dmg