Any way to temporarily pause dialogue?

Announcements, support questions, and discussion for the Dialogue System.
Post Reply
BaddyDan
Posts: 14
Joined: Tue May 05, 2015 2:52 pm

Any way to temporarily pause dialogue?

Post by BaddyDan »

Hi,

I'm wondering if there's any way I can pause dialogue for a given period of time. For example, in the middle of a conversation, I have a sequence of animations happen and I only want the text to continue only after the animation has been completed.

It would be great if anyone can help me with this. Many thanks in advance!
User avatar
Tony Li
Posts: 22102
Joined: Thu Jul 18, 2013 1:27 pm

Re: Any way to temporarily pause dialogue?

Post by Tony Li »

Hi,

Use the sequencer's "@Message" syntax. See this manual page. Scroll down to Example 2: Waiting for Messages for an example.

Here's a simple example:

Code: Select all

AnimatorPlayWait(Dance)->Message(DoneDancing);
AnimatorPlay(Idle)@Message(DoneDancing) 
This sequence plays the animator state "Dance" and waits until it's done. When it's done, it sends the message "DoneDancing" to the sequencer. The second command, AnimatorPlay(Idle), doesn't start until it receives the message "DoneDancing". The conversation won't continue until all of the sequencer commands have run.

The Dialogue System's Tutorial Example scene uses this syntax, but it waits for a message that's generated by player actions. The dialogue text is something like "Pick up a blue cube." The sequence waits until it receives a message. This message is sent by a gameplay script that calls the static method Sequencer.Message().
Post Reply