Error in Sending Message

Announcements, support questions, and discussion for Quest Machine.
Post Reply
willij
Posts: 15
Joined: Sat Oct 27, 2018 5:35 pm

Error in Sending Message

Post by willij »

I'm not sure what this means exactly:

Message System exception sending [message] to [class]: Object reference not set to an instance of an object

Redacted the exact message and class name for brevity's sake.
User avatar
Tony Li
Posts: 22056
Joined: Thu Jul 18, 2013 1:27 pm

Re: Error in Sending Message

Post by Tony Li »

Hi,

Would you please post or PM me the full message? Click on the message in the Console window, press Ctrl+C (or Command-C on Mac) to copy it to the clipboard, and then paste it into a reply or private message.

It means that something registered itself to listen for this message, but then that something was destroyed without unregistering itself.

As far as the Message System is concerned, it's informational. The next update will let this slide by without logging an error.
willij
Posts: 15
Joined: Sat Oct 27, 2018 5:35 pm

Re: Error in Sending Message

Post by willij »

Thank you - I was able to get the error to go away but I'm not exactly sure what I did.

I was never destroying the game object that was listening for the message - and even if I somehow did by accident I have On Disable stop listening code on it.

It might have something to do with me setting the timescale to 0. I commented out that code among other things and the error went away. I left it like that so I could get some work done while I waited for your response however I put the code back in just now and I'm still not getting the error anymore so I don't know what's going on.

Maybe I just needed to restart Unity. Anyway thanks again.
User avatar
Tony Li
Posts: 22056
Joined: Thu Jul 18, 2013 1:27 pm

Re: Error in Sending Message

Post by Tony Li »

Glad to help. It was basically harmless anyway, but I'm glad it runs nice and clean now.
Post Reply