Page 1 of 1

Chain dialogues

Posted: Tue Mar 28, 2023 6:59 am
by GenesisEnd
Hello Tony,

Is it possible to chain dialogues?

Thanks

Re: Chain dialogues

Posted: Tue Mar 28, 2023 1:17 pm
by Tony Li
Hi,

Yes, there are several ways to do that. What do you want to do?

Re: Chain dialogues

Posted: Tue Mar 28, 2023 4:47 pm
by GenesisEnd
Hello Tony,
I would like to use the dialogue system as way to move through different dialogues.
For example:
You enter a tavern and want to start a conversation with anyone in the tavern.
I need will need a different dialogue for each person, but i want to have the versatility that your system provides in order to list all of those dialogues.

Re: Chain dialogues

Posted: Tue Mar 28, 2023 7:32 pm
by Tony Li
There are several ways to interpret that, and I'm sure there's a way to do any of them. It sounds like you want to show a conversation that lists all of the NPCs that you can talk to. From that conversation, the player can choose an NPC to talk to, and the Dialogue System will switch to that conversation. If so, use a cross-conversation link. To set up a cross-conversation link, inspect a node. From the "Links To:" dropdown, select "(Another Conversation)". Then you could set it up like this:

tavernSimple.png
tavernSimple.png (20.01 KiB) Viewed 554 times

Each of the 3 "Talk to X" player responses links to a different conversation.

If you don't know ahead of time which NPCs will be in the tavern, you can set up conditions like this:

tavernFancy.png
tavernFancy.png (46.84 KiB) Viewed 554 times

The nodes on the left have Conditions that require the NPC to be in the tavern. If so, the conversation will choose the left node. Otherwise it will choose the right node.

Re: Chain dialogues

Posted: Wed Mar 29, 2023 4:54 am
by GenesisEnd
This is amazing, that was exactly what i needed.
The system doesn't cease to amaze me, great job and thanks a lot the quick response.

Re: Chain dialogues

Posted: Wed Mar 29, 2023 9:17 am
by Tony Li
Happy to help!

Re: Chain dialogues

Posted: Tue Jun 18, 2024 2:10 pm
by mel
Hi Tony, this post was really helpful. Thank you.
An additional question I had - say I want to link a conversation to another conversation that uses a different UI (I have separate dialogue UIs for regular convos vs text message exchanges). Is there a way I am able to do this using linked conversations? Or do you have suggestions for a graceful way I could handle this?

Re: Chain dialogues

Posted: Tue Jun 18, 2024 2:28 pm
by Tony Li
Hi,

There are two ways you could do that:

1. Stop the first conversation and start the second one. When starting a conversation (e.g., the second one), there are 3 ways to specify a different dialogue UI:
  • Add an Override Dialogue UI component to one of the two primary participants.
  • Assign the other dialogue UI to the Dialogue System Trigger's Actions > Start Conversation > Override Dialogue UI field.
  • Or pass the other dialogue UI to the C# method DialogueManager.StartConversation().
2. Or keep the conversation going and assign the dialogue UI to DialogueManager.conversationView.dialogueUI in an OnLinkedConversationStart() method on a script on the Dialogue Manager.