-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathAFKFishing.ahk
More file actions
51 lines (48 loc) · 1.01 KB
/
AFKFishing.ahk
File metadata and controls
51 lines (48 loc) · 1.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
CoordMode Pixel Screen
CoordMode Mouse Screen
SetTitleMatchMode 2
SetTimer, AutoRestartTimer, 300000
SetTimer, AutoRestartTimer, Off
*F11::
AfkToggle := !AfkToggle
If (AfkToggle)
{
ControlClick,, Minecraft,, right,, D
}
else
{
ControlClick,, Minecraft,, right,, U
}
return
*F12::
AutoRestart := !AutoRestart
if(AutoRestart)
{
SetTimer, AutoRestartTimer, On
}
else
{
SetTimer, AutoRestartTimer, Off
}
return
AutoRestartTimer:
ImageSearch, FoundX, FoundY, 0, 0, A_ScreenWidth, A_ScreenHeight, back.png
if(ErrorLevel = 0)
{
ControlClick,, Minecraft,, right,, U
SetTimer, AutoRestartTimer, Off
MouseClick, left, FoundX+200, FoundY+20
Sleep 300000
ImageSearch, FoundX, FoundY, 0, 0, A_ScreenWidth, A_ScreenHeight, realm.png
While(ErrorLevel > 0)
{
Sleep 60000
ImageSearch, FoundX, FoundY, 0, 0, A_ScreenWidth, A_ScreenHeight, realm.png
}
MouseClick, Left, FoundX+291, FoundY+32, 2
Sleep 60000
ControlClick,, Minecraft,, right,, D
AfkToggle = 1
SetTimer, AutoRestartTimer, On
}
return