MZ Simple plugin request

Can someone make a simple plugin that just makes it so $gameTemp.reserveCommonEvent(1); could happen when a skill is used, instead of the skill?
happen when a skill is used, instead of the skill?
Can you please repeat that?
@Keeby do you mean a Skill that has a chance of instead triggering a particular Common Event?
I want to have the player do a skill in battle, and instead of the skill happening, an event will happen, and if the player completes the event successfully, the skill with happen, but if they fail, the skill won't happen. I was able to achieve this by putting $gameTemp.reserveCommonEvent(1) in the formula, but it shows the player doing the skill first. If I set the animation to none, it still shows the player do the attack movement before the event plays. It also damages the enemy before the event plays as well. I want to play the event first.
Moved to: Plugin Requests

How will the plugin know "if the player completes the event successfully"? Events aren't things that a player "colmpletes".

And how will the plugin know which common events are to be run first or instead of the skill, and which are to be run after?
You could just link the first Skill to a Common event, and then put in a branch that if the player succeeds the event Force Action the Actor to perform the actual Skill.
@Milennin This is what I did before I posted the thread. I put $gameTemp.reserveCommonEvent(1); in the formula. The issues are that the player still does the skill animation before the event plays. I can accept this flaw, by just having them do a magic circle type of animation, followed by the event, but there is another problem.

The box 'Type', listing things like HP Damage, etc. If I set it to none, the formula is ignored, including the event. If it's left as is, someone, the player, or the enemy will be damaged before the event plays because of
a.atk * 4 - b.def * 2 following the common event call. If I remove a.atk * 4 - b.def * 2, it looks acceptable, but it says the enemy took no damage, or was unaffected, or something along those lines, before the event plays out with the forced action.

If I could just make it so that it does not say the enemy took damage, or whatever, before the event plays out with the forced action, that would be acceptable. Sorry if I wasn't very clear.
You don't need to put anything in the formula. Link the Skill to a Common Event in the Effects box.

Original thread: https://forums.rpgmakerweb.com/threads/simple-plugin-request.132992/