Sorry if this has been posted before, I looked for an answer and couldn't find one. I'm making a game that has random encounters as well as events that do things like start a battle or damage the player.
If the player happens to hit a random encounter while a nearby event is set to approach, or the player is in the line of a trap, the event continues moving for quite a while before the player can move on the map after battle. It causes the player to get hit by something they would have otherwise been able to avoid.
Is there anything I can do that allows the player to be able to move at the same time the events start moving again after a battle ends? One thing I've tried is making encounter tiles not be on the line of these type of events, but some maps have so many of these that I might as well not have encounters. That takes away from the challenge I want the game to have, though.
Are these events using autorun? What do their move routes look like?
An autorun will make it so the player and other events can't move until that event finishes running its commands. You will need to change those to parallel. Also, you might want to check if you have any Wait for Completion boxes checked on your event move routes.
The events are set to "event touch" and are either custom routes or approach, most of the time. Either way, the issue still occurs. It may be worth mentioning the same thing happens if it's a random encounter, or a battle caused by an event. No autorun or wait for completion is used.
For the events that start battles, in the "if win" branch, there is "erase event" added.
All events continue moving for about a full second before the player is able to move immediately after any battle.
That is unlikely to have anything to do with the battle itself.
My first two gesses are either lag due to too many or too badly constructed parallel processes, or a problem with your plugins causing that delay.
In both cases we need more info to help, including screenshots of your entire plugin manager with your plugins and their order.
I'm not using any plugins or parallel processes (on the maps that this happens). Actually, it more seems like the events are moving before the battle processing has ended, while the screen is transitioning back to the map. I don't think it's any kind of lag, as this also happens on a fresh project.
Other events continue moving on their own while another event is processing (and the player can't move), which is normal, but they're doing this during battles too which is a problem. So I guess it's not really a delay.
You're not giving us a lot to go on. You're just describing the output without showing us any of your inputs at all. Show the event pages with the move routes, and plugins you have installed, and any common events that are running.
I started a new project to show this happens without any DLC, plugins, common events, parallel events, this is how you can replicate it. On the map, the zombies start on the top of the 5x5 map. The encounter rate is 10 steps. The zombies are set to move down 4 spaces and back up 4 spaces, and to repeat the movements. They are set to event touch, to trigger a textbox and then a battle.
If you get a random encounter while in the route of these zombies, they will continue moving after the battle, before you can move, and they will bump into you, triggering the event, before you can take control of your character again.
Edit: Also the other party members have been removed here, so Reid is the only member. Events don't trigger if they touch your followers.
I missread and missclicked, please delete my post...
Does it work if you put a switch BATTLE on when battles start and have those field sprites have a parallel page with that switch:
wait XX frames (test a correct wait time here)
turn switch BATTLE off
EDIT: and of course move route: fixed on that page
Thanks for the suggestions, I don't think you can have a switch be flipped as a result of a random battle starting? Maybe it'll work in the troop event pages. I'll try it out.
I'll also look into the plugins.