Page 1 of 1

What's the best way to have multiple characters talking to the player?

Posted: Tue Jan 19, 2016 7:51 am
by bluebuttongames
E.g

Actor 1: You need to get out of here!
Actor 2: Yeah beat it!

Player: Uh..ok.

I can't find an example of this in the documentation?

Thanks.

Re: What's the best way to have multiple characters talking to the player?

Posted: Tue Jan 19, 2016 10:10 am
by Tony Li
Hi,

Define your characters in the Dialogue Editor's Actors tab: Player, Actor1, Actor2.

When you create a conversation, assign two characters as the main participants, for example Actor=Player and Conversant=Actor1.

As you write your conversation, assign each node's Actor and Conversant. The node's Actor is the speaker. The node's Conversant is the character that's primarily being spoken to. You can select from all of the characters defined on the Actors tab. So for some nodes you could assign Actor=Actor2.

When the Dialogue System runs the conversation, you can provide GameObjects for the conversation's primary Actor and Conversant. These will override the characters that you've assigned in the Dialogue Editor. This allows you to re-use conversations -- for example, use the same shopkeeper conversation for several different shopkeepers.

When additional characters are involved in the conversation (not the Actor or Conversant), the Dialogue System will look for a GameObject whose name matches the character's name in the Dialogue Editor.