Move the player to another position in the current scene

Announcements, support questions, and discussion for the Dialogue System.
Post Reply
User avatar
DearDeerDee
Posts: 30
Joined: Mon Mar 22, 2021 10:00 am

Move the player to another position in the current scene

Post by DearDeerDee »

Hi Tony,

When the player selects a dialogue choice, I want the player to move to another position in the scene before black screen fades out. Are there sequences for those?
User avatar
Tony Li
Posts: 22117
Joined: Thu Jul 18, 2013 1:27 pm

Re: Move the player to another position in the current scene

Post by Tony Li »

Hi,
DearDeerDee wrote: Thu Aug 12, 2021 9:17 pmWhen the player selects a dialogue choice, I want the player to move to another position in the scene before black screen fades out. Are there sequences for those?
Yes. You can use the MoveTo() and Fade() sequencer commands. For example, to fade to black, then move the speaker to the position of a GameObject named BlockingMark2, then fade in, use this Sequence:

Code: Select all

Fade(stay, 1);                    // Fade out to black over 1 second and stay faded out.
MoveTo(BlockingMark2, speaker)@1; // At the 1-second mark, move speaker to BlockingMark2.
Fade(in,1)@1.5;                   // At the 1.5-second mark, fade in.
User avatar
DearDeerDee
Posts: 30
Joined: Mon Mar 22, 2021 10:00 am

Re: Move the player to another position in the current scene

Post by DearDeerDee »

Thank you Tony!
User avatar
DearDeerDee
Posts: 30
Joined: Mon Mar 22, 2021 10:00 am

Re: Move the player to another position in the current scene

Post by DearDeerDee »

Hi Tony I was checking the MoveTo() doc, and noticed this:

subject: (Optional) The object to move. Can be speaker, listener, or the name of a game object in the scene. Default: speaker.

Yet in the dialogue editor, there is only Actor, Conversant. So speaker actually refers to Actor?
User avatar
Tony Li
Posts: 22117
Joined: Thu Jul 18, 2013 1:27 pm

Re: Move the player to another position in the current scene

Post by Tony Li »

Yes, the speaker is the dialogue entry node's Actor, and the listener is the dialogue entry node's Conversant.

Note that it's possible to use a different GameObject for the conversation's main actor and conversant if you need to. For more info on this, see Character GameObject Assignments.
User avatar
DearDeerDee
Posts: 30
Joined: Mon Mar 22, 2021 10:00 am

Re: Move the player to another position in the current scene

Post by DearDeerDee »

Gotcha. Thanks!
Post Reply