Forum rules - please read before posting.

Disable text scrolling causes text to vanish

Hi all

I have working dialogues with scrollable text. When I try disabling scrollable text in the AC settings panel the text disappears from dialogue window. That is, I disable scrollable text in the AC settings panel, hit play, and my dialogue boxes are empty. Enable scrollable text, hit play, and the text appears again.

Any ideas? I feel I've missed something obvious here.



  • What are your AC / Unity versions?

    There are a couple of scrolling options in the Settings Manager - which one specifically are you unchecking, and is the text coming from a character, or narration?

    Is your Menu rendered with AC, or Unity UI? If Unity UI, try viewing the Text component in the Hierarchy at runtime - does its Inspector show the text being populated? If so, pause the game, and try examining the UI in the Scene window to see why it's not showing.

    Otherwise, try switching your Menu Manager's asset file to Default_MenuManager, so that you have the default Subtitles menu - does text then display?

  • Hi Chris

    You're right, my post was amazingly sparse when it came to actual data :) Sorry.

    Those are two links showing the AC setting I've disabled (I can only see one that relates) and also the text in the text box at runtime. The TextMesh component shows text in the text field, but it doesn't show in the UI. If, at runtime, I duplicate that textmeshpro object then the new one shows, so I think that AC is "stuck" at showing a blank text string waiting for the typewriter effect to move forward, which I've disabled.

    The same text field works fine without changes if I re-enable the setting above.

    Ultimately I want to have the typewriter effect enabled or disabled based on an Options setting probably linked to a GVAR but got stuck at just finding the right setting to change.


  • And the Menu is linked to TMPro via the TextMeshProIsPresent scripting define symbol?

    If the text is present in the TMPro component's Text field, then it looks like AC side of things is working.

    Try unchecking Auto Size and play with the Font Size field when this issue occurs - it may be that TMPro is involved here.

  • I can't see what the TMPro issue might be to cause this. If I duplicate the Text object at runtime (just highlight and hit CTL+D), the new object shows the text normally, and has exactly the same settings as the one that doesn't work. The only difference I can see would be that the old one is referred to by AC but the new one has inherited the settings and text but isn't being controlled by AC. I can't disable the old one as it immediately re-enables, but can with the new one, for example.

    The old one has correct autosize and font size, but changing those makes no difference.


  • I thnk it is an AC thing somewhere.

    If I put a script on the dialogue text component, and some debug lines in Update(), I can see that the MaxVisibleCharacters keeps changing back to 0, making the text invisible. This only happens if Scrolling is disabled.

    If I set the maxVisibleCharacters of TMPro to a large number, the text appears, but then the value is reset on the next frame.

    Here's a debug showing the Update() output before and aftger I change the value to a large number.

    For now, that's my work around ("If scrolling is disabled, then each frame change the maxvisible to 99999"). But it does feel like something is wrong somewhere.

    Again, If I clone the textmesh object at runtime, the new object has a maxvisiblecharacters value matching the text contents.

  • edited September 2023

    Quite right - it's related to the "maxVisibleCharacters" property, which AC is indeed controlling. Apologies for passing the buck prematurely.

    The issue specifically is that AC will affect this property when the Label element's TMPro Typewriter effect? option is checked - even if the option itself is no longer visible.

    I will address this properly, but you should be able to sort this in the meantime by re-enabling scrolling, unchecking the above (now visible) option, and then disabling scrolling once more.

  • Great news. So in my options when the player toggles Scroll Subtitles, I currently need to change both the Scroll Subtitles setting and also the menu item SpeechLine typewriter effect setting in order for it to work?

  • If you're making the setting dynamic via a player-configurable option, yes - for the moment.

    You can get an API reference to change the typewriter effect field through script by right-clicking the field's label. It'll be something of the form:

    AC.PlayerMenus.GetElementWithName ("Subtitles", "SubsLineLabel").hideScrollingCharacters = false;
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Welcome to the official forum for Adventure Creator.