Specific timing on Subtitle Panel animations?

Announcements, support questions, and discussion for the Dialogue System.
mpillit
Posts: 7
Joined: Mon Apr 01, 2024 1:03 pm

Specific timing on Subtitle Panel animations?

Post by mpillit »

Im trying to get the Subtitle Panel to display in this way:

1. The text field is populated
2. The Show animation plays and brings the panel into the cameras view.
3. The player makes a choice.
4. The Hide animation plays and takes the panel out of view, but still with the previous text populated.
5. go to 1.

The Menu Response buttons are behaving this way, but I cant get the subtitle panel to do the same. Ive been messing with the Visibility settings but none of them are getting the results I'm looking for.

Any ideas?

Thanks
Attachments
Screenshot 2024-04-02 004749.png
Screenshot 2024-04-02 004749.png (35.33 KiB) Viewed 145 times
User avatar
Tony Li
Posts: 20764
Joined: Thu Jul 18, 2013 1:27 pm

Re: Specific timing on Subtitle Panel animations?

Post by Tony Li »

Hi,

What specifically isn't working the way you want at the moment? Does the previous text disappear when the hide animation starts? Something else? By previous text, do you mean the current subtitle or an accumulation of all subtitles from the start from the conversation onward?
mpillit
Posts: 7
Joined: Mon Apr 01, 2024 1:03 pm

Re: Specific timing on Subtitle Panel animations?

Post by mpillit »

Hi Tony, thanks for the reply!

Here is a video of what Im trying to accomplish.



As you can see, all changes to the text are done when the text boxes are not visible. This radio is behaving like an analog slide projector. A slide moves out and a new slide moves in. At no point should the player ever see the text boxes being populated.

I built this using my own little system of scriptable nodes, but as the game has expanded, managing all this content was getting to be a nightmare. I bought Articy Draft 3 and your asset to import it more easily.

What specifically isn't working the way you want at the moment?

As for what its doing now, its seems to be all over the place, but I think thats because I fundamentally don't understand what each of the visibility options do.

For example, if I have one of the Always show visiblity options, no animations play and the subtitle text changes immediately when a button is clicked. That all makes sense and behaves in a predictable manner. But if I select Only During Content, the results will vary from one node to the next. First time it will:

1. play the Show animation
2. change the subtitle text
3. immediately play the hide animation without user input instead of staying in the Show state waiting for input

OR sometimes it will

1. play the Show animation
2. not change the subtitle text at all
3. immediately play the hide animation

Any help you could provide would be much appreciated.

Thanks
mpillit
Posts: 7
Joined: Mon Apr 01, 2024 1:03 pm

Re: Specific timing on Subtitle Panel animations?

Post by mpillit »

Also, heres a video of what its doing now.



Its animating in, changing the text while its visible and then automatically animating out. And sometimes its displaying the wrong text or not changing it at all, but I cant pinpoint exactly how or when.
User avatar
Tony Li
Posts: 20764
Joined: Thu Jul 18, 2013 1:27 pm

Re: Specific timing on Subtitle Panel animations?

Post by Tony Li »

Hi,

Here's an example scene:

DS_SpinningUIExample_2024-04-02.unitypackage

Instead of masking the text (which you should do in your scene), I made the radio border semi-transparent so you can see where it's rotating to.

There isn't a visibility dropdown option that does exactly what you're looking for. Instead, I set the subtitle panel's Visibility to Until Superceded, although it could be anything other than Only During Content. Then I set the conversation's properties -> Override Display Settings > Sequence Settings > Default Player Sequence to: HidePanel(0); Delay(1)

This manually hides the panel (playing a rotate-out animation) so it's ready for the next subtitle. The Delay(1) waits for 1 second while it rotates. The Hide animation rotates the text out to the right and then snaps it to the left so it's ready for the next Show animation to rotate the new text in.

On the subtitle panel's inspector, in addition to setting Visibility, I also ticked Wait For Close but left Wait For Open unticked.

The example above doesn't require any code. Alternatively, you could:

1. Make a subclass of StandardUISubtitlePanel that handles all of this in code.

2. Or duplicate TemplateDialogueUI.cs and implement the entire dialogue UI (a simple IDialogueUI C# interface) yourself, bypassing the StandardDialogueUI scripts entirely.

Note: I didn't enter all of the text from your example video. Most of the nodes link to "Go South", which link back to WATERFALL.
mpillit
Posts: 7
Joined: Mon Apr 01, 2024 1:03 pm

Re: Specific timing on Subtitle Panel animations?

Post by mpillit »

Wow, thanks for this! Ill open up the files tonight and let you know how it goes. I really appreciate your effort.

-Mike
User avatar
Tony Li
Posts: 20764
Joined: Thu Jul 18, 2013 1:27 pm

Re: Specific timing on Subtitle Panel animations?

Post by Tony Li »

Hi,

Glad to help! If it doesn't work how you'd like it to, let me know what needs to be different.
mpillit
Posts: 7
Joined: Mon Apr 01, 2024 1:03 pm

Re: Specific timing on Subtitle Panel animations?

Post by mpillit »

This is perfect, thank you. I didn't know about the Delay setting. This is pretty much exactly how I had my old system set up. I may be able to just put this right into my existing framework without completely redoing my existing interface.

Much appreciated!

-M
mpillit
Posts: 7
Joined: Mon Apr 01, 2024 1:03 pm

Re: Specific timing on Subtitle Panel animations?

Post by mpillit »

One more quick question if you dont mind. Is there a way to set the Delay on a global default basis rather than just per conversation? There will be a lot of conversations and they will all behave the same.

Thanks again,

-M
User avatar
Tony Li
Posts: 20764
Joined: Thu Jul 18, 2013 1:27 pm

Re: Specific timing on Subtitle Panel animations?

Post by Tony Li »

Hi,

Yes, set the Dialogue Manager GameObject's Display Settings > Camera & Cutscene Settings > Default Sequence and/or Default Player Sequence.

(If Default Player Sequence is non-blank, it will be used instead of Default Sequence for all player nodes -- that is, blue nodes assigned to player actor(s).)
Post Reply