Forum rules - please read before posting.

Size of Narrator's speech box using content size fitter...

edited April 2017 in Technical Q&A
I've implemented a separate UI to show narration "speech" text, with the aim of making something like AGS' Display function, and am using a content size fitter to make it fit the writing. The text pops up just fine, but if I have the speech set to "no scrolling", 50% of the time the size of the box is set for the previous line of text. If I have the scrolling on, and I skip the text half-way through, the text completes, but the box doesn't expand to cover all of the now-revealed text.

By the looks of it, this means that the size of the box no longer updates once all of the text is visible. Is there a way to get it to keep changing its size?

image

Also, as part of my effort to make a "Display" box, is there any way to set "Display subtitles forever until user skips" for just the narrator speech?

Comments

  • Being a Unity component, the Content Size Fitter ought to be able to update itself correctly.  I'd recommend testing it out without AC so be sure that it isn't the component itself that's at fault.

    You can also try adding a brief fade transition time to the Menu.

    As for displaying narrator speech forever, no - I'll see if that can be added.
  • Digging around, it appears that the resizing issue is to do with the Content Size Fitter updating the panel's size before the stage of a cycle that it updates the text. So, letter-by-letter typing works okay, but when all of the text suddenly appears, it no longer updates the box size.

    To get around this, I wrote a script to update the box's size more frequently, which seems to be doing the trick for now.
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.