Well, I'm not sure if it's possible in a battle, you'd probably have to heal them as the map also checks if the characters are dead, but you'll also want to make sure that the condition for that battle event isn't set to "Don't Run", because then it won't run.
If the battle was set up by an event, you can also check the "Don't Lose" option to be able to put in more event commands if the player loses the battle.
If the battle is random, you will need a plugin.The win/lose check is done before the battle event check.
Thanks, all.
Here's my situation: I want these to be a global event, as in every random/non-random battle will have this trigger/event.
So I'm looking for a scalable solution. Adding the End Phase Trigger to every troop isn't scalable, so perhaps a plugin request might be the best way to go.
Mods - please let me know if I should start a thread in the request forum.
In engine ways for a non-Gameover Defeat:
For battles that are on the map:
On the event page go to battle processing.
In battle processing you can make a branch that says if lose, and then you don't die at the end of a battle. Under the lose branch place a transfer that sends the player back to wherever they were.
Random battles:
Do the same as in map battles but as check the box that says like random encounters. Now you have a random encounter.
For a bit extra you could make a common event set to a parllel process of a region ID that was set battle processing that was random event, then you wouldn't have t9 make an event for every battle, or if you wanted something a bit more complete you could have a region id set to a spefic value.