Home   Help Search Login Register  

Author Topic: Color of Text  (Read 1039 times)

0 Members and 2 Guests are viewing this topic.

Offline Carroll

  • Members
  • *
  • Mission Designer (MP-"well tryin to capiche"
Color of Text
« on: 15 May 2008, 09:52:47 »
hi, i can't seem to find anything definitive about changing the onscreen text color. Did find however some topics related to OPF in the forums suggesting the use of a colorText command, Does this command exist?

*I am looking for a way to define the color of the main text that is displayed onscreen (eg such as when a trigger is activated or when using the titleText command)

Is this easy to do & how?

Offline Mandoble

  • Former Staff
  • ****
    • Grunt ONE and MandoMissile suite
Re: Color of Text
« Reply #1 on: 15 May 2008, 10:12:17 »
You need to define your own title resources, you cannot modify the color of the default ones.
For example:
Code: [Select]
// description.ext

class RscTitles
{
   class your_first_title
   {
      idd=-1;
      movingEnable=true;
      duration=15;
      name="your_first_text";
      controls[]={"your_first_text"};
      class your_first_text
      {
         idc = -1;
         x = 0;
         y = 0;
         w = 1;
         h = 1;
         text = "Your title text";
         type = 0;
         style = 2+256;
         colorBackground[] = {0, 0, 0, 0};
         colorText[] = {0, 0, 1, 1};
         font = "TahomaB";
         sizeEx = 0.1;
      };
   };
};

In your trigger's EFFECT select type: RESOURCE, and in the list below select your_first_text. Note that after modifying description.ext you will need to reload the mission from the editor for the changes to have effect.

Offline Carroll

  • Members
  • *
  • Mission Designer (MP-"well tryin to capiche"
Re: Color of Text
« Reply #2 on: 15 May 2008, 11:33:20 »
Understood, will see what i can conjure  :good: