Delay command not working with PlaySequence function?

Announcements, support questions, and discussion for the Dialogue System.
Post Reply
_marc
Posts: 69
Joined: Mon Nov 05, 2018 5:44 am

Delay command not working with PlaySequence function?

Post by _marc »

Hi Tony,

I'm trying to use the Delay() command from the sequencer to add time between some dialogues. It works perfectly when the command is added in the dialogue nodes (in Articy, in my case), but with C# it seems to be ignored. My goal is to add some delay automatically, depending of the speaker, in the "OnConversationLine(Subtitle subtitle)" function, with this line: DialogueManager.PlaySequence("Delay(5)")

The debugging tells me that the sequence Delay is played by the Dialogue System, but it's ignored (the next dialogue entries are displayed before the end of the time). Is it because there is another delay sequence playing automatically (depending of the length of each dialogue entry), does it override my delay sequence?
User avatar
Tony Li
Posts: 21059
Joined: Thu Jul 18, 2013 1:27 pm

Re: Delay command not working with PlaySequence function?

Post by Tony Li »

Hi,

The conversation's timing uses the sequence that's specifically defined for the dialogue entry. If you call DialogueManager.PlaySequence("Delay(5)") in a script, it will run in parallel, unrelated to the conversation. Instead, add the delay to the subtitle's sequence:

Code: Select all

void OnConversationLine(Subtitle subtitle)
{
    subtitle.sequence = "Delay(5); " + subtitle.sequence;
}
_marc
Posts: 69
Joined: Mon Nov 05, 2018 5:44 am

Re: Delay command not working with PlaySequence function?

Post by _marc »

It works (obviously...)! Thanks for your help :)
User avatar
Tony Li
Posts: 21059
Joined: Thu Jul 18, 2013 1:27 pm

Re: Delay command not working with PlaySequence function?

Post by Tony Li »

Happy to help!
Post Reply