Pay attention to what I posted. You didn’t change the search area at all. You also have % symbols around the PixelSearch output variables which doesn’t make sense. And the really shouldn’t be the same as the ones from MouseGetPos anyway. And trying to sleep for 1 ms will sleep for at least 10, btw. But there’s no reason to sleep since nothing happens after it. Maybe you think it’s looping. It’s not. Is that what you’re expecting it to do — to keep checking over and over after you press the hotkey once? And there is no reason for the $ prefix on the hotkey since you’re not sending that key.
CODE:
#SingleInstance, Force
SendMode, Input
SetBatchLines, -1
SetWorkingDir, %A_ScriptDir%
CoordMode, Pixel, Screen
CoordMode, Mouse, Screen
g::
MouseGetPos, MouseX, MouseY
PixelSearch, FoundX, FoundY, MouseX, MouseY, MouseX, MouseY, 0x1623FD, 1, Fast
if (ErrorLevel = 0)
Send, {Space Down}{Click}{Space up}
return
2::Reload
3::ExitApp
Statistics: Posted by boiler — Today, 16:41