Page 1 of 1
Disabling Dialogue System Text color overrides
Posted: Fri Dec 22, 2017 4:28 am
by patxiku
Hi, I'm trying to make a dynamic color texts on my game but Dyalogue system keeps overriding text colors.
How can I disable this?
I'm changing color property from my NPC Subtitle Line Text property but in a milisecond Dyalogue System overrides it.
Thanks in advance.
Re: Disabling Dialogue System Text color overrides
Posted: Fri Dec 22, 2017 9:26 am
by Tony Li
Hi,
How are you changing the color?
Can you use [em] tags or rich text codes? For example:
- Dialogue Text: "<color=red>This is red text.</color>"
If you're talking about response buttons, inspect the response button and untick the option to set the label color.
Re: Disabling Dialogue System Text color overrides
Posted: Tue Jan 02, 2018 1:15 am
by patxiku
I'm changing the Text component references values as follows:
Code: Select all
reference = GetComponent<Text>();
reference.color = overrideColor;
reference.font = overrideFont;
reference.fontSize = overrideSize;
It seems to be overrited each frame by the dialogue system itself, since I have no other style changes.
Edit: I can't change the text itself to add tags since it'd be counterporductive.
Re: Disabling Dialogue System Text color overrides
Posted: Tue Jan 02, 2018 4:42 am
by patxiku
Nevermind, I created a new class that inhertis from "UnityUIDialogueUI" and overrided the ShowDialogue Function so it overrides the dialogue style too.
That seems to have fixed it
Thanks!