so i looked up how to make an animation play when an attack triggers critical and found that you can use yanfly's Auto Passive States and the Buff State Core plugins in conjunction to do so, i did and the effect works good for the most part, but i've noticed some skills just don't trigger the animation for some reason, i was wondering if it was due to the "Physical" in the code but some skills with that trait just also don't trigger the animation like in this gif, is there something causing this?

Here's the code i put in the note tags for the state that gets applied to both actors and enemies.
an additional but not necessary question is if i could use a variant of this code to also make it play animations whenever weaknesses or resistances are triggered.

Here's the code i put in the note tags for the state that gets applied to both actors and enemies.
<Custom Establish Effect>if (this.isPhysical() && target.result().hpDamage > 0 && target.result().critical) {target.startAnimation(6);}</Custom Establish Effect>an additional but not necessary question is if i could use a variant of this code to also make it play animations whenever weaknesses or resistances are triggered.