Force Start a Conversation in Script

Announcements, support questions, and discussion for the Dialogue System.
Post Reply
HunterTom
Posts: 18
Joined: Fri Dec 24, 2021 4:58 pm

Force Start a Conversation in Script

Post by HunterTom »

Hi,

I have been using

Code: Select all

DialogueManager.StartConversation()
to start a conversation in script.

However, I cannot do this when another conversation is already active.

Although I do remember seeing an option in the inspector somewhere that allows me to force quit the current conversation and start the new conversation, (maybe that option is in Dialogue System Trigger?) I do not know how to do that via script.

Can someone please help me?

Thank you very much!
User avatar
Tony Li
Posts: 21981
Joined: Thu Jul 18, 2013 1:27 pm

Re: Force Start a Conversation in Script

Post by Tony Li »

Hi,

Use something like this:

Code: Select all

if (DialogueManager.isConversationActive) DialogueManager.StopConversation();
DialogueManager.StartConversation("Another conversation");
Post Reply