Posts: 228
Threads: 7
Joined: Dec 2014
Posts: 228
Threads: 7
Joined: Dec 2014
12-24-2014, 07:38 AM
(This post was last modified: 12-24-2014, 08:37 AM by GkevinOD.)
I manage to fix it I believe. It will just skip the base if gold is not found. I will make it more efficient later, but this should also work:
Code:
Func CheckSearch()
Sleep(2000)
Local $countY = 0
Local $countExit = 0
$GoldCheck = getGold($x_default, $y_default + $countY)
While $GoldCheck = ""
If $countY >= 5 Then $countY = 0
$countY += 1
$countExit += 1
$GoldCheck = getGold($x_default, $y_default + $countY)
Sleep(200)
If $countExit >= 50 Then
ControlClick ($HWnD, "","", "left", "1", 715*$x_ratio, 405*$y_ratio) ;Click Next
$countExit = 0
EndIf
If $RunState = False Then
ExitLoop
EndIf
WEnd
;GUICtrlSetData($Results, "Finish check" & @CRLF, -1)
EndFunc
Posts: 37
Threads: 4
Joined: Dec 2014
Reputation:
0
why the bot is not skipping bases? no search
Posts: 228
Threads: 7
Joined: Dec 2014
12-24-2014, 08:05 AM
(This post was last modified: 12-24-2014, 08:12 AM by GkevinOD.)
Posts: 228
Threads: 7
Joined: Dec 2014
Posts: 14
Threads: 1
Joined: Dec 2014
Reputation:
0
There's so many changes and updates! This is amazing hah. Hard to keep up. Anyone have the most up to date changes ?
Posts: 228
Threads: 7
Joined: Dec 2014