Hello,
I'm encountering a very weird bug concerning the Dialogue System Events component. I've set it up to react to dialgue state between the player and a boss enemy. When setting up the events in the inspector all references to different methods are properly set up on the OnConversationEnd event. But as soon as I enter play mode, all references are lost and obviously since they are lost, nothing happens on the OnConversationEnd event. Stopping play mode properly displays the references again. why do they get lost upon entering play mode while being properly set up in the inspector? see the two screen shots for comparison: first is in edit mode, second is in play mode.
Any advice on how to fix this would be greatly appreciated!
Bug using Dialogue System Events component
Re: Bug using Dialogue System Events component
This is a Unity bug that's been reported to Unity. It not specifically the Dialogue System. In certain Unity versions, it affect scripts (such as DialogueSystemEvents) that contain only UnityEvents.
What Unity version are you using?
If possible, back up your project and update to the latest version of whatever LTS version you're using (e.g., the latest Unity 2022 LTS, or the latest Unity 6 LTS).
As an alternative, you can use Dialogue System Trigger components. Replace the Dialogue System Events component with a Dialogue System Trigger set to OnConversationEnd. Then select Add Action > OnExecute() UnityEvent.
Alternatively, you can add a script to the GameObject that has an OnConversationEnd(Transform) method.
What Unity version are you using?
If possible, back up your project and update to the latest version of whatever LTS version you're using (e.g., the latest Unity 2022 LTS, or the latest Unity 6 LTS).
As an alternative, you can use Dialogue System Trigger components. Replace the Dialogue System Events component with a Dialogue System Trigger set to OnConversationEnd. Then select Add Action > OnExecute() UnityEvent.
Alternatively, you can add a script to the GameObject that has an OnConversationEnd(Transform) method.
Re: Bug using Dialogue System Events component
We were using Unity 2022.3.41f1 and following your advice updated to the latest available Unity 2022.3.54f1. Unfortunately the buggy behaviour persisted. As you suggested we then tried using a DS trigger component instead, which seems to work fine for our use case.
Still, it'd be a shame not being able other events in case we need them. According to your statement regarding event only scripts, could we add a dummy field to the DS Events to try to make it work?
Still, it'd be a shame not being able other events in case we need them. According to your statement regarding event only scripts, could we add a dummy field to the DS Events to try to make it work?
Re: Bug using Dialogue System Events component
Hi,
I don't think that will fix it. I'll ping Unity on the status of the issue. Would it be possible for you to send a reproduction project to tony (at) pixelcrushers.com?
I don't think that will fix it. I'll ping Unity on the status of the issue. Would it be possible for you to send a reproduction project to tony (at) pixelcrushers.com?
Re: Bug using Dialogue System Events component
Hi,
Thanks for sending the reproduction project. I replied to your email.
Thanks for sending the reproduction project. I replied to your email.