Click button on text color change

I often play online io dice games with friends and I’m trying to automate my rolls. To do that, I need to press the “STOP THE ROLLS” as soon as the 10th li element turns green, but each time, the number might be random so is there a way to detect the style color or something like that?

Post url of page please

Try to use a better xpath and you need not color in xpath

XPath is fastest, if it works. Otherwise use the new visualGetPixelColor: UI.Vision RPA - VisualAssert check colors