Rsponse panel for a NPC?

Announcements, support questions, and discussion for the Dialogue System.
Post Reply
forrestuv
Posts: 64
Joined: Tue Nov 06, 2018 11:28 am

Rsponse panel for a NPC?

Post by forrestuv »

Is there a way to show a response panel even if the actor or conversant are not players?
thx
User avatar
Tony Li
Posts: 22057
Joined: Thu Jul 18, 2013 1:27 pm

Re: Rsponse panel for a NPC?

Post by Tony Li »

The easiest way is to make a copy of the actor, and set its Is Player checkbox true. Assign it to the response nodes. You can make it look just the non-player copy of the actor by using the same Display Name and portrait image(s).

Alternatively, you could temporarily set the original actor's Is Player field to true at runtime. For example, in C#:

Code: Select all

DialogueLua.SetActorField("Some Actor", "Is Player", true);
If you want to get deep under the hood, you could create a new ConversationState object and call DialogueManager.conversationController.GotoState(state). I'll only get into those weeds if you tell me that's the way you want to go.
forrestuv
Posts: 64
Joined: Tue Nov 06, 2018 11:28 am

Re: Rsponse panel for a NPC?

Post by forrestuv »

thx
also, is there a particular reason why DialogueEntry has ActorID and ConversantID always = 1 ?
(same if I query the DB DialogueManager.instance.MasterDatabase.GetDialogueEntry)

The DialogueEntry Actor and Conversant are configured properly in the editor.
forrestuv
Posts: 64
Joined: Tue Nov 06, 2018 11:28 am

Re: Rsponse panel for a NPC?

Post by forrestuv »

Interesting..it only happens on a specific (long) Entry ...mmmm
forrestuv
Posts: 64
Joined: Tue Nov 06, 2018 11:28 am

Re: Rsponse panel for a NPC?

Post by forrestuv »

Nevermind..It was the backup db selected that had the same entry with wrong Actor/Conversant ID all set to 1 (odd btw)
User avatar
Tony Li
Posts: 22057
Joined: Thu Jul 18, 2013 1:27 pm

Re: Rsponse panel for a NPC?

Post by Tony Li »

Glad to hear it's okay now. Maybe at one point someone had set the conversation's actor and conversant to the same value.
Post Reply