I have multiple NPCs in a scene with the correct components attached to them (Dialogue System Trigger, Dialogue System Events, and Usable), and they are using different conversations from each other. In other scenes, also with multiple NPCs, the Dialogue System Events are firing as intended with no problem, but not with these NPCs. I'm sure its not the Dialogue Manager object since its copy and pasted from a scene in which there is no problem with these events.
I also made sure that the components from these NPCs matched with NPCs that had the events working in previous scenes, and still the events aren't working. Could the problem be in the conversation database? Or I'm not sure what to look for to further debug these NPCs.
Thanks!
OnConversationStart and OnConversationEnd events working in some scenes and not others
Re: OnConversationStart and OnConversationEnd events working in some scenes and not others
Hi,
Do your NPCs have direct references to the scene's Dialogue Manager? If so, please be aware that the Dialogue Manager GameObject survives scene changes by default, so the reference won't be valid after changing scenes. Please see this article for an explanation with screenshots and solutions. It explains the topic in the context of the player GameObject, but the same idea applies to NPCs, too.
Do your NPCs have direct references to the scene's Dialogue Manager? If so, please be aware that the Dialogue Manager GameObject survives scene changes by default, so the reference won't be valid after changing scenes. Please see this article for an explanation with screenshots and solutions. It explains the topic in the context of the player GameObject, but the same idea applies to NPCs, too.