Need Help with basic Select Item Script

Ask gaming related questions (AHK v1.1 and older)
royaleadvisor
Posts: 1
Joined: 16 Jun 2017, 18:17

Need Help with basic Select Item Script

16 Jun 2017, 18:23

I'm new to ahk , just started today and I am trying to make a code which will start clicking at a certain area, and after some time click at the coordinates to the right of that area. I have been trying to follow the website's instructions, here is the code:

Code: Select all

#NoEnv  ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn  ; Enable warnings to assist with detecting common errors.
SendMode Input  ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir%  ; Ensures a consistent starting directory.

xValue = 1050
yValue = 259
Loop 
{
    Send, Click right %xValue%, %yValue%
    Send, Click up right
    Sleep, 1000
    xValue += 44
}
User avatar
Spawnova
Posts: 554
Joined: 08 Jul 2015, 00:12
Contact:

Re: Need Help with basic Select Item Script

18 Jun 2017, 03:41

You were close, but you accidentally mixed the send command with click

Code: Select all

#NoEnv  ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn  ; Enable warnings to assist with detecting common errors.
SendMode Input  ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir%  ; Ensures a consistent starting directory.
SetMouseDelay,50 ;small sleep between mouse actions, increases reliability in some games


f1:: ;Set F1 as hotkey
xValue := 1050
yValue := 259
loop 2 { ;do below actions 2 times
	Click right %xValue%, %yValue%
	Click up right
	xValue += 44
	sleep 1000
}
return ;return script to idle

Return to “Gaming Help (v1)”

Who is online

Users browsing this forum: Shoobis and 31 guests