MV Yanfly Action Sequence: Enemy attack works, but enemy heal doesn't.

Hi folks,
I'm at my wits end here, pretty much ripping my hair out at this point. It's late, and I'm tired and I'm not sure if I can coherently explain the problem I am having clearly, but I'll try my best.
All I want is for an enemy's healing skill to repeat itself 5 times after the enemy casts it. The reason why I have it set up this way is that each time it repeats it has a random chance of applying 1 stack of a healing state. So basically at the end of the skill, the enemy could have 1 stack of additional healing or if they were lucky, 5 stacks.
Now, vanilla, this works perfectly except 1 small problem...the healing animation only plays once. But the actual number calculations work as intended.

Now, see, that same enemy has a similar skill, except this time targeting the player. The skill repeats itself 3 times, each time has a random chance of applying a damage stack.
Again vanilla, this works fine other than the animation only playing 1 time.

That's where I turned to the action sequence plugin thing. After reading through the wiki page, I applied this to the enemy attack:
<whole action> action animation wait: 10 action animation: mirror wait: 10 action animation </whole action>
And voila, now it works perfectly. Damages player, animations match up, and has a random chance to apply 0 - 3 stacks.

So tell me...why is it when I applied effectively the exact same lines (except extending it to match the 5 repeats for the healing skill) everything is not working right?
The healing effect: gone. They don't heal any more. The states: well, funny thing, one time I got it to...sort of work? Well, it only applied 1 state (during testing I set the state to have 100% chance to apply, so...it should have been 5 stacks, not 1 - I even let it do the skill multiple times in case something funny happened the first time to see if it applied more than 1 stack the second and third time, but no.) But after some more fiddling, I couldn't even get that 1 state to show up. I'm really at a loss how it can differ between healing and damaging.
Anyways, nonetheless, here's the notetag that doesn't work:
<whole action> action animation wait: 10 action animation: mirror wait: 10 action animation wait: 10 action animation: mirror wait: 10 action animation </whole action> <finish action> action effect </finish action>
(for the record, about the addition of the action effect. I added this line after plenty of testing with just the original 5 lines of action animation and wait. Originally the action effect was inside the whole action section, but for testing, I moved it to the finish action section)

Now, funny thing about this whole action sequence adventure...I could have sworn by default RPG Maker would automatically repeat animations when using the "invocation: repeat" function within the editor. I loaded up an older game of mine that used this function, and sure enough in that game it repeated animations by default. At a later point in that game's life I updated it with just a few plugins and the later version of that old game is now ALSO missing the vanilla function of repeating animation.
The weird thing is, I opened up the project file and outright deleted the plugins to see if I could restore the old functionality...but uh...it didn't. That old game is only using Yanfly plugins...so...I don't want to go pointing fingers....but it's a little sus to me.
I don't really want to use the action sequence plugin, but since the vanilla function of repeated animations seems to have been stripped from my project, it seems like the only choice, and after spending about an hour to an hour and a half just trying to get this healing animation to work properly I'm feeling a little miffed...I'm also probably cranky from it being so late.

So...I don't know, I hope someone has some advice or can give me an idea of what to try next in troubleshooting this, because I just don't know what to try any more. And it's late. Good night.

p.s.
forgot to mention I also opened up a demo project included in an animation pack I purchased, saw that it was using yanfly plugins (just the main core and battle core) and tested the repeat animations thing in that demo game and noticed it too is missing the vanilla functions. So, somehow, I think yanfly's plugins are outright stripping the function from the project (as I mentioned, even deleting the plugins from the project didn't restore the vanilla function)
All I want is for an enemy's healing skill to repeat itself 5 times after the enemy casts it.
I think you can do this just by having 5 action effect lines, e.g. (untested):

<target action> perform action motion wait: user action animation wait for animation action effect action effect action effect action effect action effect </target action>
I.e. "step forward/swing/whatever; wait for that motion to complete; play the animation [on the target]; wait for that; apply the effect to the target 5 times". If the skill's scope is "All Allies" or "All Enemies", you may need to replace <target action> (per target) with <whole action> (per action).

