Skill based on DEF debuff.

Hello.

I'm setting up a skill where the atk formula is multiplied by the debuff stack.

With the current formula I'm getting "no damage taken".

I have 2 skills:

1. Add debuff [DEF] 5 turns (reduces DEF by 1 each time)

2. a.atk*4*b.param_min(DEF) - b.def*2

If anyone can suggest the best way to set this up that would be great.

EDIT:

I worked it out.

1st skill: adds debuff and has a common event that adds 1 to variable

2nd skill: multiplies damage formula by variable and has a common event that sets variable to 0.

Original thread: https://forums.rpgmakerweb.com/threads/skill-based-on-def-debuff.23903/