I'm trying to match the colour of text I receive from the mud.
I'm using world.GetLinesInBufferCount, world.GetStyleInfo and world.GetLineInfo.
The problem is the output buffer changes to rapidly that I can't detect the text I want.
Am I supposed to match the trig_line with a line from the output buffer by iterating through it?
I tried outputting the last 25 lines of the output buffer using GetLineInfo, counting from GetLinesInBufferCount - 25 to GetLinesInBufferCount.
The output was skipping lines from the screen, it was not sequential.
Is there a method that gets called when the output buffer changes, or am I going about this the wrong way.
for example, this never seems to work:
wow my code tags aren't even working... im doing godlike tonight
I'm using world.GetLinesInBufferCount, world.GetStyleInfo and world.GetLineInfo.
The problem is the output buffer changes to rapidly that I can't detect the text I want.
Am I supposed to match the trig_line with a line from the output buffer by iterating through it?
I tried outputting the last 25 lines of the output buffer using GetLineInfo, counting from GetLinesInBufferCount - 25 to GetLinesInBufferCount.
The output was skipping lines from the screen, it was not sequential.
Is there a method that gets called when the output buffer changes, or am I going about this the wrong way.
for example, this never seems to work:
#check last line in the buffer for colour yellow
line = world.GetLinesInBufferCount - 1
styleRuns = world.GetLineInfo (line, 11)
ansiColour = world.GetStyleInfo (line, styleRuns, 14)
if ansiColour == 65535:
print('found')
wow my code tags aren't even working... im doing godlike tonight