Page 1 of 1

If action happens earlier than, statement

Posted: 24 May 2022, 11:22
by VetX
Hey, i need help with code that performs an action if pixel color changes earlier than a certain amount of time

Code: Select all

CoordMode, Pixel, Relative

Loop
 {
PixelSearch, x, y, 1826, 822, 1834, 827, 0xE5464F
if x, y, "changes earlier than" 1000,
{
DetectHiddenWindows, On 
WinClose, %fullScriptPath% ahk_class AutoHotkey
}
 }

Re: If action happens earlier than, statement  Topic is solved

Posted: 24 May 2022, 11:28
by BoBo
A_TickCount :?: ... 'if elapsed time < expected time'