Hi there, I'm curious about one thing that's happening in my setup. It's not a big deal, but I think it's time I know why this is happening at all.
First of all, my configuration may be weird, and it's probably too early in the thread to dump it, when it's possible this is happening by design.
My issue: "Continue Button" is set to "Always", but if I leave any entry's "Dialogue Text" field blank, the button is disabled regardless.
So, if I forget to provide a way to artificially continue, with a Continue() sequence command, the conversation is effectively stuck because I also removed the keyboard shortcuts to manipulate convo flow.
Now, I'm not 100% I didn't do something to cause this in another part of my game. It's been so long that it could be, lol.
But I'd like to ask you first, in case this is indeed how DS is supposed to work, even when "Always" is selected.
Thanks.
Continue button disabled if dialogue entry doesn't have dialogue text.
Continue button disabled if dialogue entry doesn't have dialogue text.
Unity 2019.4.9f1
Dialogue System 2.2.15
Dialogue System 2.2.15
Re: Continue button disabled if dialogue entry doesn't have dialogue text.
That's by design. Continue buttons are normally inside subtitle panels. If the subtitle text is blank, the Dialogue System won't show it in a subtitle panel, which means the subtitle panel (and its continue button) may not be visible. If text-less entries required continue button clicks, in most cases it would appear to the player like the conversation just froze with no way to advance it.
Re: Continue button disabled if dialogue entry doesn't have dialogue text.
Ah, so I didn't mess up the configuration so much. That's good.
Alright. It's not causing me much trouble.
I'm doing everything related to scripted events (think of a graphical adventure) with your plugin. In some entries there is dialogue, but in others there isn't and I'm running sequence commands that take some time to execute, like a character changing clothes or going from point A to point B.
And in those cases, I'd like the player being able to skip by clicking on the screen at my huge invisible continue button. That's not possible if I forgot to add a blank space character in that entry.
Another worse case is if I leave one of those "non-actor" entries without a way for continuing eventually, as when I'm waiting for a message from a PlayMaker FSM that never arrives. In those cases I usually add another Continue()@<some_time>, just in case. But if I forget that, then the game can get stuck in those entries because the player won't have an continue button to click, unless there's a blank space in Dialogue Text, as the previous case.
The "problem" (more like an aesthetic issue), is that the panels are activated when I use that single space character, along with the gradient effect I added to the UI.
Anyway, I'm not doing a masterwork here and you know that in my particular genre... aesthetics are more important in other areas.
In other words: I'll survive.
Maybe I'll experiment taking the button outside the subtitle panel, idk.
Thanks for the reply!
Alright. It's not causing me much trouble.
I'm doing everything related to scripted events (think of a graphical adventure) with your plugin. In some entries there is dialogue, but in others there isn't and I'm running sequence commands that take some time to execute, like a character changing clothes or going from point A to point B.
And in those cases, I'd like the player being able to skip by clicking on the screen at my huge invisible continue button. That's not possible if I forgot to add a blank space character in that entry.
Another worse case is if I leave one of those "non-actor" entries without a way for continuing eventually, as when I'm waiting for a message from a PlayMaker FSM that never arrives. In those cases I usually add another Continue()@<some_time>, just in case. But if I forget that, then the game can get stuck in those entries because the player won't have an continue button to click, unless there's a blank space in Dialogue Text, as the previous case.
The "problem" (more like an aesthetic issue), is that the panels are activated when I use that single space character, along with the gradient effect I added to the UI.
Anyway, I'm not doing a masterwork here and you know that in my particular genre... aesthetics are more important in other areas.
In other words: I'll survive.
Maybe I'll experiment taking the button outside the subtitle panel, idk.
Thanks for the reply!
Unity 2019.4.9f1
Dialogue System 2.2.15
Dialogue System 2.2.15
Re: Continue button disabled if dialogue entry doesn't have dialogue text.
The continue button -- or a secondary continue button -- will have to be outside of your subtitle panel, since the subtitle panel will stay inactive.
You could add a script like this to your dialogue UI:
EnableContinueButtonForBlankSubtitles.cs
Then add a secondary continue button outside of your subtitle panel, assign it to this script, and configure its OnClick() to do two things:
1. Call the dialogue UI's StandardDialogueUI.OnContinueConversation, and
2. Deactivate itself (the secondary continue button).
You could add a script like this to your dialogue UI:
EnableContinueButtonForBlankSubtitles.cs
Code: Select all
using UnityEngine;
using UnityEngine.UI;
using PixelCrushers.DialogueSystem;
public class EnableContinueButtonForBlankSubtitles : MonoBehaviour
{
public Button secondaryContinueButton;
void OnConversationLine(Subtitle subtitle)
{
secondaryContinueButton.gameObject.SetActive(string.IsNullOrEmpty(subtitle.formattedText.text));
}
}
1. Call the dialogue UI's StandardDialogueUI.OnContinueConversation, and
2. Deactivate itself (the secondary continue button).
Re: Continue button disabled if dialogue entry doesn't have dialogue text.
Thanks Tony, I appreciate it.
Unity 2019.4.9f1
Dialogue System 2.2.15
Dialogue System 2.2.15