2 Replies Latest reply on Nov 12, 2012 7:22 AM by WarZebra6

    Disabled color change...


      Hello everybody,

      this is my first comment here because for all other problems I found solution without registration

      Anyway I was looking how to disabled color change (just some part of sentence) which should be highlighted, example is right here (it's part of topics in rpg game):

      Tell me some rumours

      I killed the dragon (quest)


      In the init. state text "I killed the dragon" is black and text "(quest)" is yellow. Highlight color is red :

      mc_Topics.mc_topic0.tField.textColor = 0xb21d22; // init. state highlight first topic

      Now if I want highlight sentence with "(quest)" it's make this (simple) :

      mc_Topics["mc_topic" + Index].tField.textColor = 0xb21d22;

      but it will highlight of course all sentence by red color even if I want to quest word stay yellow.

      I know I can make it somehow like this for highlight :

      mc_Topics["mc_topic" + index].tField.html = true;

      mc_Topics["mc_topic" + index].tField.htmlText = lowerCase + "<FONT COLOR = '#695f49'><FONT SIZE = '24'>" + quest + "</FONT></FONT>";

      But problem is that in function where I'm setting highlight I dont know variables for text (lowerCase) and quest (there can different text).

      Thanks for any suggestion : )