Conversa Plugin
This is for the long and sustainable evolution of the basic things seen before. This is a paid plugin and so this would not apply to everyone.
Reference Link: https://github.com/enriquemorenotent/unity-conversa-support/wiki
Initial Updates to DiaManager.cs
// Add to top of the script
using System;
using Conversa.Runtime.Events;Initial Updates to DiaTrigger.cs
// Add to top of the script
using Conversa.Runtime;
using Conversa.Runtime.Events;
using Conversa.Runtime.Interfaces;
...
//Inside Class
[SerializeField] private Conversation conversation;
private ConversationRunner runner;
...
//Setting things up
private void Start()
{
runner = new ConversationRunner(conversation);
runner.OnConversationEvent.AddListener(HandleConversationEvent);
}
Buckle up, Time for Delegates!
In javascript, you can pass a function as a variable. Not in C#. Now, you have to create a delegate. This video, up to 3:28 will explain the shenanigans. If you go past that, you will get confused.
Just the additional Script added for DiaManager.
Here are some failures I got when trying to set "onContinue" to a function in the DiaManager:
Last updated