Conversation ends as soon as SequencerCommand stops?

Announcements, support questions, and discussion for the Dialogue System.
Post Reply
MaddyOSaurus
Posts: 7
Joined: Sun Nov 21, 2021 8:17 pm

Conversation ends as soon as SequencerCommand stops?

Post by MaddyOSaurus »

Hi there,

I've written a SequencerCommand to call some sound via FMOD. It plays the sound and waits, calling SequencerCommand.Stop() after the clip is finished. I find, however, that as soon as Stop is called, the dialogue system ends that line (even if it's not finished with the typewriter effect yet). What can I do to play the command without affecting the visual behaviour of the dialogue system?

Thank you!
User avatar
Tony Li
Posts: 21681
Joined: Thu Jul 18, 2013 1:27 pm

Re: Conversation ends as soon as SequencerCommand stops?

Post by Tony Li »

Hi,

A subtitle will stay onscreen for the duration of its dialogue entry node's Sequence. When the Sequence field is blank, it uses the Default Sequence defined on the Dialogue Manager GameObject in Display Settings > Camera & Cutscene Settings. On an unmodified Dialogue Manager, the Default Sequence is is Delay({{end}}) which delays for a duration based on the text length, Subtitle Chars Per Second, and Min Subtitle Seconds.

Since you've specified your FMOD command, the subtitle will stay until the FMOD command has finished. If you also want it to stay until the typewriter has finished, add: WaitForMessage(Typed). Example:

Code: Select all

YourFMODCommand(entrytag);
WaitForMessage(Typed)
BTW, the Dialogue System comes with an FMODWait() sequencer command if that's any help to you.
MaddyOSaurus
Posts: 7
Joined: Sun Nov 21, 2021 8:17 pm

Re: Conversation ends as soon as SequencerCommand stops?

Post by MaddyOSaurus »

Thank you, the WaitForMessage command was what I was missing! Working as expected now :)
User avatar
Tony Li
Posts: 21681
Joined: Thu Jul 18, 2013 1:27 pm

Re: Conversation ends as soon as SequencerCommand stops?

Post by Tony Li »

Glad to help!
Post Reply