Reverse the "Substitute" mechanic?

I'm making a game with a guest character who you have to escort. He has auto-battle and is a bit of a coward.

I wanted to give him a 'hide behind someone else' mechanic, where if he uses a skill, he forces someone else to take damage that was meant to him.

Is there a plugin to that, or something?
If you're looking to use the Substitute mechanic, I've made some changes here that will allow you to do this using states: Substitute Override.

Have the guest character's skill apply the "protect" state (the one you choose in the plugin parameters) to himself, and then have another state that applies the substitute flag added to an ally.
You'll need to create or request a plugin that can change the conditions for Substitute for certain states. I've done this before in Ace, and it's not that hard, but I don't know where the substitute conditions are in the MV code base. Essentially, what you'll want to do is give a special Priority 0 (therefore Invisible) Substitute state to everyone except the Coward, and set up your conditions that if it's THIS state, it looks to see whether the Coward is the target, and if so, substitutes; otherwise, it does the normal processing (usually looking to see if the target has 25% or less HP).

EDIT: Looks like @Silva might have given you what you need. Try that first.
@Wavelength my plugin does as you've suggested - I haven't included an else branch to process a normal substitution though, but am happy to do so if it's needed @Grandy12.
If you're looking to use the Substitute mechanic, I've made some changes here that will allow you to do this using states: Substitute Override.

Have the guest character's skill apply the "protect" state (the one you choose in the plugin parameters) to himself, and then have another state that applies the substitute flag added to an ally.

Thank you, this should work!

Original thread: https://forums.rpgmakerweb.com/threads/reverse-the-substitute-mechanic.106910/