[Bug] Note Box States not applying?

I have almost all Yanfly plugins and plugin extensions, but none other than Buff states Core should really interact with this to my knowledge. For some reason I can't seem to get any states to apply to a target thru the notebox. Am I missing something?
1670633768718.png
Your tag says "after I get hit, give me state ID 78". If that's not what you're seeing, then make sure your Yanfly plugins are in the recommended order, listed here:
You can click+drag in the Plugin Manager list to rearrange the order. Remember to save your project to apply Plugin Manager changes before testing.

If you want the state to be added to the action user instead, replace b with a.

Otherwise, maybe describe what you want to happen.
thanks for the suggestion, but sadly it still doesn't seem to work.
What I'm trying to do is have a skill check if the user's stats, in this case ATK is higher than the target's, in this case DEF. If the user's stat is higher then a state is applied to the target.
What instead happens is damage is dealt, animations finish, but then nothing else.
I've tried using different states, different actors and enemies, different skills with this in the notebox, etc. The picture from before was me trying to see if I could get a state to apply at all using this method.
Here is the code as I described:
<Custom Respond Effect>
var rame = a.atk;
rame -= b.def;
if ( rame > 0 ){
b.addState(78);
}
end
</Custom Respond Effect>
Ideas:
  1. end isn't part of JS syntax (but the rest of that tag looks OK). I think that last line will just have no effect, but to be sure you could try this instead:

    <Custom Respond Effect> if (a.atk > b.def) { b.addState(78); } </Custom Respond Effect>

  2. That tag should be in the Note field of a state. Is that where you have it? 😅

  3. You didn't clarify this, so I'll paraphrase: the <Custom Respond Effect> of a state processes immediately after the state-bearer gets hit. (The state-bearer is the one who is affected by the state.) Is that what you want?

    If not, you'll need a different tag, e.g. <Custom Establish Effect> (processes immediately after the state-bearer lands a hit).

  4. For testing, you can try this:

    <Custom Respond Effect> alert(b.name() + ' was hit!'); </Custom Respond Effect>
    This should show a pop-up message when the tag processes. Do you see that message when you expect to see it?

  5. Did you check your plugin order like I suggested? Also check that the plugins you're using are up-to-date. You can share screenshot(s) of your Plugin Manager if you want people to help with that.

    Remember to save your project to apply Plugin Manager changes before testing.
I've tried...different skills with this in the notebox, etc.
caethyril mentioned it, but I believe this is the culprit.

Custom Respond Effect is a State notetag, not a Skill notetag - it will never do anything if you put it in a skill.

If you want it to be in a skill, not dependent on a state, the correct tag from Yanfly's Skill Core is Post-Damage Eval. (or After Eval, if you don't want it to be dependent on a successful hit)
lmao yup. I switched it to Post-Damage Eval and it worked first try. Seems like that was the main issue so if anyone else has this issue, it's pretty simple. My thanks to both ATT_Turan and caethiryl.

Original thread: https://forums.rpgmakerweb.com/threads/bug-note-box-states-not-applying.153220/