Image recognition

Ask gaming related questions
AviationGuy
Posts: 185
Joined: 17 Jan 2019, 10:13

Re: Image recognition

27 Mar 2019, 04:05

Welcome to the forums!
It is :)
You'll need to do something like this.

Code: Select all

f1::																		; hotkey
Loop																		; keep looking for image
	ImageSearch, FoundX, FoundY, 0, 0, A_Screenwidth, A_Screenheight, C:\Path\Image.png	; search for image
Until !ErrorLevel															; keep searching for image UNTIL found
{
	MouseClick,, %FoundX%, %FoundY%											; mouseclick command
	send a																; send key command
}
return																	; end of script
Take a look at:
- ImageSearch
- Send
- MouseClick
And the AHK tutorial should help you too.

Return to “Gaming”

Who is online

Users browsing this forum: No registered users and 40 guests