 |
Tambu Novice
Joined: 31 Mar 2001 Posts: 39 Location: USA
|
Posted: Fri Feb 15, 2002 1:28 am
Command to check color of a word? |
Ok say I have a line that is the same except for a change in color on the words.
This is a line.
and the word line changes various colors say red blue yellow.
Now I know you could make one trigger with the ascii color codes for each possible color but is there a command I'm missing that would do something like this
#trig {This is a (%w).} {#if (%colorword(%1)=1) {#say red}}
so that you can do a command based on the color of the word line.
PS. I have found the %linecol command but this appears to only do the start of the line you can't do %linecol(%1) for example.
Input appreciated.
Tambu |
|
|
|
 |
Kjata GURU

Joined: 10 Oct 2000 Posts: 4379 Location: USA
|
Posted: Fri Feb 15, 2002 3:33 am |
A trigger ignores all ANSI codes in the MUD output and so there is no way to see the codes from insde the commands of a trigger. The only way to make a trigger not ignore the ANSI codes is to make it an ANSI trigger, but then the codes are only used to see if the pattern will still match or not.
Kjata |
|
|
|
 |
|
|
|