-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMain.ahk
More file actions
143 lines (121 loc) · 3.24 KB
/
Main.ahk
File metadata and controls
143 lines (121 loc) · 3.24 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
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
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
#SingleInstance Force
#Persistent
#NoEnv
SetWorkingDir %A_ScriptDir%
IniRead, DanceHkey, settings.ini, Application, DanceHkey
if (DanceHkey <> "ERROR") or (DanceHkey <> "")
Hotkey, % DanceHkey, Dance, UseErrorLevel ON
IniRead, AFKHkey, settings.ini, Application, AFKHkey
if (AFKHkey <> "ERROR") or (AFKHkey <> "")
Hotkey, % AFKHkey, AFK, UseErrorLevel
IniRead, PotionHkey, settings.ini, Application, PotionHkey
if (PotionHkey <> "ERROR") or (PotionHkey <> "")
Hotkey, % PotionHkey, Potion, UseErrorLevel
IniRead, BattleOneHkey, settings.ini, Application, BattleOneHkey
if (BattleOneHkey <> "ERROR") or (BattleOneHkey <> "")
Hotkey, % BattleOneHkey, BattleOne, UseErrorLevel ON
DanceHkeyOldest := DanceHkey
AFKHKeyOldest := AFKHkey
PotionHKeyOldest :=
BattleOneHKeyOldest := BattleOneHkey
AFKState := false
Gui, Margin, 8, 8
Gui, Add,Text,,Dance Game Bot:
Gui, Add, Hotkey, w100 gDanceHKey VDanceHkey, % DanceHkey
Gui, Add,Text,,AFK Mode:
Gui, Add, Hotkey, w100 gAFKHKey VAFKHkey, % AFKHkey
Gui, Add,Text,,Potion Motion Game Bot:
Gui, Add, Hotkey, w100 gPotionHKey VPotionHkey, % PotionHkey
Gui, Add,Text,,Auto-Battle One:
Gui, Add, Hotkey, w100 gBattleOneHKey VBattleOneHkey, % BattleOneHkey
Gui, Add, Button, gSave, Save
return
F9::
Gui,Show,Autosize,Options
return
Save:
IniWrite, % DanceHkey, settings.ini, Application, DanceHkey
IniWrite, % AFKHkey, settings.ini, Application, AFKHkey
IniWrite, % PotionHkey, settings.ini, Application, PotionHkey
IniWrite, % BattleOneHkey, settings.ini, Application, BattleOneHkey
Gui,Hide
return
F10::
ExitApp
return
DanceHKey:
HClear := DanceHkey
If (StateDanceHkey == "On") {
DanceHkeyOldest := HClear
StateDanceHkey := "Off"
Hotkey, %DanceHkeyOldmost%, OFF, UseErrorLevel OFF
} Else {
DanceHkeyOldmost := HClear
StateDanceHkey := "On"
Hotkey, %DanceHkeyOldest%, OFF, UseErrorLevel OFF
}
Hotkey, %DanceHkey%, Dance, UseErrorLevel ON
return
Dance:
Msgbox, Please set the game resolution to 800X600 and the UI size to HUGE before clicking Ok
RunWait, DanceBot.ahk
return
AFKHKey:
HClear := AFKHkey
If (StateAFKHkey == "On") {
AFKHKeyOldest := HClear
StateAFKHkey := "Off"
Hotkey, %AFKHKeyOldmost%, OFF, UseErrorLevel OFF
} Else {
AFKHKeyOldmost := HClear
StateAFKHkey := "On"
Hotkey, %AFKHKeyOldest%, OFF, UseErrorLevel OFF
}
Hotkey, %AFKHkey%, AFK, UseErrorLevel ON
return
AFK:
AFKState := !AFKState
if(AFKState){
SetTimer, AFKSend, 100
}
Else {
SetTimer, AFKSend, Off
}
return
AFKSend:
Send, {d down}
sleep, 10
Send, {d up}
return
PotionHKey:
HClear := PotionHkey
If (StatePotionHkey == "On") {
PotionHKeyOldest := HClear
StatePotionHkey := "Off"
Hotkey, %PotionHKeyOldmost%, OFF, UseErrorLevel OFF
} Else {
PotionHKeyOldmost := HClear
StatePotionHkey := "On"
Hotkey, %PotionHKeyOldest%, OFF, UseErrorLevel OFF
}
Hotkey, %PotionHkey%, Potion, UseErrorLevel ON
return
Potion:
RunWait, PotionMotion.ahk
return
BattleOneHKey:
HClear := BattleOneHkey
If (StateBattleOneHkey == "On") {
BattleOneHKeyOldest := HClear
StateBattleOneHkey := "Off"
Hotkey, %BattleOneHKeyOldmost%, OFF, UseErrorLevel OFF
} Else {
BattleOneHKeyOldmost := HClear
StateBattleOneHkey := "On"
Hotkey, %BattleOneHKeyOldest%, OFF, UseErrorLevel OFF
}
Hotkey, %BattleOneHkey%, BattleOne, UseErrorLevel ON
return
BattleOne:
RunWait, AutoBattleOne.ahk
return