UI not enabling for conversation

Announcements, support questions, and discussion for the Dialogue System.
Post Reply
jal
Posts: 2
Joined: Mon Mar 14, 2022 3:04 pm

UI not enabling for conversation

Post by jal »

Hi, I'm new to using this plugin so I don't understand everything 100% yet but I'm having an issue where the interface game object is disabled when OnUse is triggered. To explain the situation, I'm working on an RPG where an NPC challenges you to a battle with dialogue and on winning the battle there's additional dialogue about the battle. My problem is that the initial dialogue is appearing correctly, and the battle goes as normal, but then that post-battle dialogue isn't appearing correctly. The logs imply that the dialogue has been successfully triggered and there's no error or anything.
dialogue-logs.png
dialogue-logs.png (62.41 KiB) Viewed 251 times
So I noticed that the game object for the interface itself was disabled..
dialogue-hierarchy.png
dialogue-hierarchy.png (2.84 KiB) Viewed 251 times
if I manually enable it the dialogue happens as expected with the correct line, so I'm unsure why it's not enabling the interface in this specific case. I've also noticed that if I talk to the NPC manually after this, instead of using the interface that is already instantiated, it creates a new instance. Is this intended? Over time, it builds up to a huge amount of instantiated interface prefabs that never get destroyed.
dialogue-hierarchymulticonvo.png
dialogue-hierarchymulticonvo.png (5.94 KiB) Viewed 251 times
I'm clearly missing something and hoping someone can help me out here! Thanks!
User avatar
Tony Li
Posts: 22149
Joined: Thu Jul 18, 2013 1:27 pm

Re: UI not enabling for conversation

Post by Tony Li »

Hi,

Are you using Override Dialogue UI or Override Display Settings components?

Is DialogueUI_Portrait assigned to the Dialogue Manager GameObject's Display Settings > Dialogue UI field?

Does your DialogueUI_Portrait GameObject only have a Standard Dialogue UI component, and not a Standard UI Subtitle Panel or Standard UI Menu Panel?

If it has a Standard Dialogue UI, make sure the DialogueUI_Portrait GameObject itself isn't assigned to the Dialogue Panel field. (When the conversation ends, the Standard Dialogue UI component will deactivate the Dialogue Panel, assuming it's a child object.) If the subtitle panel(s) and menu panel(s) are direct children of DialogueUI_Portrait, you can leave the Dialogue Panel field unassigned.
jal
Posts: 2
Joined: Mon Mar 14, 2022 3:04 pm

Re: UI not enabling for conversation

Post by jal »

Thanks so much for your quick response! I didn't realize that the standard dialogue UI handled the enabling/disabling of things so I had added disabling to the OnClosed function within UIPanel. After removing that it's working as expected!
Thanks again!
User avatar
Tony Li
Posts: 22149
Joined: Thu Jul 18, 2013 1:27 pm

Re: UI not enabling for conversation

Post by Tony Li »

Glad to help!
Post Reply