I'm using MUSHclient 5.05
I'm attempting to set a trigger to grab room names from Armageddon MUD. The room name lines are bold yellow text, and they end with brown text describing the exits.
When I set a trigger to match on yellow lines and send the line to a script, the trigger never seemed to match anything. So I moved to the trigger GUI and attempted to duplicate the setup, hoping I'd just messed up the trigger definition in the plugin.
This eventually led me to just seeing if I was missing something fundamental about triggers in MUSHclient, so I started testing with just a '*' for the match and no other requirements. As you'd expect, that matched all lines.
Changing only the setting to have it match yellow lines produced no matches. Oddly enough, changing it to only match white lines matched exactly as you'd expect. No other color settings managed to match any lines.
This made me wonder if there was something I didn't understand about how MUDs send colors, and that maybe the colors in Armageddon weren't coming as simple ANSI codes. So I matched on a word from the yellow room name line and sent the whole line to a script. The script ran GetStyle on the third column and it told me the line was yellow.
I'm out of ideas as to why I can't seem to match colored lines. I'm hoping it's just something that I'm failing to understand, but I seem to have pinned the issue down tightly enough to warrant a bug report.
To make sure I wasn't missing some check box that could help, here are some screen shots: http://imgur.com/a/sFFmj
[Solved]
Using `Display -> Text Attributes` on the line in question revealed that the MUD was sending all colors except for white as 256-ANSI color codes instead of plain ANSI color codes. MUSHclient triggers don't match on 256-ANSI color codes, so a workaround is used for this match: Match on every line and send the match to another script that reads the styles table to determine the color.
I'm attempting to set a trigger to grab room names from Armageddon MUD. The room name lines are bold yellow text, and they end with brown text describing the exits.
When I set a trigger to match on yellow lines and send the line to a script, the trigger never seemed to match anything. So I moved to the trigger GUI and attempted to duplicate the setup, hoping I'd just messed up the trigger definition in the plugin.
This eventually led me to just seeing if I was missing something fundamental about triggers in MUSHclient, so I started testing with just a '*' for the match and no other requirements. As you'd expect, that matched all lines.
Changing only the setting to have it match yellow lines produced no matches. Oddly enough, changing it to only match white lines matched exactly as you'd expect. No other color settings managed to match any lines.
This made me wonder if there was something I didn't understand about how MUDs send colors, and that maybe the colors in Armageddon weren't coming as simple ANSI codes. So I matched on a word from the yellow room name line and sent the whole line to a script. The script ran GetStyle on the third column and it told me the line was yellow.
I'm out of ideas as to why I can't seem to match colored lines. I'm hoping it's just something that I'm failing to understand, but I seem to have pinned the issue down tightly enough to warrant a bug report.
To make sure I wasn't missing some check box that could help, here are some screen shots: http://imgur.com/a/sFFmj
[Solved]
Using `Display -> Text Attributes` on the line in question revealed that the MUD was sending all colors except for white as 256-ANSI color codes instead of plain ANSI color codes. MUSHclient triggers don't match on 256-ANSI color codes, so a workaround is used for this match: Match on every line and send the match to another script that reads the styles table to determine the color.