Page 1 of 1

Dialogue does not wait for Custom Typewriter

Posted: Thu Feb 17, 2022 2:16 pm
by Alexis
I've created a custom typewriter that inherit from the Abstract typewriter. However, I'm having issues because the dialogue system only waits for the "MinSubtitleSeconds" value before skipping to the next bubble, no matter if typewriter has finished displaying. The Stop does is not sent (including the "Sequencer.Message(SequencerMessages.Typed);").

The thing that skip to the next dialogue is the Sequencer. In its update, the delay time left reaches 0 and there are no queuedCommands or activeCommands.


- The delay time is always wrong, because it seems to come from "GetDefaultSubtitleDurationInSeconds" which does not take into account a custom typewriter. Should I change something so my custom typewriter feeds a proper duration? What if it's dynamic?
- Should I add a command every time my typewriter starts? What would be the best way to do this?


Thanks!
Alexis

Re: Dialogue does not wait for Custom Typewriter

Posted: Thu Feb 17, 2022 2:30 pm
by Tony Li
Hi Alexis,

Your custom typewriter class is responsible for sending the message "Typed" when done:

Code: Select all

Sequencer.Message("Typed");
Sequences do not wait for the typewriter unless you've confirmed the sequence to wait for the "Typed" message. GetDefaultSubtitleDurationInSeconds determines the value of {{end}}, which is based on text length and the settings in the Dialogue Manager's Subtitle Settings section.

Re: Dialogue does not wait for Custom Typewriter

Posted: Fri Feb 18, 2022 11:39 am
by Alexis
Thanks, I must have missed it in the documentation!

For anyone having a similar issue, the solution was to change the default sequence in the Dialogue Manager from
Delay({{end}})
to
Continue()@Message(Typed)