-
Notifications
You must be signed in to change notification settings - Fork 0
/
Crusaders of the Lost Idols.ahk
406 lines (329 loc) · 6.33 KB
/
Crusaders of the Lost Idols.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
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
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
#SingleInstance force
; #Warn ; Enable warnings to assist with detecting common errors.
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
DetectHiddenWindows, On
global GameTitle := "Crusaders of The Lost Idols"
global CheatEngineTitle := "Cheat Engine 7.2"
#If WinActive(GameTitle)
^F1::
ce_enter_speed(1)
ce_apply_speed()
Reload
Sleep 1000 ; If successful, the reload will close this instance during the Sleep, so the line below will never be reached.
MsgBox, 4,, The script could not be reloaded. Would you like to exit?
IfMsgBox, Yes, ExitApp
Return
^1::
ce_enter_speed(1)
ce_apply_speed()
Return
^2::
ce_enter_speed(10)
ce_apply_speed()
Return
^3::
Loop 50000 {
;buff_time1()
;buff_time2()
buff_time3()
}
Return
^4::
Loop 40000 {
shopchest_select1()
shopchest_purchase()
}
Return
^F2::
Loop {
ce_set_speed(500)
ControlSend,, {Left}, %GameTitle%
Sleep 2000
ControlSend,, {Right}, %GameTitle%
Sleep 2000
ce_set_speed(25)
Loop 3 {
click_level(GameTitle)
ControlSend,, {Left}, %GameTitle%
Sleep 1000
ControlSend,, {Right}, %GameTitle%
Sleep 1000
}
}
Return
^F3::
ce_enter_speed(10)
ce_apply_speed()
ControlFocus,, %GameTitle%
SetControlDelay -1
Loop {
progress(GameTitle)
}
Return
^F4::
ControlFocus,, %GameTitle%
SetControlDelay -1
Loop {
sprint(GameTitle)
}
Return
^F5::
ControlFocus,, %GameTitle%
SetControlDelay -1
Loop {
sprint(GameTitle)
; Assign formation
ControlSend,, w, %GameTitle%
ce_enter_speed(10)
ce_apply_speed()
toggle_auto_progress(GameTitle)
Loop 550 {
progress(GameTitle)
}
toggle_auto_progress(GameTitle)
}
Return
^F6::
Loop {
Loop 50 {
click_kill(GameTitle)
}
;click_upgrade(GameTitle)
Loop 50 {
click_kill(GameTitle)
}
;click_level(GameTitle)
;toggle_auto_progress(GameTitle)
}
Return
^F7::
Loop {
ce_enter_speed(10)
ce_apply_speed()
Sleep 100
magnify()
storm_rider()
magnify()
storm_rider()
ce_enter_speed(500)
ce_apply_speed()
Sleep 8000
}
Return
^F8::
ce_enter_speed(10)
ce_apply_speed()
ControlFocus,, %GameTitle%
SetControlDelay -1
Loop {
ControlSend,, {Right}, %GameTitle%
Sleep 100
click_upgrade(GameTitle)
click_level(GameTitle)
Sleep 500
}
Return
#If
toggle_auto_progress(GameTitle) {
ControlSend,, g, %GameTitle%
}
progress(GameTitle) {
ControlSend,, {Right}, %GameTitle%
Sleep 100
click_upgrade(GameTitle)
click_level(GameTitle)
Sleep 5000
}
sprint(GameTitle) {
ce_enter_speed(1)
ce_apply_speed()
world_reset(GameTitle)
select_fp_2p(GameTitle)
ce_enter_speed(10)
ce_apply_speed()
; Hide notifications
ControlSend,, {Space}, %GameTitle%
Sleep 100
; Farm some gold
Loop 50 {
click_kill(GameTitle)
}
click_level(GameTitle)
; Get to level 4
Loop 3 {
ControlSend,, {Right}, %GameTitle%
click_upgrade(GameTitle)
click_level(GameTitle)
Sleep 5000
}
; Get ready for Sprint Mode
ce_enter_speed(1)
ce_apply_speed()
buff_spawn1()
;buff_spawn2()
;buff_spawn3()
Sleep 300
; Boss Sprint
Loop 40 {
ControlSend,, {Right}, %GameTitle%
click_level(GameTitle)
Sleep 6000
ControlSend,, {Right}, %GameTitle%
click_upgrade(GameTitle)
Sleep 6000
}
}
click_kill(GameTitle) {
ControlClick, x725 y325, %GameTitle%
Sleep 100
}
click_upgrade(GameTitle) {
ControlClick, x993 y570, %GameTitle%
Sleep 1000
}
click_level(GameTitle) {
ControlClick, x993 y652, %GameTitle%
Sleep 1300
}
select_fp_2p(GameTitle) {
; Position
Loop 4 {
scroll_down(GameTitle)
}
Sleep 400
; Select
ControlClick, x548 y378, %GameTitle%
Sleep 200
; Confirm
ControlClick, x785 y593, %GameTitle%
Sleep 3000
}
scroll_right(GameTitle) {
ControlClick, x994 y614, %GameTitle%
Sleep 100
}
scroll_down(GameTitle) {
ControlClick, x589 y636, %GameTitle%
Sleep 100
}
buff_spawn() {
ControlClick, x580 y144, Crusaders of The Lost Idols
Sleep 100
}
buff_spawn1() {
buff_spawn()
ControlClick, x670 y192, Crusaders of The Lost Idols
Sleep 100
}
buff_spawn2() {
buff_spawn()
ControlClick, x670 y231, Crusaders of The Lost Idols
Sleep 100
}
buff_spawn3() {
buff_spawn()
ControlClick, x670 y268, Crusaders of The Lost Idols
Sleep 100
}
buff_time1() {
ControlSend, , {Ctrl down}{Shift down}, Crusaders of The Lost Idols
ControlClick, x550 y195, Crusaders of The Lost Idols
Sleep 50
}
buff_time2() {
ControlSend, , {Ctrl down}{Shift down}, Crusaders of The Lost Idols
ControlClick, x550 y230, Crusaders of The Lost Idols
Sleep 50
}
buff_time3() {
ControlSend, , {Ctrl down}{Shift down}, Crusaders of The Lost Idols
ControlClick, x550 y265, Crusaders of The Lost Idols
Sleep 100
}
shopchest_select1() {
; select to buy 1 chest that would use ingame currency
ControlClick, x200 y450, Crusaders of The Lost Idols
Sleep 100
}
shopchest_purchase() {
; purchase chest
ControlClick, x350 y530, Crusaders of The Lost Idols
Sleep 1000
}
clickorama() {
ControlSend, , 1, %GameTitle%
Sleep 20
}
magnify() {
ControlSend, , 2, %GameTitle%
Sleep 20
}
fire_storm() {
ControlSend, , 3, %GameTitle%
Sleep 20
}
savage_strikes() {
ControlSend, , 4, %GameTitle%
Sleep 20
}
goldorama() {
ControlSend, , 5, %GameTitle%
Sleep 20
}
royal_command() {
ControlSend, , 6, %GameTitle%
Sleep 20
}
storm_rider() {
ControlSend, , 7, %GameTitle%
Sleep 20
}
alchemy() {
ControlSend, , 8, %GameTitle%
Sleep 20
}
world_reset(GameTitle) {
Loop 9 {
scroll_right(GameTitle)
}
Sleep 1000
click_reset(GameTitle)
}
click_reset(GameTitle) {
; Click Nate Dragon's Ability
ControlClick, x55 y680, %GameTitle% ; On mission
Sleep 10
ControlClick, x190 y682, %GameTitle% ; Not on mission
Sleep 2500
; Confirmation window
ControlClick, x435 y555, %GameTitle%
Sleep 4500
; Big Red Button
ControlClick, x518 y567, %GameTitle%
Sleep 13000
; Rewards Summary
ControlClick, x526 y583, %GameTitle%
Sleep 3000
}
ce_set_speed(speed) {
ce_enter_speed(speed)
ce_apply_speed()
}
ce_enter_speed(speed) {
ControlSetText, Edit1, %speed%, %CheatEngineTitle%
Sleep 30
}
ce_apply_speed() {
ControlClick, Button3, %CheatEngineTitle%
Sleep 30
}
ce_focus_speedbox() {
ControlFocus, Edit1, %CheatEngineTitle%
Sleep 50
}
ce_toggle_speedhack() {
ControlClick, Button4, %CheatEngineTitle%
Sleep 10
}