Battle Cancel Mechanic?

Hello,

I am wondering if it's possible (presumably through way of plugins) to cancel a battle before it starts, similar to Wild Arms 3.

Here is how it works in that game:

The player has an ECN Gauge, which is filled either through resting or by collecting certain crystals.

If the player is faced with a random encounter, an exclamation point will appear above their head. If there is a non-substantial difference between player and enemy level, the player can cancel the battle from starting. This will drain their ECN gauge, depending on how substantial the difference in level is. Cancelling encounters with stronger enemies may cost 10 ECN instead of 1 or 2.

The exclamation point comes in three different colors. Green means you can cancel for free. White means you can cancel at the expense of ECN, and Red means you cannot cancel (ambush, no ECN).

I'm wondering if it's possible to create a similar system where a player can opt to prevent a random encounter from occurring.

Thank you.
Moved to: Plugin Request
You'll need a plugin for this, as by default random encounters could not be cancelled, only aborted after having started.

I suggest Tsukihime's plugin for random encounter common events, with that plugin a common event is called before the battle to allow any processing at that time, including an option to abort the encounter instead of continuing it.
Then make your display and calculations inside that common event.
Awesome. I will check that out. Thank you again for your help. 🙂

Original thread: https://forums.rpgmakerweb.com/threads/battle-cancel-mechanic.81479/