I am using scrolling text with the Unity UI per my post https://www.pixelcrushers.com/phpbb/vie ... 756#p20756
If the text is too long, it shows an error about exceeding the max vertices.
To fix this, I replaced all Text components with Text Mesh Pro - Text (UI), removed sizerText which doesn't seem to be necessary anymore, and replaced Unity UI Typewriter Effect with Text Mesh Pro Typewriter Effect
This works, however the response menu overlaps the text itself
Under https://www.pixelcrushers.com/dialogue_ ... h_pro.html it says "An example scene is in the Example folder." however there is no "Example" folder. There is an "Examples" folder, but that contains Assets/Plugins/Pixel Crushers/Dialogue System/Scripts/Editor/Fields/Examples/CustomFieldType_SceneType.cs
I am able to repro this in the latest version of Dialogue System For Unity.
Repro:
Add Dialogue Manager to Scene
Replace Text and Unity UI Typewriter as indicated above
Check Auto Scroll Enabled and assign the two fields
In TextMeshPro Typerwriter Effect, On Character, set ScrollRect.verticalNormalizedPosition to zero for Scroll Rect
Start any long conversation
Response menu overlaps text when using TextMeshPro
Response menu overlaps text when using TextMeshPro
- Attachments
-
- Capture.PNG (196.59 KiB) Viewed 1307 times
Re: Response menu overlaps text when using TextMeshPro
Hi,
That manual page is for the old, deprecated TextMesh Pro Support package. (Near the top of the page, it says: "THIS PAGE IS ONLY FOR LEGACY PROJECTS THAT WERE CREATED BEFORE THE DIALOGUE SYSTEM'S STANDARD DIALOGUE UI SYSTEM. THE CURRENT WAY TO USE TEXTMESH PRO IS TO ENABLE INTEGRATION AS DESCRIBED IN DIALOGUE UIs.")
The current way to enable TextMesh Pro integration is here: TextMesh Pro Support. I suspect you're already using this, so I'm including the link just in the off chance that you're not using it yet.
The dialogue UI isn't doing anything special to lay out the subtitle text and response menu buttons. It just relies on the Scroll Content's Vertical Layout Group. Make sure your subtitle text is configured to work with the layout, and to expand to fit its text. (For example, tick the Vertical Layout Group's Control Child Size > Height checkbox.)
That manual page is for the old, deprecated TextMesh Pro Support package. (Near the top of the page, it says: "THIS PAGE IS ONLY FOR LEGACY PROJECTS THAT WERE CREATED BEFORE THE DIALOGUE SYSTEM'S STANDARD DIALOGUE UI SYSTEM. THE CURRENT WAY TO USE TEXTMESH PRO IS TO ENABLE INTEGRATION AS DESCRIBED IN DIALOGUE UIs.")
The current way to enable TextMesh Pro integration is here: TextMesh Pro Support. I suspect you're already using this, so I'm including the link just in the off chance that you're not using it yet.
The dialogue UI isn't doing anything special to lay out the subtitle text and response menu buttons. It just relies on the Scroll Content's Vertical Layout Group. Make sure your subtitle text is configured to work with the layout, and to expand to fit its text. (For example, tick the Vertical Layout Group's Control Child Size > Height checkbox.)
Re: Response menu overlaps text when using TextMeshPro
The instructions on the updated webpage are
"Then you can remove the UI Text component from the NPC Subtitle Line GameObject, add a TextMeshProUGUI, and assign it to the field. If you want to use a typewriter effect, you can also remove the Unity UI Typewriter Effect from the GameObject and add a Text Mesh Pro Typewriter Effect."
That is exactly what I did.
The result is the response menu overlaps the text. This does not happen when using Unity UI text.
"Then you can remove the UI Text component from the NPC Subtitle Line GameObject, add a TextMeshProUGUI, and assign it to the field. If you want to use a typewriter effect, you can also remove the Unity UI Typewriter Effect from the GameObject and add a Text Mesh Pro Typewriter Effect."
That is exactly what I did.
The result is the response menu overlaps the text. This does not happen when using Unity UI text.
Re: Response menu overlaps text when using TextMeshPro
This might help: If I let the text scroll normally it works OK. However, the problem occurs if I press continue to skip the text. This occurs if using "Optional for PC or Before Reponse Menu"
Re: Response menu overlaps text when using TextMeshPro
Hi,
Here's an example scene exported from Unity 2020.1:
DS_TestTMP_2020-12-07.unitypackage
It's set up the way you described, including the continue button. Try these settings:
1. Subtitle text: Typewriter's OnCharacter() event calls ScrollRect's UIScrollbarEnabler.CheckScrollbarWithResetValue = 0.
2. Menu: OnContentChanged() event calls ScrollRect's UIScrollbarEnabler.CheckScrollbarWithResetValue = 0.
Here's an example scene exported from Unity 2020.1:
DS_TestTMP_2020-12-07.unitypackage
It's set up the way you described, including the continue button. Try these settings:
1. Subtitle text: Typewriter's OnCharacter() event calls ScrollRect's UIScrollbarEnabler.CheckScrollbarWithResetValue = 0.
2. Menu: OnContentChanged() event calls ScrollRect's UIScrollbarEnabler.CheckScrollbarWithResetValue = 0.