forked from djo5296/Tap-Titans-2-Progress-Bot
-
Notifications
You must be signed in to change notification settings - Fork 14
/
Push
753 lines (670 loc) · 12.2 KB
/
Push
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
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
// - Tap Titans 2 RandomClicker by Tune389 [ v1 ]
// edited by djo5296 '17-12-23 v2
// chrisreyn Push July 19 2018
//THIS SCRIPT HAS NO PRESTIGE, NO SKILL LEVEL UP (just activate), ONLY RECENT HERO LEVEL UP
SCREEN_SIZE: 480x800
var #startX 60
var #endX 415
var #endY 420
// ----------- Settings
var #startY 160
// use 160 if w/ faries
// use 270 if no faries
var #enableCO 1
var #PHoM 1
var #equipmentStacking 0
var #agree 1
var #decline 0
// agree = 1 if you want to auto accept fairy ads; aka skippable fairy ads
// decline = 1 if you cannot turn off fairy ads but want to click on all fairies
// you can leave both at 0 if you turn off fairy ads (change #startY if so)
// do not make both agree and decline = 1 hahaha
// ---------- Actions ---------- [ ClanQuest ]
var #enableClanQuest 1
//clan boss with max possible hits
var #clanQuestRunsPerReadyUp 1
// 1 = (default) attack every ready up once for free
// 2-99 = spend dias for more attacks
// ----------- Heroes
var #levelUpToggle 1
var #heroIntensity 2
var #startHeroLevelUpNow 0
// ----------- Skills
var #astralAwakening 1
var #skillToggle 1
var #HS 0
var #DS 1
var #HoM 1
var #FS 1
var #WC 1
var #SC 1
// ----------- Vars
var #randomX 0
var #randomY 0
var #menuY 780
var #menuSlideDelay 200
var #menuStats 15
var #menuHeroes 120
var #menuCloseY 455
var #menuCloseX 466
var #delay 20
var #btnDelay 150
var #menuPopUpDelay 500
var #skillDelay 50
var #loadingClanQuestDelay 3000
var #cqCheck 1
var #clanQuestCount 0
var #clanQuestLoopCount 0
var #recheckClanQuest 0
var #hero 0
var #hitCount 0
var #extraCount 0
var #skillCount 0
var #levelCount 0
var #pressLevelUpLoopCount 0
var #loopDetectionCount 0
var #color1 0
var #color2 0
var #colorRed 0
var #colorGreen 0
var #colorBlue 0
var #colorGray 2695200
var #colorStatsButton 3695603
if #startHeroLevelUpNow == 1
#hitCount = 1199
endif
// ----------- RANDOM ATTACK
:start
rand #randomX #startX #endX
rand #randomY #startY #endY
//equipment stacking
if #randomX > 310 and #randomX < 415 and #randomY > 290 and #equipmentStacking == 1
goto :start
endif
//prevent hero story window
if #randomY > 184 and #randomY < 233 and #randomX > 403
goto :randomTouch
endif
touchDown 0 #randomX #randomY
touchUp 0
sleep #delay
if #astralAwakening == 1
#hero = #hero + 1
if #equipmentStacking == 1
if #hero == 1 or #hero == 6
#hero = #hero + 1
endif
endif
if #hero == 1
//Maya
touchDown 0 350 400
touchUp 0
elseif #hero == 2
//Zato
touchDown 0 135 400
touchUp 0
elseif #hero == 3
//Sophia
touchDown 0 435 390
touchUp 0
elseif #hero == 4
//Lance
touchDown 0 100 395
touchUp 0
elseif #hero == 5
//Pingo
touchDown 0 100 315
touchUp 0
elseif #hero == 6
//Rosabella
touchDown 0 400 305
touchUp 0
elseif #hero == 7
//Gulbrand
touchDown 0 55 275
touchUp 0
elseif #hero == 8
//Captain Davey
touchDown 0 455 305
touchUp 0
elseif #hero == 9
//Rhys
touchDown 0 35 305
touchUp 0
elseif #hero == 10
//Kronus
touchDown 0 50 375
touchUp 0
endif
endif
goto :randomTouchB
:randomTouchB
if #astralAwakening == 1
if #equipmentStacking == 1
if #hero == 11 or #hero == 19
#hero = #hero + 1
endif
endif
if #hero == 11
//Cosette
touchDown 0 400 400
touchUp 0
elseif #hero == 12
//Kiki
touchDown 0 10 305
touchUp 0
elseif #hero == 13
//Maddie
touchDown 0 75 410
touchUp 0
elseif #hero == 14
//Beany
touchDown 0 425 305
touchUp 0
elseif #hero == 15
//Sawyer
touchDown 0 400 225
touchUp 0
elseif #hero == 16
//Lil' Ursa
touchDown 0 465 410
touchUp 0
elseif #hero == 17
//Saje
touchDown 0 20 380
touchUp 0
elseif #hero == 18
//Wally
touchDown 0 15 210
touchUp 0
elseif #hero == 19
//Jayce
touchDown 0 380 365
touchUp 0
elseif #hero == 20
//Great Pharaoh
touchDown 0 445 205
touchUp 0
endif
endif
goto :randomTouchC
:randomTouchC
if #astralAwakening == 1
if #equipmentStacking == 1
if #hero == 22
#hero = #hero + 1
endif
endif
if #hero == 21
//Boomoh Doctor
touchDown 0 50 225
touchUp 0
elseif #hero == 22
//Dex-1000
touchDown 0 375 305
touchUp 0
elseif #hero == 23
//Great Madame Cass
touchDown 0 470 225
touchUp 0
elseif #hero == 24
//Lala
touchDown 0 80 225
touchUp 0
elseif #hero == 25
//Aya
touchDown 0 75 305
touchUp 0
elseif #hero == 26
//Lady Lucy
touchDown 0 445 170
touchUp 0
elseif #hero == 27
//Jazz
touchDown 0 415 170
touchUp 0
elseif #hero == 28
//Maple
touchDown 0 370 170
touchUp 0
elseif #hero == 29
//Kin
touchDown 0 95 190
touchUp 0
elseif #hero == 30
//Princess Titania
touchDown 0 25 175
touchUp 0
endif
endif
goto :randomTouchD
:randomTouchD
if #astralAwakening == 1
if #hero == 31
//Miki
touchDown 0 425 225
touchUp 0
elseif #hero == 32
//Mina
touchDown 0 465 120
touchUp 0
elseif #hero == 33
//Yzafa
touchDown 0 385 135
touchUp 0
elseif #hero == 34
//Zolom
touchDown 0 60 170
touchUp 0
elseif #hero == 35
//Finn
touchDown 0 465 125
touchUp 0
elseif #hero == 36
//Nohni
touchDown 0 120 145
touchUp 0
elseif #hero == 37
//Damon
touchDown 0 420 80
touchUp 0
endif
sleep #hitDelay2
if #hero > 36
#hero = 0
endif
endif
#hitCount = #hitCount + 1
#extraCount = #hitCount % 12
#skillCount = #hitCount % 72
#levelCount = #hitCount % 1000
if #levelCount == 0
#hitCount = 0
goto :levelUp
endif
if #skillCount == 0
goto :skills
endif
if #extraCount == 0
goto :extra
endif
goto :start
:extra
if #PHoM == 1
touchDown 0 270 370
sleep 12
touchUp 0
sleep 14
touchPress 0 270 370
sleep 2
touchUp
sleep 3
touchPress 0 270 370
sleep 16
touchUp 0
sleep 18
touchDown 0 270 370
sleep 10
touchUp 0
sleep 18
endif
if #enableCO == 1
touchPress 0 175 410
sleep #delay
touchPress 0 175 410
sleep #delay
sleep #shipDelay
if #agree == 1
touchDown 0 300 630
sleep 30
touchUp 0
sleep 30
touchDown 0 300 630
sleep 30
touchUp 0
sleep 30
endif
if #decline == 1
touchDown 0 200 630
sleep 30
touchUp 0
sleep 30
touchDown 0 200 630
sleep 30
touchUp 0
sleep 30
endif
goto :start
:skills
if #skillToggle == 0
goto :extra
endif
if #SC == 1
touchPress 0 430 710
sleep #skillDelay
touchPress 0 430 710
sleep #skillDelay
endif
if #HoM == 1
touchPress 0 200 710
sleep #skillDelay
endif
if #DS == 1
touchPress 0 120 710
sleep #skillDelay
endif
if #WC == 1
touchPress 0 360 710
sleep #skillDelay
endif
if #FS == 1
touchPress 0 280 710
sleep #skillDelay
endif
if #HS == 1
touchPress 0 40 710
sleep #skillDelay
endif
goto :extra
:levelUp
#hitCount = 0
if #enableClanQuest == 1 and #cqCheck == 1
#cqCheck = 0
goto :checkClanQuest
endif
#cqCheck = 1
//click "Fight Boss"
getColor #color1 372 24
if #color1 == 1076975
toast FightBoss1
touchPress 0 390 36
sleep 40
touchUp
sleep 40
goto :pressSkills
endif
if #levelUpToggle == 0
goto :skills
endif
if #agree == 1
sleep 3000
touchPress 300 630
sleep #btnDelay
touchPress 300 630
sleep #btnDelay
touchPress 300 630
sleep #btnDelay
endif
if #decline == 1
sleep 3000
touchPress 200 630
sleep #btnDelay
touchPress 200 630
sleep #btnDelay
touchPress 200 630
sleep #btnDelay
endif
//open stats
sleep #btnDelay
touchDown 0 #menuHeroes #menuY
sleep #btnDelay
touchUp 0
sleep 1000
//wait for slide
sleep #menuSlideDelay
//slide top
touchDown 0 280 650
sleep 200
touchMove 0 280 600
sleep 50
touchMove 0 280 700
sleep 50
touchMove 0 280 750
sleep 50
touchMove 0 280 780
sleep 50
touchUp 0
sleep 750
sleep #btnDelay
//slide top
touchDown 0 280 650
sleep 200
touchMove 0 280 600
sleep 50
touchMove 0 280 700
sleep 50
touchMove 0 280 750
sleep 50
touchMove 0 280 780
sleep 50
touchUp 0
sleep 750
sleep #btnDelay
//slide top
touchDown 0 280 650
sleep 200
touchMove 0 280 600
sleep 50
touchMove 0 280 700
sleep 50
touchMove 0 280 750
sleep 50
touchMove 0 280 780
sleep 50
touchUp 0
sleep 750
sleep #btnDelay
touchPress 0 460 670
sleep #btnDelay
touchPress 0 460 670
sleep #btnDelay
touchPress 0 460 670
sleep #btnDelay
touchPress 0 460 670
sleep #btnDelay
//slide down
touchDown 1 280 740
sleep 200
touchMove 1 280 710
sleep 50
touchMove 1 280 500
sleep 50
touchMove 1 280 410
sleep 50
touchMove 1 280 400
touchUp 1
sleep 300
goto :levelHeroesPressLevelUp
:levelHeroesPressLevelUp
#pressLevelUpLoopCount = #pressLevelUpLoopCount + 1
touchDown 1 466 720
sleep 40
touchUp 1
sleep 40
touchDown 1 466 700
sleep 40
touchUp 1
sleep 40
touchDown 1 466 680
sleep 40
touchUp 1
sleep 40
touchDown 1 466 660
sleep 40
touchUp 1
sleep 40
touchDown 1 466 640
sleep 40
touchUp 1
sleep 40
touchDown 1 466 620
sleep 40
touchUp 1
sleep 40
touchDown 1 466 600
sleep 40
touchUp 1
sleep 40
touchDown 1 466 580
sleep 40
touchUp 1
sleep 40
touchDown 1 466 560
sleep 40
touchUp 1
sleep 40
touchDown 1 466 540
sleep 40
touchUp 1
sleep 40
if #pressLevelUpLoopCount < #heroIntensity
goto :levelHeroesPressLevelUp
endif
#pressLevelUpLoopCount = 0
goto :levelHeroesSlideUpCollection
:levelHeroesSlideUpCollection
#loopDetectionCount = #loopDetectionCount + 1
if #loopDetectionCount > 7
#loopDetectionCount = 0
toast levelHeroesSlideUpCollection loop
goto :closeMenu
endif
touchDown 1 280 510
sleep 20
touchMove 1 280 512
touchMove 1 280 514
touchMove 1 280 516
sleep 20
touchMove 1 280 520
touchMove 1 280 540
sleep 20
touchMove 1 280 580
touchMove 1 280 600
sleep 20
touchMove 1 280 630
touchMove 1 280 670
sleep 20
touchMove 1 280 690
touchMove 1 280 700
sleep 20
touchMove 1 280 736
touchMove 1 280 738
sleep 20
touchMove 1 280 740
touchMove 1 280 742
sleep 200
touchUp 1
touchPress 1 280 750
getColor #color1 275 527
getColor #color2 275 508
if #color1 == #colorGray and #color2 == #colorGray
#loopDetectionCount = 0
goto :closeMenu
endif
goto :levelHeroesPressLevelUp
:closeMenu
//close stats
sleep #btnDelay
touchPress 0 #menuCloseX #menuCloseY
touchPress 0 #menuCloseX #menuCloseY
touchPress 0 #menuCloseX #menuCloseY
sleep #menuSlideDelay
goto :skills
// ---------- CHECK CLAN QUEST
:checkClanQuest
sleep 300
getRGB #colorRed #colorGreen #colorBlue 72 21
getColor #color1 65 795
if #colorRed < 190 and #colorRed > 120 and #color1 == #colorStatsButton
#recheckClanQuest = 1
goto :checkClanQuestReady
endif
goto :levelUp
:checkClanQuestReady
//open CQ menu
sleep #btnDelay
touchDown 0 80 25
sleep #btnDelay
touchUp 0
sleep #btnDelay
sleep 250
sleep 250
//touch clan icon bottom
touchDown 0 100 730
sleep #btnDelay
touchUp 0
sleep #loadingClanQuestDelay
getColor #color1 420 725
//420 730
if #color1 == -1785765 and #clanQuestCount == 0
#recheckClanQuest = 0
goto :clanQuestClose
endif
//boss progress color
getColor #color1 175 335
#clanQuestLoopCount = 0
if #color1 == 2055160
//boss up
touchDown 0 310 740
sleep #btnDelay
touchUp 0
sleep #menuPopUpDelay
goto :clanQuestCheckDias
elseif #color1 == 0
//boss down
#recheckClanQuest = 0
endif
//close (and recheck)
goto :clanQuestClose
:clanQuestCheckDias
getColor #color1 40 215
if #color1 == -7775689
//no dias left
#recheckClanQuest = 0
goto :clanQuestClose
else
touchDown 0 325 450
//330 450
sleep #btnDelay
touchUp 0
sleep 3000
getColor #color1 20 770
goto :clanQuestHit
endif
:clanQuestHit
if #color1 == -28929 and #clanQuestLoopCount == 0
//add quest
#clanQuestCount = #clanQuestCount + 1
endif
#clanQuestLoopCount = #clanQuestLoopCount + 1
if #color1 == -28929 and #clanQuestLoopCount < 1000
//hit the boss
touchDown 0 180 730
touchUp 0
sleep 28
goto :clanQuestHit
elseif #clanQuestLoopCount > 950
goto :clanQuestClose
endif
:clanQuestClose
getColor #color1 65 788
if #color1 == #colorStatsButton
goto :clanQuestCloseCheck
else
touchDown 0 415 45
sleep 35
touchUp 0
sleep 200
touchDown 0 420 210
sleep 35
touchUp 0
sleep 200
goto :clanQuestClose
endif
:clanQuestCloseCheck
if #recheckClanQuest == 1 and #clanQuestCount < #clanQuestRunsPerReadyUp
goto :checkClanQuestReady
else
#clanQuestCount = 0
goto :levelUp
endif