How to Stack Alert messages

Announcements, support questions, and discussion for the Dialogue System.
User avatar
Tony Li
Posts: 21984
Joined: Thu Jul 18, 2013 1:27 pm

Re: How to Stack Alert messages

Post by Tony Li »

The NullReferenceException in HUDManager.cs occurs because itemdata is null. This means there is no CItemIndicator component on the HUDManager's GameObject. Is it on a child GameObject? If so, use GetComponentInChildren.

For the second error (Lua reporting that ShowAlert() is not a registered method), please temporarily set the Dialogue Manager's Other Settings > Debug Log to Info. Then reproduce the problem.

When the Dialogue Manager starts, the Console window should log:

Dialogue System: Registering Lua function ShowAlert

Make sure you see this message. Then review the logs after that for any occurrences of:

Dialogue System: Unregistering Lua function ShowAlert

If you see any occurrence, click on it to view the stack trace in the bottom part of the Console log. Review it (or post a screenshot here) to determine what's unregistering it.

At any time, please feel free to send a reproduction project to tony (at) pixelcrushers.com along with reproduction steps.
2gold
Posts: 19
Joined: Wed Aug 18, 2021 2:56 am

Re: How to Stack Alert messages

Post by 2gold »

stack_success.png
stack_success.png (21.21 KiB) Viewed 261 times
Finally, I made it exactly as I intended!
I was able to solve the problem by reinforcing my script by looking at your explanation.
Thank you so much for your support, Tony! :mrgreen:
User avatar
Tony Li
Posts: 21984
Joined: Thu Jul 18, 2013 1:27 pm

Re: How to Stack Alert messages

Post by Tony Li »

Happy to help! I'm glad you got it to work the way you want.
Post Reply