Is anyone interested in a bot that sends your minions out on 1 minute adventures so you can level them up...if so ill release it and work on making it function for 5 and 15min adventures.
#include <Misc.au3>
#include <Date.au3>
#include <MsgBoxConstants.au3>
#include <WinAPI.au3>
Local $pos[2]
Local $i, $j
Local $timer
Local $minionLevelCount
Global $g_AdventureCardLoc[2]
Global $g_MinionLoc[2]
Global $g_SendButtonLoc[2]
Global $g_AdventureClaimLoc[2]
Global $g_AdventureTime=60000 ; minion adventure time in milliseconds. Change to 300000 for 5mins, 900000 for 15mins, 2880000 for 8hour, etc.
HotKeySet("{esc}","Terminate")
Setup()
While 1
; set minion reward card
MouseClick("left",$g_AdventureCardLoc[0],$g_AdventureCardLoc[1])
Sleep(200)
; select minion
MouseClick("left",$g_MinionLoc[0],$g_MinionLoc[1])
Sleep(200)
;Send the minion
MouseClick("left",$g_SendButtonLoc[0],$g_SendButtonLoc[1])
Sleep(200)
; now wait until the adventure is done
Sleep($g_AdventureTime+500)
; click the reward!
MouseClick("left",$g_AdventureClaimLoc[0],$g_AdventureClaimLoc[1])
Sleep(200)
; write out to the Autoit console the results
$minionLevelCount=$minionLevelCount+1
ConsoleWrite(_NowTime(5)&" Minion Level "&$minionLevelCount&@LF)
Sleep(100)
WEnd
Func Setup()
Local $mousePos
$mousePos=GetMouseClickPosition('Adventure Card')
$g_AdventureCardLoc[0] = $mousePos[0]
$g_AdventureCardLoc[1] = $mousePos[1]
$mousePos=GetMouseClickPosition('Minion Card')
$g_MinionLoc[0] = $mousePos[0]
$g_MinionLoc[1] = $mousePos[1]
$mousePos=GetMouseClickPosition('Send Now Button')
$g_SendButtonLoc[0] = $mousePos[0]
$g_SendButtonLoc[1] = $mousePos[1]
$mousePos=GetMouseClickPosition('Hurry Button, wait a second, then click Cancel')
$g_AdventureClaimLoc[0] = $mousePos[0]
$g_AdventureClaimLoc[1] = $mousePos[1]
Sleep($g_AdventureTime+250)
; click the reward!
MouseClick("left",$g_AdventureClaimLoc[0],$g_AdventureClaimLoc[1])
Sleep(200)
EndFunc
Func GetMouseClickPosition($clickPrompt)
; handle for _isPressed
Local $hDLL = DllOpen("user32.dll")
Local $clicked
Local $mousePos
ConsoleWrite(_NowTime(5)&" ******************** Left Click "&$clickPrompt&" ***************"&$minionLevelCount&@LF)
$clicked = False
While Not $clicked
If _IsPressed("01", $hDLL) Then
; you clicked on the screen, get the position on the screen where the click was
$mousePos=MouseGetPos()
; now wait until the click is completed
While _IsPressed("01", $hDLL) > 1
Sleep(10)
WEnd
$clicked=True
EndIf
Sleep(10)
WEnd
Sleep(250)
DllClose($hDLL)
Return $mousePos
EndFunc
Func Terminate()
Exit
EndFunc