Page 1 of 1

Messages going blank - textline

Posted: Sat Aug 22, 2020 6:14 am
by kelsington
Hi Tony,

I have a weird bug happening that only occurs in the WebGL export of my game.

There are no errors in unity and the game plays as expected in the game view, but for some reason in the final messages the text disappears and leaves the messages blank.

I can't see anything obvious in the dialogue manager or character set ups that could cause this - any idea where I need to look?

Image attached to show my issue. Please help! :)

Re: Messages going blank - textline

Posted: Sat Aug 22, 2020 8:26 am
by Tony Li
Hi Kelsey,

It may be a font issue. As a test, try a different font, such as Unity's default Arial. Or, if you're not using TextMesh Pro, try switching to TextMesh Pro.

But, before you do that, make a Development Build. (Tick Development Build in the Build Settings window.) When you play and get to that point, check your browser's development console. (See Debugging WebGL)

Re: Messages going blank - textline

Posted: Sun Aug 23, 2020 5:46 am
by kelsington
Hi Tony,

Definitely not a font issue, it is already in Ariel. I've debugged as suggested and have found this error in the console

Dialogue System: Can't find any built-in sequencer command named waitformessage() or a sequencer command component named SequencerCommandwaitformessage()
(Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 35)

It looks like the sequencer command waitformessage(forever) didn't work, so i've removed that. Fingers crossed that solves it!

Re: Messages going blank - textline

Posted: Sun Aug 23, 2020 9:30 am
by Tony Li
Try:

Code: Select all

WaitForMessage(Forever)
The "WaitForMessage" part is case-sensitive.

Fonts are a bit quirky in WebGL. Here are a few things you can try:

1. Set the Text elements' Material field to the default 'Font Material', or create a default material and assign it.

2. Try changing fonts and/or inspect the font you're using and specify a fallback font in case WebGL can't use that font on some machine.

3. Tick the font's Include Font Data checkbox.

4. Or, all else failing, switch to TextMesh Pro (TMP). TMP renders text from sprite sheets, so it's not dependent on different computers' and browsers' font compatibility.

Re: Messages going blank - textline

Posted: Sat Sep 12, 2020 8:00 am
by kelsington
Hi Tony,

I can't find a font material that works with the scroll rect - meaning that the text continues to appear past the scroll rect restrictions. Any suggestions?

I find it weird that it is in relation to the font when the issue only appears around 15 minutes into playing (right before the end of the game. Is it not possible to be anything else? I am trying to use Text Mesh pro but its not working

Re: Messages going blank - textline

Posted: Sat Sep 12, 2020 9:02 am
by Tony Li
Hi Kelsey,

It's possible that it's something else. Does it happen at the same place every time?

If you're accumulating a lot of text, you might be hitting a message limit. Try setting Max Messages to a non-zero value such as 100.

Does the Scroll Rect GameObject have a Mask component? If so, is it enabled? This is what masks away text that's outside of the Scroll Rect's Image boundaries.

TextMesh Pro (TMP) will give you the best performance and crispest text. What questions do you have about TMP?