I used a damage formula in ace and trying to copy it to my mv project it does not work just giving me a error
"Failer to execute 'createLineGradient' on 'CanvasRenderingContext2D': float parameter 3 is non-infinitive"
Here is my damage formula so any help is appriciated.
a.atk * 3 + a.mat * 0.2 + ((a.atk * 1 + a.level)/32) * ((a.atk * 1 * a.level*1)/32) - b.def * 1
Edit
Ohh now i see where the problem is, on my vxa i got a different attack for enemies and as enemies do not have level it gives me the error as i am yet to give the enemy its own attack.
I'm having some trouble with the battle forumla, and it just occurerd to me that maybe what I want to do it can't be done.
Is it possible to store the ID of the caster into a variable?
I tried something like:
v[1]=a.id; a.atk * 4 - b.def * 2
If the ID is correct then it should trigger a common event, but nothing happens, so am I missing something or just it can't be done?
I have an idea for a few skills that I are meant to "hit" multiple times, depending on the attacker's Agility versus the target's. As an example, one skill is called "Six Slaps," with the following formula:
( a.atk * 6 - b.def * 4 )
What I want it to do is as follows: For every 3 (past the first three) Agility the user has more than the target, the final damage done is multiplied. E.g., if the use has 76 Agility and the target has 70 (6 more greater than the target's), then the damage will be doubled (2x damage). Having 79 Agility against the same target (9 greater) would result in triple damage, 82 in quadruple, 85 in quintuple, and finally 88 (18 greater) would result in sextupled damage. However, if the user only has 1-3 more Agility than their target, if both battlers have equal Agility, or if the target's Agility is higher, then the damage would be multiplied by 1 / wouldn't be changed and work as the above formula.
The other skills I have in mind have different "hit caps" from Six Slaps, so I figure just one formula could easily have numbers swapped to suit the other skills. How can I achieve my goal(s) in a damage formula?
How would I add a state to the entire party while damaging the enemy?
EG: Phoenix skill (similar to FF7). Deals damage to the enemy, adds autolife state to allies.
ok, first of all i read through like 10 pages ... then got lazy x, x
i wanted to make a potion that heals both HP and MP, i dont know what the damage formula would look like ....
i tried something like 80;a.gainmp(15) but it keeps doing zero damage.
also i want a potion that does random heal, i kept getting same results, the formula is x=math.randomint(20)+20;80+x;x
im not sure where i went wrong =\ , any help is appreciated xD
@Balako: You don't need a damage formula if the HP and MP gain is fixed. Just add gain MP as a feature (box under the damage formula), select gain MP, and enter the fixed amount. Also works for % of max MP. Similar for HP if HP gain is fixed.
Hi everyone! I'm trying to work out how my formula should work. What I have now is:
0.9*Math.floor(Math.sqrt(a.atk*a.atk*a.atk*(Math.pow(0.5, b.def*0.02)))
The problem is, in its' current form, it deals constant 0 damage when it shouldn't (20 ATK vs 10 DEF means it should deal ~75 DMG). It worked in VXA in the following form:
0.9*(Math.sqrt(a.atk*a.atk*a.atk*(0.5**(b.def*0.02))).to_i)
What am I doing wrong? Should there be more spaces?
Hello eveyone I'm trying to use a very simple formula I think; so please if anyone can help me...
Math.round($gameVariables[2] * 0.75) + a.atk * 4 - b.def * 2
This so far is the basic layout, however as Variable 2 is going to be increased constantly in the game I want put a lmit to the bonus damage like.
if Variable 2 > 700 then the bonus should stay at 700 even if the varibale is something like 1250
I hope I made myself clear and that someon can help me.