Hermes
dziwki kola gramy w lola
Hello.
I am trying to get how these formulas are working. I mean something like this:
the part in source concerned with this:
there are four values. I think those are mina, minb, maxa, maxb and eventually minc, maxc. But what's the real order? Why are there two value for min and max damage :f.
Any ideas?
@edit
setAttackFormula from functions.lua
Best regards,
Hermes
I am trying to get how these formulas are working. I mean something like this:
Code:
setAttackFormula(combat, COMBAT_FORMULA_LEVELMAGIC, 6.5, 6.5, 5.5, 7.5)
Code:
case FORMULA_LEVELMAGIC:
{
min = (int32_t)((player->getLevel() / minl + player->getMagicLevel() * minm) * 1. * mina + minb);
max = (int32_t)((player->getLevel() / maxl + player->getMagicLevel() * maxm) * 1. * maxa + maxb);
if(minc && std::abs(min) < std::abs(minc))
min = minc;
if(maxc && std::abs(max) < std::abs(maxc))
max = maxc;
player->increaseCombatValues(min, max, params.useCharges, true);
return true;
......
Any ideas?
@edit
setAttackFormula from functions.lua
Code:
function setAttackFormula(combat, type, minl, maxl, minm, maxm, min, max)
local min, max = min or 0, max or 0
return setCombatFormula(combat, type, -1, 0, -1, 0, minl, maxl, minm, maxm, -min, -max)
end
Best regards,
Hermes
Last edited: