Skill coding of chance chains

Before I start, I'll clarify the term "chance chains" in the title. This simply means there's a chance-based property in the skill and, if that succeeds, another chance property pops up.

For instance, programming my skill, Protective Light, beyond the initial heal is getting difficult, because I also want it to cure a random debuff state present on the targeted ally. If this succeeds, I then want it to do a 25% chance to remove another random debuff state. Of course, this has to adhere to how many states are on the target at once.

Will this require a script/plugin to do?
yes and no.

there are ways to do this without a plugin, but they are tedious and limiting. So if you have a lot of such effects, a custom plugin might be better.

1) it could be done by damage coding, placing ifs into the damage formula of the skill.
However, that is complex and the damage formula has a limited length for entering code.

2) your skill could call a common event, and in that event you could handle the chances and the additional effects.
Unfortunately by default common events attached to skills are executed at the end of the battleturn, not when the skill is executed.

and as said the only alternative to these two options is a custom plugin.
yes and no.

there are ways to do this without a plugin, but they are tedious and limiting. So if you have a lot of such effects, a custom plugin might be better.

1) it could be done by damage coding, placing ifs into the damage formula of the skill.
However, that is complex and the damage formula has a limited length for entering code.

2) your skill could call a common event, and in that event you could handle the chances and the additional effects.
Unfortunately by default common events attached to skills are executed at the end of the battleturn, not when the skill is executed.

and as said the only alternative to these two options is a custom plugin.

@1, I agree with this; encountered that problem with entering code for two effects with long formulas

@2, this shouldn't be a concern for me as I use Yanfly's turn battle plugins so the turn ends when the skill is selected (or in the case of ATB, when the turn bar turns 100% red). I think a loop or a chain of conditional branches may be needed.

Original thread: https://forums.rpgmakerweb.com/threads/skill-coding-of-chance-chains.91374/