Instantiating DialougeManager into a scene that already has Dialogue Actors

Announcements, support questions, and discussion for the Dialogue System.
Post Reply
fkkcloud
Posts: 298
Joined: Mon Oct 05, 2020 6:00 am

Instantiating DialougeManager into a scene that already has Dialogue Actors

Post by fkkcloud »

Hello,

I am instantiating a DialogueManager prefab into a scene where it already instanced Dialogue Actor components.
It seems like the Dialogue Actor components that were already instanced before the DialogueManager prefab exists does not get registered.

What would be the best solution for this kinda situation?
User avatar
Tony Li
Posts: 21984
Joined: Thu Jul 18, 2013 1:27 pm

Re: Instantiating DialougeManager into a scene that already has Dialogue Actors

Post by Tony Li »

Hi,

The Dialogue Actor components register with the CharacterInfo script. It shouldn't matter that you're instantiating the Dialogue Manager prefab afterward.

What is not working properly?

Have you tried setting the Dialogue Manager's Other Settings > Debug Level to Info to get more information?
fkkcloud
Posts: 298
Joined: Mon Oct 05, 2020 6:00 am

Re: Instantiating DialougeManager into a scene that already has Dialogue Actors

Post by fkkcloud »

Hi,

With Dialogue Manager's Other Settings > Debug Level to Info, I don't see the characters with the Dialogue Actor component calling "Register" log.

If I manually deactivate and activate the game object that has the Dialogue Actor component, it does Register or Unregister it.

As it's not getting registered, it seems like it tries to register/look for the dialogue actor while the conversation is progressing (When the specific Dialogue Actor speaks), it does a hiccup since it goes through all gameObject to find it seems.
User avatar
Tony Li
Posts: 21984
Joined: Thu Jul 18, 2013 1:27 pm

Re: Instantiating DialougeManager into a scene that already has Dialogue Actors

Post by Tony Li »

It should still be registered, even if the Dialogue Manager isn't present to tell it to log the information to the Console window.

Is it possible that something else is causing the hiccup, such as the Dialogue Manager starting its database and initializing the dialogue UI?
fkkcloud
Posts: 298
Joined: Mon Oct 05, 2020 6:00 am

Re: Instantiating DialougeManager into a scene that already has Dialogue Actors

Post by fkkcloud »

It seems so.

I have below sequence command on startup node.

Code: Select all

SetPanel(Sia, 6);
SetPanel(Min, 6);
SetPanel(Inah, 6);
SetPanel(JungIn, 6);
SetPanel(Suji, 6);
I have other c# code that is called OnConversationStart so I will look into more on the initialization side of it.
Post Reply