Enemy Skill that Damages TP?

Hi!

So, I've been trying to make a duck-and-cover system for my game and I've been struggling with making a Pokémon-esque Substitute Skill, and the closest I've gotten was Yanfly's Absorption Barrier plug-in. Alas, it wasn't that easy, because it never is...

My RPG uses a certain battle system where you don't worry about HP as much as you worry about MP.

See, in my game when you take damage if you still have MP you don't lose HP, instead, that damage is dealt to the MP, which acts as a shield. You use MP as both shielding and regular old RPG MP for magic Skills. (À la RWBY 's Aura).
The way I'm making this work is through another Yanfly plug-in, his Battle AI Core. Basically, the enemy detects if the Actor has MP, then they either use the MP Damage Skill or the HP Damage Skill.

The problem is that while Yanfly's plug-in satisfies everything else, it only affects HP... However! I came up with a rather haphazard workaround.

Use TP as the "health bar" for the terrain you're covering behind. I am not using TP in my game at all, so I think this would be a great way to make use of it now! What I want to do with this is add a third attack Skill to the Battle AI Core, a TP Damage skill if the player has a certain state.

While I know I can apply it with the Battle AI Core, I'm not sure how to go about a TP Damage Skill, since neither RPG Maker, nor any plug-ins I've encountered have given an option for something like this.

If anyone knows how I can make something like a TP Damage Skill either through Vanilla RPGMMV or through plug-ins, please do tell me, as I'm getting a little desperate.

Thanks in advance,

- Lex
Simple:
Simple:


Lmao thanks a million!
Simple:

It... Uhhh, keeps crashing my game whenever I try it.
Instead of xxx use number value, but if it keeps crashing let me know
Second reason might be that enemies in Enemies TAB inside database don't have TP by default, so the skill that damages actors TP must be used by enemies on players, because if player uses that skill on enemy, game might crash because as I said, enemies don't have TP

Original thread: https://forums.rpgmakerweb.com/threads/enemy-skill-that-damages-tp.127912/