Tasharen Entertainment Forum
Support => NGUI 3 Support => Topic started by: leegod on August 13, 2014, 12:48:04 AM
-
So I want to make message windows.
Messages will have various color as its sort (battle message, event message, etc), so I want to pass string with color info to UITextList
but UITextList seems only give .Add(str) function. So color should be "[FF0000]msg" like this.
Isn't there another way to pass color info? like, textlist.Add(str, colorpicker);
-
Add("[ff0000]" + yourtext)? :P
Also note NGUIText.EncodeColor.
Add("[" + NGUIText.EncodeColor(Color.red) + "]" + yourText);
-
Also note NGUIText.EncodeColor.
Add("[" + NGUIText.EncodeColor(Color.red) + "]" + yourText);
oh Good solution! Thank!