NPC moving from fixed route to specific coordinates?

TravisTouchdown

Villager
Member
Joined
Mar 19, 2015
Messages
7
Reaction score
0
First Language
German
Primarily Uses
Hi!

I'm working on my game's intro cutscene, in which an NPC (1) repeats walking on a fixed route while dialog displays (see Screenshot 1).

So, naturally I set the move route to not be "wait for completion".



Once (1) is done talking I intend to have another NPC (2) enter the scene and move towards (1). As soon as (2) has completed doing so, I want (1) to stop following his fixed route and move towards the other NPC as well.

In order to accomplish this, I've used variables -- since I can't predict (1)'s current position when the player has finished viewing his dialog  -- Map X and Map Y.

However, no matter what I try, the movements of the two NPCs always seem to cancel each other out (see Screenshot 2; NPC 1 is supposed to stand where the red x mark is, but he'll always stop before).



I've attached another screenshot below, containing a portion of the event commands I've used. NPC 1 is referred to as "Pitty" there, while NPC 2 is named "Dr. Job".

The conditional branch is set up so "Pitty" should walk to these map coordinates: 009 (x),007 (y) [which is the spot on the map marked with an x]

The other NPC moves via the Set Move Route command.

This portion of the cutscene runs as a parallel process. I'm not sure if that's the correct way to do it, though.



Any clues as how to solve this would be highly appreciated!

Thank you.

Cheers

EDIT: Also, why is my avatar displayed upside down and angled (I'm using Firefox...)? LOL
 
Last edited by a moderator:

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
31,734
Reaction score
7,851
First Language
German
Primarily Uses
RMMV
This portion of the cutscene runs as a parallel process. I'm not sure if that's the correct way to do it, though.
No, that's actually the worst mistake that can be made in a cutscene.
Parallel processes automatically loop sixty times per second, which means that the move route for Dr, Job is also reset sixty times per second - and then you have loops inside that big loop...


Cutscenes Always have to be on autorun, and all commands in a single event, or it'll be very difficult to make the cutscene do what you want.
 

Shaz

Global Moderators
Global Mod
Joined
Mar 2, 2012
Messages
40,697
Reaction score
13,985
First Language
English
Primarily Uses
RMMV
What's on the first tab of that event? Please tell me it's not autorun with the only command to turn on self switch A.
 

TravisTouchdown

Villager
Member
Joined
Mar 19, 2015
Messages
7
Reaction score
0
First Language
German
Primarily Uses
No, that's actually the worst mistake that can be made in a cutscene.

Parallel processes automatically loop sixty times per second, which means that the move route for Dr, Job is also reset sixty times per second - and then you have loops inside that big loop...

Cutscenes Always have to be on autorun, and all commands in a single event, or it'll be very difficult to make the cutscene do what you want.
Oh, yeah, as for the various loops: I guess I'd just had a brainfart there. This will work just as good (if not better) if I place all 3 conditional branches inside 1 loop, won't it?

Well, I'm new to RPG Maker, and for some reason I thought that events containing variables (such as Map X/Y) require to be parallel process. I've watched a tutorial on how to do stealth segments and it was done that way. But then again, it wasn't a cutscene, yeah...
 

TravisTouchdown

Villager
Member
Joined
Mar 19, 2015
Messages
7
Reaction score
0
First Language
German
Primarily Uses
What's on the first tab of that event? Please tell me it's not autorun with the only command to turn on self switch A.
It does feature some event commands, such as the fixed repeating move route of NPC 1 at the beginning and his dialog. But yes, it eventually concludes with a self-switch. No good? ;-)

 
Last edited by a moderator:

Shaz

Global Moderators
Global Mod
Joined
Mar 2, 2012
Messages
40,697
Reaction score
13,985
First Language
English
Primarily Uses
RMMV
Why turn on a self switch at the end of an autorun event just to trigger another autorun event (or parallel process, in this case, but it doesn't need to be, because it's a cutscene).

Set Pitty to Autonomous Movement, Repeat, left, left, left, right, right, right, etc.

Set the autorun to show the text on that event just there, then do a Set Move Route (this event) Change Graphic to Dr Job, followed by move up, up, up, up... with a Wait for Completion. Then do a Set Move Route (Pitty) down, down, down (if he's just walking left and right, you don't care what his Y position is - you already know it, and you know how many steps he needs to take down)

Then do something like this:

Loop Control Variables [10: Pitty_x] = Pitty's map x Conditional Branch: Variable [10: Pitty_x] < 9 Set Move Route (Pitty) Move Right Else Conditional Branch: Variable [10: Pitty_y] > 9 Set Move Route (Pitty) Move Left Else (Pitty is at 7,9 - just override the auto move route to make him stay in place) Set Move Route (Pitty - repeat) Turn Down Branch End Branch EndBranch End... do your other stuffWhen you want to move Pitty, just do another Set Move Route on him. When you want him to stay in place, do a Set Move Route and set it to repeat, and make him face in the desired direction (the direction isn't really necessary, but you need to turn him down at some point so he's facing the people he's talking to).A repeated move route, without any movement commands, will just disable the auto move route. When/if you want him to start pacing again, move him back to the point where he starts on the map, and the original auto move route should take over again.
 
Last edited by a moderator:

TravisTouchdown

Villager
Member
Joined
Mar 19, 2015
Messages
7
Reaction score
0
First Language
German
Primarily Uses
Thank you!

But I don't understand the part about moving "this event". I know how to select it, but why would I use that rather than selecting the desired NPC from the dropdown?
 

TravisTouchdown

Villager
Member
Joined
Mar 19, 2015
Messages
7
Reaction score
0
First Language
German
Primarily Uses
Also, what would be the easiest way to have Dr. Job's character sprite remain transparent UNTIL Pitty is done with his monolog? Obviously I wouldn't want Dr. Job to just stand there in the corner doing nothing. He shouldn't be visible from the start.

I've tried accomplishing this by using a switch (e.g. "Job appears") that won't be active until Pitty's dialog is done. But I'd guess there's a more convenient way?

Thanks!
 
Last edited by a moderator:

Shaz

Global Moderators
Global Mod
Joined
Mar 2, 2012
Messages
40,697
Reaction score
13,985
First Language
English
Primarily Uses
RMMV
This Event means the autorun event. You've turned it into Dr Job. So you're moving Dr Job. You don't have to - you could have 3 events. My point is, for a single cutscene, you have one event controlling the whole cutscene - including the movement of the other events - and that one controlling event only needs a single page.
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

HexMozart88 wrote on Citali's profile.
Kikuo!
The lack of bike trails and bungee jump areas in this city should be criminalized.
SF_Actor3_8 added!



A recent screenshot that I also shared on Reddit and the likes, links in my signature if you want to follow :)


I am starting to get a hang of this parallaxing mapping business. Still inexperienced, but at least I can be a lot more creative now :)

Forum statistics

Threads
107,416
Messages
1,029,542
Members
139,542
Latest member
NJP
Top