If you don't specify one (or more) stages of an action sequence, the default stage(s) will be used:
In case it helps, for a single-target item/skill I believe these are the default phases with motion waiting enabled, i.e. the actions used when none are specified via notetags:
Spoiler
Code:
<setup action>
clear battle log
display action
immortal: targets, true
perform start
wait for movement
cast animation
wait for animation
</setup action>

<target action>
perform action
motion wait: user
action animation
wait for animation
action effect
death break
</target action>

<follow action>
</follow action>

<finish action>
immortal: targets, false
wait for new line
clear battle log
perform finish
wait for movement
wait for effect
action common event
</finish action>
If the item/skill scope is "all allies" or "all enemies", it'll use <whole action> instead of <target action>.

Also, <finish action> is designed for cleanup, e.g. return to home position and removal of temporary immortality. If you want something to happen after the main stuff, consider <follow action> instead.
I think you can do this just by having 5 action effect lines, e.g. (untested):

<target action> perform action motion wait: user action animation wait for animation action effect action effect action effect action effect action effect </target action>

[snip]
Hey! Thanks for the informative reply. So I gave it a test, and it's at an acceptable state, though still not perfect.
It does target all allies, so first I tried moving it to the whole action section. What I noticed here is that the random chance of applying a stack is working....but it applies the same number of stacks to all allies. So for example, if it rolls 3 stacks, then all allies now have 3 stacks. The way I intend for it to work is each ally gets a random stack.

So, I tried moving it to the target action section again. Here, the calculations work properly. As in, each target gets their own individual roll of healing stacks. One might get 2, the other might get 3. However, here, the animations start to break down again.
In this form, it would first play 1 animation on the caster. It would partially calculate the numbers, and then resume the other 4 animations on the rest of the enemy's party.

That brings me to the final iteration I have now; so I moved 2 parts of the script into whole action section while leaving the majority in target action.
It's probably better to show then tell, so here's how I have it set up now:
<whole action> perform action motion wait: user </whole action> <target action> action animation wait: 10 action animation: mirror wait: 10 action animation wait: 10 action animation: mirror wait: 10 action animation action effect action effect action effect action effect action effect </target action>

So the reason this is imperfect is because the animations basically work in 2 steps. First it does all 3 cast animations on the user. A pause. Then it casts all 5 animations on the allies. So, it's animated correctly, the numbers work correctly, which I would say is acceptable. However, it would be nice if the animations happened at the same time for the user and allies rather than having a brief pause between user and allies.
I'll continue testing, but I'm still open to ideas.
Cast animations are part of the default <setup action>:

<setup action> clear battle log display action immortal: targets, true perform start wait for movement cast animation wait for animation </setup action>
I'm thinking you could override the default <setup action> to move cast animation out of there and into the appropriate place in <target action>. Maybe like this?
Spoiler: action sequence
<setup action> clear battle log display action immortal: targets, true perform start wait for movement </setup action> <whole action> perform action motion wait: user </whole action> <target action> cast animation action animation wait: 10 action animation: mirror wait: 10 action animation wait: 10 action animation: mirror wait: 10 action animation action effect action effect action effect action effect action effect </target action>
Cast animations are part of the default <setup action>:

<setup action> clear battle log display action immortal: targets, true perform start wait for movement cast animation wait for animation </setup action>

I'm thinking you could override the default <setup action> to move cast animation out of there and into the appropriate place in <target action>. Maybe like this?
Spoiler: action sequence
<setup action> clear battle log display action immortal: targets, true perform start wait for movement </setup action> <whole action> perform action motion wait: user </whole action> <target action> cast animation action animation wait: 10 action animation: mirror wait: 10 action animation wait: 10 action animation: mirror wait: 10 action animation action effect action effect action effect action effect action effect </target action>
Hey! Sorry for not getting back to you sooner. I haven't tried it yet, I've been busy these past few days, but I definitely appreciate your continued support. I'll report back (probably edit this post) after I have tested it.
Thank you again, so much for your help! Take care of yourself.
👋 No worries, take as much time as you need~

Original thread: https://forums.rpgmakerweb.com/threads/yanfly-action-sequence-enemy-attack-works-but-enemy-heal-doesnt.146515/