Jabantiz wrote:Code to show SpellDamage takes the same params
Either I have no idea what you're talking about, or you're not taking the time to read what I am saying
I'm not suggesting there be 1 parameter for function cast(). cast should still be (Target, Caster, Type, Min, Max).
When we call SpellDamage, it is done like
SpellDamage(Target, Type, Amount), and that is 1 value of damage based on a math.random() we did in LUA - not in C++. I do not want to random between 2 values in C++ (for this specific type of min/max) unless you're telling me there is no other way to do it.
If SpellHeal is a copy/paste of SpellDamage, then this is how SpellHeal should already work. If this is how SpellHeal works, cool - then back to my original question of why it's SpellHeal("Heal", HealAmt, HealAmt) when that is NOT how SpellDamage() is called.
It should be SpellHeal(Target, "Heal", Amount) -- period. Where Amount = math.random(Min, Max), or just like the SpellDamage example:
Code: Select all
SpellHeal(Target, HealType, math.random(MinHeal, MaxHeal))
Are we having 2 different conversations? Cuz that never happens
