Page 1 of 2
Dialogue in Scroll Rect goes past the bottom
Posted: Tue Jan 21, 2020 10:13 pm
by marafrass
Firstly thanks for all the amazing stuff that's packed into this asset - you've made so many parts of my development so much easier!
I'm having an issue with accumulating dialogue boxes - the lines will generally scroll just fine, but in longer conversations, the new lines tend to get placed far down the text box, so only half the line is visible. I have auto scroll on, as well as a really fast typewriter effect.
Is there a way to make sure that the subtitle box is always scrolled to the very bottom, or is there a way for text to accumulate from the bottom upwards, rather than top-down? Any typical common pitfalls with this?
Hopefully I've made the problem clear enough to communicate what I mean!
Additionally, I was curious - after selecting a dialogue response, is there a way to skip the PC response without removing it from the text box? "Skip PC line" removes it entirely, and I'd like to go straight to the NPC response but still log the PC line.
Re: Dialogue in Scroll Rect goes past the bottom
Posted: Wed Jan 22, 2020 8:35 am
by Tony Li
Hi,
marafrass wrote: ↑Tue Jan 21, 2020 10:13 pmI'm having an issue with accumulating dialogue boxes - the lines will generally scroll just fine, but in longer conversations, the new lines tend to get placed far down the text box, so only half the line is visible. I have auto scroll on, as well as a really fast typewriter effect.
Is there a way to make sure that the subtitle box is always scrolled to the very bottom, or is there a way for text to accumulate from the bottom upwards, rather than top-down?
This post has an example scene with an explanation of how it's set up.
marafrass wrote: ↑Tue Jan 21, 2020 10:13 pmAdditionally, I was curious - after selecting a dialogue response, is there a way to skip the PC response without removing it from the text box? "Skip PC line" removes it entirely, and I'd like to go straight to the NPC response but still log the PC line.
Tick Subtitle Settings > Show PC Subtitles During Line and
untick Skip PC Line After Response Menu. Then set Camera & Cutscene Settings > Default Player Sequence to: Continue()
This will ensure that conversations always how the player's lines, but it continues them immediately instead of allowing time for their typewriter effect to play.
Re: Dialogue in Scroll Rect goes past the bottom
Posted: Wed Jan 22, 2020 3:54 pm
by marafrass
Thanks - the solution to the second, additional issue actually fixed the overlapping dialogues.
Another issue popped up, though: For some reason, dialogues slow down a lot over time. After a fair amount of text, clicking the response buttons gets more and more lag. Is this again something simple I might just have overlooked?
Thanks again, and thanks for being so patient. I'm very much a beginner so I appreciate all the help I can get.
Re: Dialogue in Scroll Rect goes past the bottom
Posted: Wed Jan 22, 2020 5:26 pm
by Tony Li
Is it delaying before typing, but then typing at the expected speed?
Or does the typing of each character get slower the more text there is?
What versions of Unity and the Dialogue System are you using?
Are you using one of the included dialogue UI prefabs? (Or did you base your dialogue UI on a prefab and customize it?)
Please feel free to send a reproduction project to tony (at) pixelcrushers.com. I'll be happy to take a look directly. This issue, or at least a similar one, was reported in an older version of the Dialogue System, but it should be fixed in recent versions.
Re: Dialogue in Scroll Rect goes past the bottom
Posted: Wed Jan 22, 2020 6:39 pm
by marafrass
Is it delaying before typing, but then typing at the expected speed?
Pretty much, but if you keep clicking response buttons, the lag will eventually get so bad the text just pops into place.
What versions of Unity and the Dialogue System are you using?
Unity 2019.2.17f1, and DS 2.2.4.
Are you using one of the included dialogue UI prefabs? (Or did you base your dialogue UI on a prefab and customize it?)
Modifying the WRPG UI!
After playing around with it for a bit, I noticed that the lag only appears if I have the typewriter active. I was planning on turning that off anyway, but now the problem is that the text doesn't autoscroll. If there's a simple way of fixing that, I'd be all set. If not, I'll send a reproduction project your way!
Re: Dialogue in Scroll Rect goes past the bottom
Posted: Wed Jan 22, 2020 7:43 pm
by Tony Li
Hi,
Use the steps below. (Sorry they're a bit obscure.)
1. Remove the typewriter effect from the Subtitle Text GameObject.
2. Add a UI Scrollbar Enabler component to the main dialogue UI GameObject (e.g., WRPG Template Standard Dialogue UI). Assign the 3 fields (Scroll Rect, Scroll Content, and Scrollbar).
3. Add a Dialogue System Events component to the main dialogue UI GameObject. Add an entry to Conversation Events > On Conversation Line (Subtitle). Assign the UI Scrollbar Enabler, and select UIScrollbarEnabler.CheckScrollbarWithResetValue. A numeric field will appear; leave it at zero.
Re: Dialogue in Scroll Rect goes past the bottom
Posted: Wed Jan 22, 2020 8:38 pm
by marafrass
Works like a charm, perfect! Thank you so much!
Re: Dialogue in Scroll Rect goes past the bottom
Posted: Wed Jan 22, 2020 8:54 pm
by Tony Li
Happy to help!
Re: Dialogue in Scroll Rect goes past the bottom
Posted: Tue Sep 01, 2020 5:49 am
by aaajiao
I'm using unity2019.4 now and I've common sense all the above approaches and it won't work!
https://www.pixelcrushers.com/phpbb/vie ... 7&start=10
https://forum.unity.com/threads/scroll- ... ol.339661/
I have common sense, none of these ways will allow the scroll to move based on option position, the UI I use is Basic Standard Dialogue UI.
Community help is so needed.
Re: Dialogue in Scroll Rect goes past the bottom
Posted: Tue Sep 01, 2020 10:53 am
by Tony Li
The ScrollToMe script should work.
If it doesn't, please post screenshots of your setup.