Delay before/after Dialogues for setup

Announcements, support questions, and discussion for the Dialogue System.
Post Reply
Nico
Posts: 4
Joined: Mon Jan 06, 2025 5:56 am

Delay before/after Dialogues for setup

Post by Nico »

Hi Tony, and everyone,

I'm setting up my dialogues using the Dialogue system (killer asset, really helpful!) and there are 3 things I can't manage to achieve. I'm curious if the asset allows it natively or if I have to make it myself:
(Note: I'm using FEEL to create all my effects and animations, not an OG animation)

- I can't find how to delay the start of a dialogue until after the start sequence is done: my dialogues start with a setup: characters sliding in view, then the dialogue box appears. it takes about 1.5s. I want the dialogue text to wait for this time before starting. Is it possible?

- I have a "closing sequence" as well, where all the elements leave the screen. For some reason, the closing sequence doesn't play, as the dialogue seems to be instantly disabled once the dialogue is finished. IS there a way to add a delay here as well?

- Finally, I would love to animate each letter appearing in the dialogue (using Unity UI Typewriter Effect, ex a fade in and a little scale when appearing) but can't seem to find a way to animate only the appearing letter (and not the entire text). Any pointers would be really appreciated.

Thanks a lot in advance, and have a great day!
User avatar
Tony Li
Posts: 22886
Joined: Thu Jul 18, 2013 1:27 pm

Re: Delay before/after Dialogues for setup

Post by Tony Li »

Hi,
Nico wrote: Fri Feb 07, 2025 4:04 am- I can't find how to delay the start of a dialogue until after the start sequence is done: my dialogues start with a setup: characters sliding in view, then the dialogue box appears. it takes about 1.5s. I want the dialogue text to wait for this time before starting. Is it possible?
Without scripting, you can create an empty node at the start of the conversation and set its Sequence field to:

Code: Select all

Delay(#)
where # is the duration of the feedback.

Not ideal, admittedly, which is why the UI scripts' methods are virtual. If you don't mind a bit of scripting, you can instead make a subclass of StandardDialogueUI and override the ShowSubtitle() method to wait until the feedback is done (if it's playing) and then call base.ShowSubtitle().

Alternatively, replace the UIPanel component on your main Dialogue Panel child with a subclass that overrides the Open() method so that it doesn't set its panelState to Open until the feedback is done. Then tick the StandardDialogueUI component's Wait For Main Panel Open.
Nico wrote: Fri Feb 07, 2025 4:04 am- I have a "closing sequence" as well, where all the elements leave the screen. For some reason, the closing sequence doesn't play, as the dialogue seems to be instantly disabled once the dialogue is finished. IS there a way to add a delay here as well?
Tick the StandardDialogueUI's Wait For Close, and Don't Deactivate Main Panel.
Nico wrote: Fri Feb 07, 2025 4:04 am- Finally, and this goes beyond the asset, so feel free to ignore it I would love to animate each letter appearing in the dialogue (using Unity UI Typewriter Effect) but can't seem to find a way to animate only the appearing letter (and not the entire text). Any pointers would be really appreciated.
Use Text Animator for Unity. It has great animation options, and the Dialogue System has integration with it. It uses TextMesh Pro, so you'll want to enable TextMesh Pro Support.
Nico
Posts: 4
Joined: Mon Jan 06, 2025 5:56 am

Re: Delay before/after Dialogues for setup

Post by Nico »

You are a superstar!
Thanks a lot for this answer, everything sounds great.

Take care, and thanks again!
User avatar
Tony Li
Posts: 22886
Joined: Thu Jul 18, 2013 1:27 pm

Re: Delay before/after Dialogues for setup

Post by Tony Li »

Glad to help!
Post Reply