In a hypothetical scenario,
> Timer hits 0.
> It just so happens a dialogue is ongoing because the player investigated an object,
> how can I make it that a common event/pp event can forcibly stop all other events from running?
Put everything inside a loop in the parallel process you use to check the timer and stop all events. While the message box will prevent any event from starting, it won't stop the looped event since it's technically not starting but still going from earlier.
It's a bit yucky, but if you make @interpreter and @page attr_accessors of the Game_Event class, you can do this:
$game_map.events.each { |i, evt| evt.page = nil evt.interpreter = nil evt.refresh}This doesn't reset the event that's actually running this script though, and it only resets map events, not common events that are currently running. It probably wouldn't take too much tinkering to add common events into the mix and figure out why the interpreter is still running on the event that's called it and to stop it.This will just reset/refresh the page, I'm thinking as if you'd inserted an Exit Event Processing in there. But it will also reset any move routes you've got on Autonomous Movement.
There was another user here a couple of days ago asking the same thing (to close a text window to make other events execute) and he got a script for it. Should be somewhere on the 2nd or 3rd support page.
I think I know which one is that (It was in RMRK) but what if there's 2 lines of dialogue and it only cancels one and I need it to stop right there? Is what I am mostly asking. But I'll try both Shaz's solution and the other guys~