Adding TP on missed attack(Yanfly Skill Core)

Hello,

I'm using Yanfly's Skill Core plugin, and want to have an attack that restores TP whenever it misses. I found this post describing how to do an effect on miss, so added some code from the script call list to get the following:

Code:
<Post-Damage Eval>
var result = target.result();
if (result.missed || result.evaded){

$gameActors.actor(1).gainTp(30)

}
</Post-Damage Eval>

This isn't working actually, and I don't know why.. I think I have the Eval-code right, and the TP part does activate if I call it through other means(script outside battle)

I also tried using <Custom Conclude Effect> tags instead(with the buffs and state plugin installed), but no luck there as well.. Can anyone shed some light on what I'm doing wrong here? Thanks 🙂

Edit: Of course I find a fix for it, mere minutes later!
I should have used <After Eval> instead of <Post-Damage Eval>

This can be closed >.<

This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.

Original thread: https://forums.rpgmakerweb.com/threads/adding-tp-on-missed-attack-yanfly-skill-core.102090/