I thought i posted another message but doesnt look like i stuffed up somehow.
OK so what i want is to find the colour of the first character on each line and if it matches a colour in a list i have then process it. Unfortunately there are no text matches that i can do on these lines. Totally random as to what will be coming in.
My problem comes when trying to find the colour of that character.
In using a colour trigger its capturing any line that has the colour in it.
This wont work for me as there are a lot of lines using the same colours. (Not first character though)
When using isAnsiFgColor i dont know if its using the original line match or the character that ive found.
Please note the code below isnt syntactically correct - just trying to describe what im after.
So here is what id like to do
"This is a line from the mud"
getCurrentLine()
local firstChar = string.sub(line, 1, 1)
if firstChar blue then --i know isAnsiFgColor(colour) compares a colour but i dont know what its using
process this
else
do not process this
end
As always if anyone has some ideas or some code to do this that would be great.