Skip PC Subtitle When Dialogue Text Empty

Announcements, support questions, and discussion for the Dialogue System.
Post Reply
Crabman
Posts: 9
Joined: Mon Sep 07, 2015 2:52 pm

Skip PC Subtitle When Dialogue Text Empty

Post by Crabman »

Is there a way to not display PC subtitles when the dialogue text is empty? As far as I can tell, I can either disable them completely, jumping directly to the NPC's line when a response is selected, or it will display the menu text again.

I'd like to see the dialogue text in regular conversation, as it's more extensive than the menu text, but in some cases the response option is an action, and in those cases I'd like to skip the PC line and not have him repeat the menu text.

Is there a way to do this?
User avatar
Tony Li
Posts: 22104
Joined: Thu Jul 18, 2013 1:27 pm

Re: Skip PC Subtitle When Dialogue Text Empty

Post by Tony Li »

Hi,

Set the empty dialogue entry's Sequence field to:

Code: Select all

None()
The Dialogue System still plays entries that have empty text because they may have a sequence that still needs to play. By putting "None()" in the Sequence field, you tell the Dialogue System that there is no sequence. If you're using continue buttons, instead of "None()" click the "+" button and select Continue > Simulate continue button click.
Crabman
Posts: 9
Joined: Mon Sep 07, 2015 2:52 pm

Re: Skip PC Subtitle When Dialogue Text Empty

Post by Crabman »

I tried both, but it didn't work. I do have a continue button, as well as a typewriter effect if that makes a difference? (Though disabling it didn't change anything.)
User avatar
Tony Li
Posts: 22104
Joined: Thu Jul 18, 2013 1:27 pm

Re: Skip PC Subtitle When Dialogue Text Empty

Post by Tony Li »

Here's an example scene:

SkipEmptyText_2016-12-12.unitypackage

Please note that it uses the new "Continue()" sequencer command introduced in patch 1.6.6.5_p20161124 available on the Pixel Crushers customer download site. If you don't already have access to the site, please PM me your Unity Asset Store invoice number.

If you don't want to install the patch, edit the example scene's dialogue database and change the "..." entry's Sequence field to:

Code: Select all

SendMessage(OnConversationContinue,,Dialogue Manager)
(Your Dialogue Manager GameObject must be named "Dialogue Manager" in this case. This tacky limitation is one of the reasons why the Continue() sequencer command was added.)
Crabman
Posts: 9
Joined: Mon Sep 07, 2015 2:52 pm

Re: Skip PC Subtitle When Dialogue Text Empty

Post by Crabman »

Oh great, using that line solved the problem. Thank you!
User avatar
Tony Li
Posts: 22104
Joined: Thu Jul 18, 2013 1:27 pm

Re: Skip PC Subtitle When Dialogue Text Empty

Post by Tony Li »

Glad to help!
Post Reply