MV Is there a "Loop until..." sort of command for Yanfly's Action Sequences?

I wanted to make it so that a skill doesn't stop attacking until a certain variable has been reached. I can't seem to find a loop command for that and I don't even want to just keep copy-pasting the same sequence over and over, as that would just be very unwieldy. Oh, and the cap's stat-dependent; if you have more agility, the more you attack, so theoretically it can go on for hundreds of times.
There's a loop for action sequences extension here:

There's a loop for action sequences extension here:

i'm glad an extension for this was already made years ago. seems i didn't search hard enough. thanks ;w;
There's a loop for action sequences extension here:

actually, i just tested the plugin and fell into an error
1777001279874.png


the skill's sequence:
Code:
<damage formula>
    var rawDamage = target.isStateAffected(2) === true ? ((user.atk*1.25)-target.def)*(user.luk/10000+1) : (((user.atk*1.25)-target.def)*(user.luk/10000+1))*target.elementRate(5);
    var value = Math.round(rawDamage);
</damage formula>

<setup>
    display action
    immortal: targets, true
    move user: target, front base, 1, offset x -24
</setup>

<target>
    eval: user._hitCap = user.agi;
    eval: user._hitCounter = 0;
    action animation
    motion thrust: user, no weapon
    while user._hitCounter < user._hitCap
        action effect
        if value > 0
            se: play enemy damage
            motion damage: target
        else
            motion evade: target
        end
        wait: 10
        eval: user._hitCounter += 12;
    while end
    wait: 40
</target>

<finish>
    immortal: targets, false
    move user: home, 1
    face user: forward
</finish>

<follow>
    clear battle log
</follow>

<Post-Damage Eval>
    var rawDamage = target.isStateAffected(2) === true ? (((user.atk*1.25)-target.def)*(user.luk/10000+1))*target.elementRate(1) : ((((user.atk*1.25)-target.def)*(user.luk/10000+1))*target.elementRate(5))*target.elementRate(1);
    value <= 0 ? 1 : target.isStateAffected(2) === true ? target.gainMp(-Math.round(rawDamage)) : target.gainMp(-Math.round((rawDamage/target.elementRate(5))*target.elementRate(6)));
    if (target.mp <= 0 && target.isStateAffected(2) == false)
        target.addState(2);
</Post-Damage Eval>
i've tried everything i could think off to try and rid of this error, like ridding of the nested if statement, using in-game variables instead of evals, moving the plugin far below the list, and all seem to return to this error regardless

i don't know what's the reason why
Don't know if it's the reason, but instructions tell you to write 'END WHILE', but you've written 'while end'
You could also test if some other plugins are interfering. But yeah, I haven't used that extension myself.
Don't know if it's the reason, but instructions tell you to write 'END WHILE', but you've written 'while end'
You could also test if some other plugins are interfering. But yeah, I haven't used that extension myself.
oh right, i actually switched up the two. it works now 😅

Original thread: https://forums.rpgmakerweb.com/threads/is-there-a-loop-until-sort-of-command-for-yanflys-action-sequences.183363/