-
Notifications
You must be signed in to change notification settings - Fork 0
/
pot-wep-top.ahk
103 lines (103 loc) · 2.28 KB
/
pot-wep-top.ahk
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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
; Script to cycle through pots, weapons, and tops on EG Shaiya.
; @author Jody Rutter
; @version 4/05/2020 v1.0
; Notes: Please put dispel pots on the numberpad hot bar in positions 1,2,3,4,5.
; Please put the weapons and tops in the 3rd hot bar on positions 1,2,3,4,5, and 6.
; Please use '.' as the hotkey for using the 3rd toolbar (this can be set in Options->System Settings->Numeric Hot Keys->Enabler Key).
; Enter will suspend the script until it is hit again (incase a user is typing a message).
; Program starts assuming a user is not typing a message.
; If you press 'enter' in another window, the script will count it.
; F12 will pause the program and, when it resumes, the program will start from its initial state.
; Program will have a random time of up to 50ms between using pots.
f12::
Pause
Suspend
EnterPressed := true
return
^j::
EnterPressed := true
Loop{
if(EnterPressed = true){
Sleep, Rand(50)
if(EnterPressed = true){
send {Numpad1 down}
send {Numpad1 up}
}
Sleep, Rand(50)
if(EnterPressed = true){
send {. down}
send {Numpad1 down}
send {Numpad1 up}
send {. up}
}
Sleep, Rand(50)
if(EnterPressed = true){
send {Numpad2 down}
send {Numpad2 up}
}
Sleep, Rand(50)
if(EnterPressed = true){
send {. down}
send {Numpad2 down}
send {Numpad2 up}
send {. up}
}
Sleep, Rand(50)
if(EnterPressed = true){
send {Numpad3 down}
send {Numpad3 up}
}
Sleep, Rand(50)
if(EnterPressed = true){
send {. down}
send {Numpad3 down}
send {Numpad3 up}
send {. up}
}
Sleep, Rand(50)
if(EnterPressed = true){
send {Numpad4 down}
send {Numpad4 up}
}
Sleep, Rand(50)
if(EnterPressed = true){
send {. down}
send {Numpad4 down}
send {Numpad4 up}
send {. up}
}
Sleep, Rand(50)
if(EnterPressed = true){
send {Numpad5 down}
send {Numpad5 up}
}
Sleep, Rand(50)
if(EnterPressed = true){
send {. down}
send {Numpad5 down}
send {Numpad5 up}
send {. up}
}
Sleep, Rand(50)
if(EnterPressed = true){
send {. down}
send {Numpad6 down}
send {Numpad6 up}
send {. up}
}
}
}
~Enter::
{
if(EnterPressed = true){
EnterPressed := false
}
else{
EnterPressed := true
}
}
Rand( a=0.0, b=1 ) {
IfEqual,a,,Random,,% r := b = 1 ? Rand(0,0xFFFFFFFF) : b
Else Random,r,a,b
Return r
}