Is there a plugin that replaces defeated actors with party members in reserve?

Plugins already exist that allow you to switch actors in the middle of a fight, but are there any that will let you switch someone if they get defeated?

Ideally I'd like the knocked out actor to be switched with a living party member from the reserves if they've been dead for 3 turns.

In this way the player won't get a gameover until all the characters they have available are defeated.

Does anything like this exist?
Did you find what are you looking for?
@mrcopra

Nah. There doesn't appear to be anything out there that does this yet.
This plugin should work for swapping out characters at the end of the turn :


edit : updated link, now allows user to insert a parameter to be able to control how many turns it takes for the use swap to happen.
@Ruiran

This is beautiful. It even works with Yanfly's CBT and STB if you set the turn counter to 0. Thank you so much for this.

Original thread: https://forums.rpgmakerweb.com/threads/is-there-a-plugin-that-replaces-defeated-actors-with-party-members-in-reserve.87712/