NPC moving with same action while player can move

Ugh. I've tried to use Andar's answer for someone else's problem when it comes to an npc moving as the player moves, but it hasn't worked. My problem is slightly different though.


The event works up to the point when the player can move. I'm hoping to have a particular NPC running round a set route repeatedly while the player is able to move, during the starting plot to my game, but at the end of the event the NPC stops at an impassable point, trying to follow the same route. Have I done something wrong, because I need to be able to talk with him to continue the plot?


Untitled.png


As I said, the event does work.


Untitled1.png


But after this point, my NPC ends up stopping against the map.


Untitled2.png


This is after the event finishes, where the player can move.


Untitled3.png


As you can see, I have been able to move my PC.


Untitled4.png


But up to here well, the NPC gets stuck against the edge of the map. He has followed the same route after theevent finished, but wrongly. He is meant to continue going round in a circle on the path around my PC. Can anyone help me?


I would like the player to be able to move and speak with him, but if my question can't be solved I'll just have it as a whole event.
an empty parallel process like you have in your second event page (second picture) is the worst kind of event and will lag your game to hell. Change that to action button, or nothing will ever work.


Second, we need to see screenshots of the custom autonomous movements to find the errors there.
Oh. I'll try that.


I'll only give one screen shot of the autonomous movement, seeing as it is the same as the second page.


Untitled5.png


For what can't be seen, I'll show it as words. There is an 'up', then 'left, left, left, left'.


I tried to have him move in a circular motion.


After game testing with the change, the npc is still in the same place and stuck.
autonomous movement will restart at certain conditions (including when its contents are triggered), and that restart will be from the current position but starting from the first command. That will get the event off-path when it happens. You'll need at least one command to absolutely set the position to the beginning of the path in order to keep the event on the path, but that would cause it to break movement and position at that moment, looking unnatural.


There is no easy solution to this other than a pathfinding plugin, and even that will be difficult to use.
autonomous movement will restart at certain conditions (including when its contents are triggered), and that restart will be from the current position but starting from the first command. That will get the event off-path when it happens. You'll need at least one command to absolutely set the position to the beginning of the path in order to keep the event on the path, but that would cause it to break movement and position at that moment, looking unnatural.


There is no easy solution to this other than a pathfinding plugin, and even that will be difficult to use.



Oh. No worries. Thanks for helping Andar. I suppose I'll have to have it as a whole event then, or have it like I made another NPC. He is moving left and right during player movement as there is no event, so I can speak with him. I'll try that for this problem,or figure out that command to see if I can have it still natural.


Well, I'm very happy I solved the problem. Just tested the game after using a conditional branch after the event, and it works wonders now. Thanks for mentioning that a command had to be used Andar. My starting plot can finally be moved more forwards now.

Original thread: https://forums.rpgmakerweb.com/threads/npc-moving-with-same-action-while-player-can-move.67835/