Double damage depending on state?

I tried using the formula below from VX ace in MV but it doesn't work, I wanted it so that the attack using the formula gets double damage against poisoned targets what does it need to be for MV?


b::state?(2) ? a.atk * 8 - b.def * 2 : a.atk * 4 - b.def * 2
Well, there is a pinned topic for damage formulas, but...


your problem is that many commands changed between the versions.


try


b.isStateAffected(2) ? a.atk * 8 - b.def * 2 : a.atk * 4 - b.def * 2

Original thread: https://forums.rpgmakerweb.com/threads/double-damage-depending-on-state.70425/