'ChatOutputProcesser' has been destroyed but you are still trying to access it.’

Announcements, support questions, and discussion for the Dialogue System.
Post Reply
GameDev273
Posts: 9
Joined: Tue Feb 07, 2023 8:14 am

'ChatOutputProcesser' has been destroyed but you are still trying to access it.’

Post by GameDev273 »

Newb here… challenged by the following error.

‘MissingReferenceException: The object of type 'ChatOutputProcesser' has been destroyed but you are still trying to access it.’
In the scene the dialogue is a player and one NPC.

I am using Dialogue System v2.2.34, LivelyChatBubbles, Unity 2021.3.7f1
Advice on the web is to find what is null, why it is null and fix it, but the error seems to refer to this script LivelyBubblesChatOuputProcessor which is not mine.

The individual scenes (work ok), but when I put them together I get the error, which then stops the dialogue from working.
Also, on investigation (at runtime) I find that cloned ‘ChatBubble_CharacterName’ has 15 Chat Output Processor (script) components attached to it, which I didn’t attach.

A ‘clean’ project using a different previously created dialogue system database (i.e. TestDB_New), still makes reference to the Chat Output Processor (script) components related to a different dialogue system database (i.e. TestDB_Previous).
Any help most appreciated.
User avatar
Tony Li
Posts: 22110
Joined: Thu Jul 18, 2013 1:27 pm

Re: 'ChatOutputProcesser' has been destroyed but you are still trying to access it.’

Post by Tony Li »

Hi,

If possible, make sure the characters and their LCB canvas only exist in the current scene. That is, they're not children of Don't Destroy On Load objects such as the Dialogue Manager. Take a look at the integration's included example scene. The characters are grouped under a GameObject named "Avatars", and their Lively Chat Bubble Subtitle Panel components point to a Canvas that's not part of the Dialogue Manager.
GameDev273
Posts: 9
Joined: Tue Feb 07, 2023 8:14 am

Re: 'ChatOutputProcesser' has been destroyed but you are still trying to access it.’

Post by GameDev273 »

OK thanks very much for your response,
I'll have a look at the respective setups (Example and mine).
GameDev273
Posts: 9
Joined: Tue Feb 07, 2023 8:14 am

Re: 'ChatOutputProcesser' has been destroyed but you are still trying to access it.’

Post by GameDev273 »

Thanks Tony,
just want to confirm for anyone else with the same issue, that Tony's advice worked in my case.

I simply put a specific canvas 'BubbleCanvas' high up in the hierarchy and referenced the Lively Chat Subtitle Panel canvas field to it.

Similar to the example integration setup in the Pixel Crushers - Lively Chat Bubbles Example


Thanks again.
User avatar
Tony Li
Posts: 22110
Joined: Thu Jul 18, 2013 1:27 pm

Re: 'ChatOutputProcesser' has been destroyed but you are still trying to access it.’

Post by Tony Li »

Glad to help!
Post Reply