Hi, I am making a button to quickly start and restart conversations for debugging purpose.
Currently, I add `DialogueSystemTrigger.OnUse` as the button's OnClick() listener. However, they could only start a conversation with an On Use trigger but cannot re-start the conversation from its beginning.
Is there anything I can do so that when the conversation is running, if the button is clicked again, the current conversation will start over from its beginning?
Thank you!
How to re-start a conversation using a button?
Re: How to re-start a conversation using a button?
Hi,
If you tick the Dialogue System Trigger's Actions > Start Conversation > Replace checkbox, it will stop the active conversation (if one is active) and start the trigger's conversation from the beginning.
Alternatively, you can call DialogueManager.StopConversation() or DialogueManager.StopAllConversations() in C# to stop any active conversations first.
If you tick the Dialogue System Trigger's Actions > Start Conversation > Replace checkbox, it will stop the active conversation (if one is active) and start the trigger's conversation from the beginning.
Alternatively, you can call DialogueManager.StopConversation() or DialogueManager.StopAllConversations() in C# to stop any active conversations first.
Re: How to re-start a conversation using a button?
Wow yeah the Replace option is exactly what I need. Thanks again Tony!
Re: How to re-start a conversation using a button?
Glad to help!