While it might be possible to do that in the damage formula, as has been mentioned several times by myself, and yanfly, do not do things like this in the damage formula. Adding scripts to the damage formula causes those scripts to happen unexpectedly during combat when AI controlled allies or enemies are trying to determine what skill to use. When skills have the same priority, some degree of randomness decides what they use, but sometimes the deciding factor is the amount of damage the skill would do, which is tested. The test would cause the script to happen, regardless of whether the skill ended up being used or not.
You're going to want to use Yanfly's SkillCore, or the Visustella Skill Core plugins to achieve this effect via an <after damage eval> from the skills notetags.
You're going to want to use Yanfly's SkillCore, or the Visustella Skill Core plugins to achieve this effect via an <after damage eval> from the skills notetags.
