So I have a boss that applies a state to himself; when this state is applied, it sets a variable to a value of 5. Each time the boss is attacked while this state is active, the variable decreases by 1. I have achieved this using a state notetag from the VisuStella Battle Core:
So that's all well and good...but here's the thing. One of my party members has a damaging skill that has a scope of 4 Random Enemies. The boss is the only target in this fight, so he gets hit 4 times, and the variable decreases by 4, 1 for each hit. I don't want that to happen, I want it to only decrease by 1, period, for each attack skill used on him, regardless of the number of hits the skill does. Is there a convenient way, either through the base engine or through VisuStella plugins, to make that happen?
JavaScript:
<JS Post-Damage As Target>
if (value > 0) {
$gameVariables.setValue(1, $gameVariables.value(1) - 1);
}
</JS Post-Damage As Target>
So that's all well and good...but here's the thing. One of my party members has a damaging skill that has a scope of 4 Random Enemies. The boss is the only target in this fight, so he gets hit 4 times, and the variable decreases by 4, 1 for each hit. I don't want that to happen, I want it to only decrease by 1, period, for each attack skill used on him, regardless of the number of hits the skill does. Is there a convenient way, either through the base engine or through VisuStella plugins, to make that happen?