Stop skill common event if battle ends?

By default, if you use a skill with a common event attached to it (let's say the skill does damage normally) and that kills the last enemy thus ending the battle (victory/defeat processing), the common event will end up running anyways WHEN you return to the map scene.

How can I prevent this? I do not want these common events to carry on if the skill ends the battle.

I was thinking of some possible solutions.

  1. Force all reserved common events to happen during the Victory/Defeat Processing. (for me this would be fine because in battle they do nothing anyways, only on the field will their effects happen due to a switch)
     
  2. Disable the reserving of specific common events in battle (Kinda more complex than the point above)
If there are no normal-editor methods to fix this, please feel free to move this to Ace Script Request.

Thanks.
That is not entirely correct. Single-use Common events are processed once upon using the call command. What you describe is what usually happens if the common event is set to parallel, because parallel CE's don't work during battlescreen.

Can you provide more data on the common event, so that we can check what really happens? Best would be a screenshot of the event and the skill.
That is not entirely correct. Single-use Common events are processed once upon using the call command. What you describe is what usually happens if the common event is set to parallel, because parallel CE's don't work during battlescreen.


Can you provide more data on the common event, so that we can check what really happens? Best would be a screenshot of the event and the skill.
Common events are processed in two steps


1. Reserving the call


2. The actual call


If the enemy dies before the reserved common event is executed then the engine will wait until the next moment it gets to execute the common event, which happens to be back on the map.


I would prefer to remove any reserved events before the end of bsttle.
I would prefer to remove any reserved events before the end of battle.
That is exactly what I want to know how to do. (on a global scale, which should be fine)

EDIT: I found a solution using a small modification of heartbreak61's Common Event On Battle End script.

http://www.rpgmakervxace.net/topic/16399-common-event-on-battle-end/

With this script I can force common events to process during the (aliased) self.process_victory, so now my reserved common events don't carry onto the map scene! I can also set up specific common events too, it's not just a global thing.

I basically added multiple victory_common_event_ID parts (one for each event I need) and have the victory process part call each one.

This thread can be locked.
This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.

Original thread: https://forums.rpgmakerweb.com/threads/stop-skill-common-event-if-battle-ends.17035/