Page 1 of 1

BTD6 afk farm again....

Posted: 15 Feb 2020, 07:15
by heldge
I have a problem with my autofarm for btd6, its not really about the autofarm its about a popup you get when you level up or unlock something. I need an imagesearch thats constantly searching for 4 different images while the autofarm is running. If it finds an image it needs to pause the autofarm and perform some clicks and stuff and then resume the autofarm. Ive litterally asked everywhere for help (even here) but I always get the answer use this or that but Im not smart enough for stuff like that. Ive tried to make this script work for over a month but without any sucess... Can someone pls help?

The loop is the autofarm. Heres the script:


Code: Select all

CoordMode, Mouse, screen

CoordMode, Pixel, screen







ImageSearch, x, y, 0, 0, 1920, 1080, pic4.JPG



{

Click 960, 820

Sleep 1500

return

}









ImageSearch, x, y, 0, 0, 1920, 1080, pic3.JPG



{

Click

}







ImageSearch, x, y, 0, 0, 1920, 1080, pic2.JPG



{

Click

Sleep 150

Click 970, 700



}







ImageSearch, x, y, 0, 0, 1920, 1080, pic1.JPG



{

Click

}







F7::

Click 800, 900 ; Play

Sleep 500

Click 1400, 950 ; Expert

Sleep 500

Click 900, 600 ; Dark Castle

Sleep 500

Click 550, 400 ; Easy

Sleep 500

Click 550, 600 ; Standard

Sleep 5000

Loop {

Send " " ; Start game

Sleep 100

Send " " ; Increase Speed

Send "u" ; Hero (Obyn)

Sleep 100

Click 549, 617

Sleep 100

Send "q" ; Dart Monkey

MouseMove 549, 500

Sleep 100

Click 549, 489

Sleep 100

Click 549, 489

Sleep 200

Send "-" ; Dart -> 0-0-1

Sleep 100

Click 785, 555

Sleep 100

MouseMove 1500, 1000

Sleep 13800

MouseMove 1084, 409

Sleep 100

Send "x" ; Monkey Sub

Sleep 100

Click 1084, 409

Sleep 100

Click 1084, 409

Sleep 100

Click 1500, 1000

Sleep 24800

Click 1084, 409

Sleep 100

Send "," ; Sub -> 1-0-0

Sleep 100

Send "," ; Sub -> 2-0-0

Sleep 100

Click 1500, 1000

Sleep 18800

Click 1084, 409

Sleep 100

Send "-" ; Sub -> 2-0-1

Sleep 100

Click 1500, 1000

Sleep 48800

Click 1084, 409

Sleep 100

Send "-" ; Sub -> 2-0-2

Sleep 100

Click 1500, 1000

Sleep 40800

Click 1084, 409

Sleep 100

Send "-" ; Sub -> 2-0-3

Sleep 100

Click 1500, 1000

Sleep 59800

Click 1084, 409

Sleep 100

Send "-" ; Sub -> 2-0-4

Click 549, 489

Sleep 200

Send "-" ; Dart -> 0-0-2

Sleep 100

Click 1500, 1000

Sleep 58500

MouseMove 960, 430

Sleep 100

Send "k"

Click 960, 430

Sleep 100

Click 960, 430

Sleep 200

Send "."

Sleep 100

Send "."

Sleep 100

Send ","

Sleep 100

Send ","

Sleep 100

Click 1500, 1000

Sleep 48000

MouseMove 770, 430

Sleep 100

Send "a"

Sleep 100

Click 770, 430

Sleep 100

Click 770, 430

Send "."

Sleep 100

Send "."

Sleep 100

Send "."

Sleep 100

Click 1500, 1000

Sleep 20000

Click 1150, 911 ; Freeplay

Sleep 1000

Click 980, 770 ; Ok

Sleep 1500

Click 1600, 40 ; Menu

Sleep 1000

Click 1070, 850 ; Restart

Sleep 1000

Click 1140, 730 ; Confirm

Sleep 1500

MouseMove 549, 617

Sleep 500

}











return



F8::

Exitapp