Checking status of the character on level up

Is there a way to trigger an event or common event once a character levels up? I have to check whether the character is in a certain state once he levels up and learns a new skill. Otherwise bugs might occur. I don't know how much to go into detail with this. The only way I can think of to implement this is to run a parallel common event which constantly checks whether the character has reached a certain level. But that would consume memory. I would try to avoid that, if possible.
the parallel process would be a bad idea.

two possibilities, depending on your game circumstances:

1) you can call a common event to check whenever the actors gain EXP. this could be done directly in case of event commands/quests giving experience, and there is a construct that allows a parallel common event to run once after each battle.

2) plugin for level up events

the second option is easier to handle but can cause compatibility problems with other plugins.
the first option is guaranteed to both work and be tedious to implement.
there is a construct that allows a parallel common event to run once after each battle

How is that done? Can I find that somewhere on the internet?
Here on this forum - because I've explained it in a dozen other posts.

basically you make a switch named "after battle".
then you make a parallel process common event that is conditioned on that switch.
in that common event you do whatever you want after each battle.
but the important part is to turn off the switch as the last command, making sure that it doesn't loop.

and then in every battle, you turn on the switch on turn 0 - because there are no parallels during battle it will only start after the battle has ended and the player returns to the map.

some people use a base troop plugin to prevent having the troop event to switch on in every troop.
You can event it as Andar described, or you should be able to find with a quick Google a plugin that calls common events when actors level up. I wouldn't be concerned about that conflicting with anything else you have installed, personally.
Thanks for the tips.

and then in every battle, you turn on the switch on turn 0 - because there are no parallels during battle it will only start after the battle has ended and the player returns to the map.
Do I have to configure every troop to have the switch turn on on turn 0 or is there a way to do it once for every battle?
is there a way to do it once for every battle?
some people use a base troop plugin to prevent having the troop event to switch on in every troop.
fundamental question: *will* the players gain any XP outside of battle?
if the answer is no, do it as suggested above: at the end of battle, check for any XP gains and level up.
if the answer is yes, you could define a small hook to the level up function and use it to trigger your common event, putting everything to be handled through the event editor rather than code.

the problem here is catching the event of level up, and that comes as a result of XP gain.
normally, you would only gain XP in battle, and the battle has a way of adding instructions to run *as* it happens.
but if you were to gain XP outside of battle, the level up will still trigger, and you're outside of the scope of that battle system.
you can still control everything through eventing... the difference is how you trigger that block.
I have finally resorted to using a plugin that executes custom code upon the level up of characters. If it doesn't match with my other plugins, I will use Andar's solution.

Original thread: https://forums.rpgmakerweb.com/threads/checking-status-of-the-character-on-level-up.151331/