-
Notifications
You must be signed in to change notification settings - Fork 11
/
Data.lua
executable file
·16309 lines (16191 loc) · 432 KB
/
Data.lua
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
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
---@type string
local AddonName = ...
---@class Data
local Data = select(2, ...)
local L = Data.L
local DRList = LibStub("DRList-1.0")
local table_insert = table.insert
local GetClassInfo = GetClassInfo
local GetNumSpecializationsForClassID = GetNumSpecializationsForClassID
local GetSpecializationInfoForClassID = GetSpecializationInfoForClassID
local GetSpellInfo = GetSpellInfo
local GetSpellName = C_Spell and C_Spell.GetSpellName or GetSpellName
local C_Spell = C_Spell
local GetSpellTexture = C_Spell and C_Spell.GetSpellTexture or GetSpellTexture
local IsRetail = WOW_PROJECT_ID == WOW_PROJECT_MAINLINE
local IsClassic = WOW_PROJECT_ID == WOW_PROJECT_CLASSIC
local IsTBCC = WOW_PROJECT_ID == WOW_PROJECT_BURNING_CRUSADE_CLASSIC
local IsWrath = WOW_PROJECT_ID == WOW_PROJECT_WRATH_CLASSIC
Data.PlayerRoles = {"TANK", "HEALER", "DAMAGER"}
Data.CyrillicToRomanian = { -- source Wikipedia: https://en.wikipedia.org/wiki/Romanization_of_Russian
["А"] = "a",
["а"] = "a",
["Б"] = "b",
["б"] = "b",
["В"] = "v",
["в"] = "v",
["Г"] = "g",
["г"] = "g",
["Д"] = "d",
["д"] = "d",
["Е"] = "e",
["е"] = "e",
["Ё"] = "e",
["ё"] = "e",
["Ж"] = "zh",
["ж"] = "zh",
["З"] = "z",
["з"] = "z",
["И"] = "i",
["и"] = "i",
["Й"] = "i",
["й"] = "i",
["К"] = "k",
["к"] = "k",
["Л"] = "l",
["л"] = "l",
["М"] = "m",
["м"] = "m",
["Н"] = "n",
["н"] = "n",
["О"] = "o",
["о"] = "o",
["П"] = "p",
["п"] = "p",
["Р"] = "r",
["р"] = "r",
["С"] = "s",
["с"] = "s",
["Т"] = "t",
["т"] = "t",
["У"] = "u",
["у"] = "u",
["Ф"] = "f",
["ф"] = "f",
["Х"] = "kh",
["х"] = "kh",
["Ц"] = "ts",
["ц"] = "ts",
["Ч"] = "ch",
["ч"] = "ch",
["Ш"] = "sh",
["ш"] = "sh",
["Щ"] = "shch",
["щ"] = "shch",
["Ъ"] = "ie",
["ъ"] = "ie",
["Ы"] = "y",
["ы"] = "y",
["Ь"] = "",
["ь"] = "",
["Э"] = "e",
["э"] = "e",
["Ю"] = "iu",
["ю"] = "iu",
["Я"] = "ia",
["я"] = "ia"
}
Data.Buttons = {
Target = TARGET,
Focus = SET_FOCUS,
Custom = L.UserDefined
}
Data.ObjectiveAndRespawnPosition = {
Left = L.LEFT,
Right = L.RIGHT,
LeftToTargetCounter = L.LeftToTargetCounter
}
Data.DisplayType = {
Frame = L.Frame,
Countdowntext = L.Countdowntext,
}
-- Data.DrCategorys = {
-- disorient = L.DR_Disorient,
-- incapacitate = L.DR_Incapacitate,
-- knockback = L.DR_Knockback,
-- silence = L.DR_Silence,
-- stun = L.DR_Stun
-- }
Data.DebuffTypes = {
HELPFUL = {
Magic = L.Magic,
},
HARMFUL = {
Magic = L.Magic,
Disease = L.Disease,
Poison = L.Poison,
Curse = L.Curse
}
}
Data.RandomDebuffType = {} -- for testmode
do
local i = 1
for engName, color in pairs(DebuffTypeColor) do
Data.RandomDebuffType[i] = engName
i = i + 1
end
end
Data.AllPositions = {
TOPLEFT = L.TOPLEFT,
TOP = L.TOP,
TOPRIGHT = L.TOPRIGHT,
LEFT = L.LEFT,
CENTER = L.CENTER,
RIGHT = L.RIGHT,
BOTTOMLEFT = L.BOTTOMLEFT,
BOTTOM = L.BOTTOM,
BOTTOMRIGHT = L.BOTTOMRIGHT
}
Data.BasicPositions = {
LEFT = L.LEFT,
RIGHT = L.RIGHT
}
Data.HorizontalDirections = {
leftwards = L.Leftwards,
rightwards = L.Rightwards
}
Data.VerticalDirections = {
upwards = L.Upwards,
downwards = L.Downwards
}
Data.Interruptdurations = {
[6552] = 4, -- [Warrior] Pummel
[96231] = 4, -- [Paladin] Rebuke
[231665]= 3, -- [Paladin] Avengers Shield
[147362]= 3, -- [Hunter] Countershot
[187707]= 3, -- [Hunter] Muzzle
[1766] = 5, -- [Rogue] Kick
[183752]= 3, -- [DH] Consume Magic, Disrupt since 8.0.1
[47528] = 3, -- [DK] Mind Freeze
[91802] = 2, -- [DK] Shambling Rush
[57994] = 3, -- [Shaman] Wind Shear
[115781]= 6, -- [Warlock] Optical Blast
[19647] = 6, -- [Warlock] Spell Lock
[212619]= 6, -- [Warlock] Call Felhunter
[132409]= 6, -- [Warlock] Spell Lock
[171138]= 6, -- [Warlock] Shadow Lock
[2139] = 6, -- [Mage] Counterspell
[116705]= 4, -- [Monk] Spear Hand Strike
[106839]= 4, -- [Feral] Skull Bash
[93985] = 4, -- [Feral] Skull Bash
[351338]= 4 -- [Evoker] Quell
}
-- for spellId, lockoutDuration in pairs(Data.Interruptdurations) do
-- Data.SpellPriorities[spellId] = 4
-- end
Data.RandomDrCategory = {} --key = number, value = categorieName, used for Testmode
Data.DrCategoryToSpell = {} --key = categorieName, value = table with key = number and value = spellId
Data.SpellPriorities = {}
local i = 1
for categorieName, localizedCategoryName in pairs(DRList:GetCategories()) do
Data.RandomDrCategory[i] = categorieName
Data.DrCategoryToSpell[categorieName] = {}
i = i + 1
end
do
local drCategoryToPriority = {
stun = 8,
disorient = 7,
incapacitate = 6,
silence = 5,
knockback = 2,
taunt = 1
}
-- no more needed since classic supports spellIDs now
-- if IsClassic then
-- for spellName, spellData in pairs(DRList.spells) do
-- local category = spellData.category
-- table_insert(Data.DrCategoryToSpell[category], spellName)
-- Data.SpellPriorities[spellName] = drCategoryToPriority[category]
-- end
-- else
-- for spellId, categorieName in pairs(DRList.spells) do
-- table_insert(Data.DrCategoryToSpell[categorieName], spellId)
-- Data.SpellPriorities[spellId] = drCategoryToPriority[categorieName]
-- end
-- end
for spellId, categorieName in pairs(DRList.spells) do
if type(categorieName) == "table" then
for k, categorie in pairs(categorieName) do
table_insert(Data.DrCategoryToSpell[categorie], spellId)
end
else
table_insert(Data.DrCategoryToSpell[categorieName], spellId)
end
Data.SpellPriorities[spellId] = drCategoryToPriority[categorieName]
end
end
Data.cCduration = { -- this is basically data from DRList-1 with durations, used for Relentless check
--[[ INCAPACITATES ]]--
incapacitate = {
-- Druid
[ 99] = 3, -- Incapacitating Roar (talent)
[236025] = 6, -- Main (Honor talent)
[236026] = 6, -- Main (Honor talent)
-- Hunter
[213691] = 4, -- Scatter Shot
-- Mage
[ 118] = 8, -- Polymorph
[ 28272] = 8, -- Polymorph (pig)
[ 28271] = 8, -- Polymorph (turtle)
[ 61305] = 8, -- Polymorph (black cat)
[277792] = 8, -- Polymorph (Bumblebee)
[277787] = 8, -- Polymorph (Direhorn)
[ 61721] = 8, -- Polymorph (rabbit)
[ 61780] = 8, -- Polymorph (turkey)
[126819] = 8, -- Polymorph (procupine)
[161353] = 8, -- Polymorph (bear cub)
[161354] = 8, -- Polymorph (monkey)
[321395] = 8, -- Polymorph (Mawrat)
[161355] = 8, -- Polymorph (penguin)
[161372] = 8, -- Polymorph (peacock)
[ 82691] = 8, -- Ring of Frost
-- Monk
[115078] = 4, -- Paralysis
-- Paladin
[ 20066] = 8, -- Repentance
-- Priest
[ 64044] = 4, -- Psychic Horror (Horror effect)
-- Rogue
[ 1776] = 4, -- Gouge
[ 6770] = 8, -- Sap
-- Shaman
[ 51514] = 8, -- Hex
[211004] = 8, -- Hex (spider)
[210873] = 8, -- Hex (raptor)
[211015] = 8, -- Hex (cockroach)
[211010] = 8, -- Hex (snake)
-- Warlock
[ 6789] = 3, -- Mortal Coil
-- Pandaren
[107079] = 4 -- Quaking Palm
},
--[[ SILENCES ]]--
silence = {
-- Death Knight
[ 47476] = 5, -- Strangulate
-- Hunter
[202933] = 4, -- Spider Sting (pvp talent)
-- Mage
-- Paladin
[ 31935] = 3, -- Avenger's Shield
-- Priest
[ 15487] = 4, -- Silence
-- Rogue
[ 1330] = 3, -- Garrote
-- Blood Elf
[ 25046] = 2, -- Arcane Torrent (Energy version)
[ 28730] = 2, -- Arcane Torrent (Priest/Mage/Lock version)
[ 50613] = 2, -- Arcane Torrent (Runic power version)
[ 69179] = 2, -- Arcane Torrent (Rage version)
[ 80483] = 2, -- Arcane Torrent (Focus version)
[129597] = 2, -- Arcane Torrent (Monk version)
[155145] = 2, -- Arcane Torrent (Paladin version)
[202719] = 2 -- Arcane Torrent (DH version)
},
--[[ DISORIENTS ]]--
disorient = {
-- Druid
[ 33786] = 6, -- Cyclone
-- Mage
[ 31661] = 3, -- Dragon's Breath
-- Paladin
[105421] = 6, -- Blinding Light -- FIXME: is this the right category? Its missing from blizzard's list
-- Priest
[ 8122] = 6, -- Psychic Scream
-- Rogue
[ 2094] = 8, -- Blind
-- Warlock
[ 5782] = 6, -- Fear -- probably unused
[118699] = 6, -- Fear -- new debuff ID since MoP
-- Warrior
[ 5246] = 5 -- Intimidating Shout (main target)
},
--[[ STUNS ]]--
stun = {
-- Death Knight
[108194] = 4, -- Asphyxiate (talent for unholy)
[221562] = 5, -- Asphyxiate (baseline for blood)
[207171] = 4, -- Winter is Coming (Remorseless winter stun)
-- Demon Hunter
[179057] = 2, -- Chaos Nova
[200166] = 3, -- Metamorphosis
[205630] = 3, -- Illidan's Grasp, primary effect
[211881] = 4, -- Fel Eruption
-- Druid
[ 5211] = 4, -- Mighty Bash
[163505] = 4, -- Rake (Stun from Prowl)
-- Monk
[120086] = 4, -- Fists of Fury (with Heavy-Handed Strikes, pvp talent)
[232055] = 3, -- Fists of Fury (new ID in 7.1)
[119381] = 3, -- Leg Sweep
-- Paladin
[ 853] = 6, -- Hammer of Justice
-- Priest
[200200] = 4, -- Holy word: Chastise
[226943] = 6, -- Mind Bomb
-- Rogue
[ 1833] = 4, -- Cheap Shot
-- [ 408] = true, -- Kidney Shot, variable duration
--[199804] = true, -- Between the Eyes, variable duration
-- Shaman
[118345] = 4, -- Pulverize (Primal Earth Elemental)
[118905] = 5, -- Static Charge (Capacitor Totem)
[204399] = 2, -- Earthfury (pvp talent)
-- Warlock
[ 89766] = 4, -- Axe Toss (Felguard)
[ 30283] = 3, -- Shadowfury
-- Warrior
[132168] = 2, -- Shockwave
[132169] = 4, -- Storm Bolt
-- Tauren
[ 20549] = 2 -- War Stomp
}
}
Data.cCdurationBySpellID = {}
for category, spellIDs in pairs(Data.cCduration) do
Mixin(Data.cCdurationBySpellID, spellIDs)
end
Data.PriorityAuras = {
HELPFUL = {
--Death Knight
[145629] = 5.0, -- Anti-Magic Zone
[48792] = 5, -- Icebound Fortitude
[81256] = 5, -- Dancing Rune Weapon
[55233] = 5, -- Vampiric Blood
[194679] = 5, -- Rune Tap
[194844] = 5.1, -- Bonestorm
[219809] = 5.1, -- Tombstone
--Demon Hunter
[187827] = 5.1, -- Metamorphosis - Vengeance
[205629] = 5.1, -- Demonic Trample
[209426] = 5.1, -- Darkness
[212800] = 5.1, -- Blur
[196555] = 5.1, -- Netherwalk
[206803] = 5.2, -- Rain from Above (up)
--Druid
[22812] = 5.1, -- Barkskin
[22842] = 5.1, -- Frenzied Regeneration
[61336] = 5.1, -- Survival Instincts
[102342] = 5.1, -- Ironbark
[155835] = 5.1, -- Bristling Fur
[305497] = 5.1, -- Thorns (PvP Talent)
[50334] = 5.1, -- Berserk (Guardian)
[247563] = 5.1, -- Nature's Grasp (Resto Entangling Bark PvP Talent)
[327037] = 5.1, -- Kindred Protection (Kyrian Ability)
[362486] = 5.2, -- Keeper of the Grove
[186265] = 5.2, -- Aspect of the Turtle
--Hunter
[136] = 5.1, -- Mend Pet
[5384] = 5.1, -- Feign Death
[53480] = 5.1, -- Roar of Sacrifice (PvP Talent)
[54216] = 5.1, -- Master's Call
[209997] = 5.1, -- Play Dead
[202748] = 5.1, -- Survival Tactics (PvP Talent)
[248519] = 5.2, -- Interlope (BM PvP Talent)
--Mage
[342246] = 5.1, -- Alter Time (Arcane)
[110909] = 5.1, -- Alter Time (Fire/Frost)
[198111] = 5.1, -- Temporal Shield (Arcane PvP Talent)
[198065] = 5.1, -- Prismatic Cloak (PvP Talent)
[45438] = 5.2, -- Ice Block
--Monk
[115176] = 5.1, -- Zen Meditation
[120954] = 5.1, -- Fortifying Brew (Brewmaster)
[243435] = 5.1, -- Fortifying Brew (Windwalker/Mistweaver)
[337294] = 5.1, -- Roll Out (Legendary)
[116849] = 5.1, -- Life Cocoon
[122278] = 5.1, -- Dampen Harm
[125174] = 5.1, -- Touch of Karma (Buff)
[122783] = 5.1, -- Diffuse Magic
[202162] = 5.1, -- Avert Harm (Brew PvP Talent)
[209584] = 5.1, -- Zen Focus Tea (MW PvP Talent)
[343249] = 5.1, -- Escape from Reality (MW Monk Legendary)
[213664] = 5.1, -- Nimble Brew (Brew PvP Talent)
[132578] = 5.1, -- Invoke Niuzao, the Black Ox
[202248] = 5.2, -- Guided Meditation (Brew PvP Talent)
[353319] = 5.2, -- Peaceweaver
--Paladin
[498] = 5.1, -- Divine Protection
[1022] = 5.1, -- Blessing of Protection
[204018] = 5.1, -- Blessing of Spellwarding
[1044] = 5.1, -- Blessing of Freedom
[305395] = 5.1, -- Blessing of Freedom with Unbound Freedom (PvP Talent)
[6940] = 5.1, -- Blessing of Sacrifice
[199448] = 5.1, -- Blessing of Sacrifice (Ultimate Sacrifice Holy PvP Talent)
[199450] = 5.1, -- Ultimate Sacrifice (Holy PvP Talent) - debuff on the paladin
[31821] = 5.1, -- Aura Mastery
[31850] = 5.1, -- Ardent Defender
[86659] = 5.1, -- Guardian of Ancient Kings
[212641] = 5.1, -- Guardian of Ancient Kings (Glyphed)
[184662] = 5.1, -- Shield of Vengeance
[199545] = 5.1, -- Steed of Glory (Protection PvP Talent)
[205191] = 5.1, -- Eye for an Eye
[210256] = 5.1, -- Blessing of Sanctuary (Ret PvP Talent)
[210294] = 5.1, -- Divine Favor (Holy PvP Talent)
[157128] = 5.1, -- Saved by the Light
[642] = 5.2, -- Divine Shield
[228050] = 5.2, -- Guardian of the Forgotten Queen (Protection PvP Talent)
--Priest
[337661] = 5.1, -- Translucent Image (Fade defensive Conduit)
[33206] = 5.1, -- Pain Suppression
[47536] = 5.1, -- Rapture
[109964] = 5.1, -- Spirit Shell
[47585] = 5.1, -- Dispersion
[47788] = 5.1, -- Guardian Spirit
[64843] = 5.1, -- Divine Hymn
[81782] = 5.1, -- Power Word: Barrier
[232707] = 5.1, -- Ray of Hope (Holy PvP Talent)
[197862] = 5.1, -- Archangel (Disc PvP Talent)
[200183] = 5.1, -- Apotheosis
[213610] = 5.1, -- Holy Ward
--[27827] = 5.1, -- Spirit of Redemption
[215769] = 5.1, -- Spirit of Redemption (Spirit of the Redeemer Holy PvP Talent)
[211336] = 5.1, -- Archbishop Benedictus' Restitution (Resurrection Buff)
[211319] = 5.1, -- Archbishop Benedictus' Restitution (Debuff)
[289655] = 5.1, -- Holy Word: Concentration
[329543] = 5.1, -- Divine Ascension (down)
[15286] = 5.1, -- Vampiric Embrace
[19236] = 5.1, -- Desperate Prayer
[213602] = 5.2, -- Greater Fade (Holy/Shadow PvP Talent)
[328530] = 5.2, -- Divine Ascension (up)
--Rogue
[1966] = 5.1, -- Feint
[5277] = 5.1, -- Evasion
[11327] = 5.1, -- Vanish
[45182] = 5.1, -- Cheating Death
[199027] = 5.1, -- Veil of Midnight (Subtlety PvP Talent)
[197003] = 5.1, -- Maneuverability (PvP Talent)
--Shaman
[108281] = 5.1, -- Ancestral Guidance
[325174] = 5.1, -- Spirit Link Totem
[204293] = 5.1, -- Spirit Link (PvP Talent)
[108271] = 5.1, -- Astral Shift
[210918] = 5.1, -- Ethereal Form (Enhancement PvP Talent)
[114052] = 5.1, -- Ascendance (Restoration)
[118337] = 5.1, -- Harden Skin
[201633] = 5.1, -- Earthen Wall Totem
[260881] = 5.1, -- Spirit Wolf
[290641] = 5.1, -- Ancestral Gift
[207495] = 5.1, -- Ancestral Protection (Totem)
[207498] = 5.1, -- Ancestral Protection (Player)
[104773] = 5.1, -- Unending Resolve
[108416] = 5.1, -- Dark Pact
[221705] = 5.1, -- Casting Circle (PvP Talent)
[333889] = 5.1, -- Fel Domination
[8178] = 5.2, -- Grounding Totem Effect (PvP Talent)
--Warrior
[871] = 5.1, -- Shield Wall
[12975] = 5.1, -- Last Stand
[97463] = 5.1, -- Rallying Cry
[118038] = 5.1, -- Die by the Sword
[147833] = 5.1, -- Intervene
[184364] = 5.1, -- Enraged Regeneration
[197690] = 5.1, -- Defensive Stance
[213871] = 5.1, -- Bodyguard (Prot PvP Talent)
[236321] = 5.1, -- War Banner (PvP Talent)
[227847] = 5.2, -- Bladestorm (Arms)
[46924] = 5.2, -- Bladestorm (Fury)
[23920] = 5.2, -- Spell Reflection
[330279] = 5.2, -- Overwatch (PvP Talent)
[335255] = 5.2, -- Spell Reflection (Misshapen Mirror Legendary)
--Death Knight
[51271] = 4.9, -- Pillar of Frost
[63560] = 4.9, -- Dark Transformation
[152279] = 4.9, -- Breath of Sindragosa
[47568] = 4.9, -- Empower Rune Weapon
[207289] = 4.9, -- Unholy Assault
[321995] = 4.9, -- Hypothermic Presence
[315443] = 4.9, -- Abomination Limb (Necrolord Ability)
[311648] = 4.9, -- Swarming Mist (Venthyr Ability)
[48707] = 5.2, -- Anti-Magic Shell
--Demon Hunter
[162264] = 4.9, -- Metamorphosis - Havoc
[188501] = 4.9, -- Spectral Sight
[206804] = 4.9, -- Rain from Above (down)
[337567] = 4.9, -- Chaotic Blades (Chaos Theory Legendary)
--Druid [5217] = 4.9 , -- Tiger's Fury
[29166] = 4.9, -- Innervate
[33891] = 4.9, -- Incarnation: Tree of Life (for the menu entry - "Incarnation" tooltip isn't informative)
[117679] = 4.9, -- Incarnation (grants access to Tree of Life form)
[102543] = 4.9, -- Incarnation: King of the Jungle
[102558] = 4.9, -- Incarnation: Guardian of Ursoc
[102560] = 4.9, -- Incarnation: Chosen of Elune
[106951] = 4.9, -- Berserk (Feral)
[132158] = 4.9, -- Nature's Swiftness
[194223] = 4.9, -- Celestial Alignment
[202425] = 4.9, -- Warrior of Elune
[319454] = 4.9, -- Heart of the Wild
[108291] = 4.9, -- with Balance Affinity
[108292] = 4.9, -- with Feral Affinity
[108293] = 4.9, -- with Guardian Affinity
[108294] = 4.9, -- with Resto Affinity
[323764] = 4.9, -- Convoke the Spirits (Night Fae Ability)
[323546] = 4.9, -- Ravenous Frenzy (Venthyr Ability)
[338142] = 4.9, -- Lone Empowerment (Kyrian Ability)
--Hunter [19574] = 4.9 , -- Bestial Wrath
[186254] = 4.9, -- Bestial Wrath buff on the pet
[186289] = 4.9, -- Aspect of the Eagle
[193530] = 4.9, -- Aspect of the Wild
[260402] = 4.9, -- Double Tap
[266779] = 4.9, -- Coordinated Assault
[288613] = 4.9, -- Trueshot
--Mage [66] = 4.9 , -- Invisibility (Countdown)
[32612] = 4.9, -- Invisibility
[113862] = 4.9, -- Greater Invisibility
[12042] = 4.9, -- Arcane Power
[12051] = 4.9, -- Evocation
[12472] = 4.9, -- Icy Veins
[198144] = 4.9, -- Ice Form
[342242] = 4.9, -- Time Warp procced by Time Anomality (Arcane Talent)
[190319] = 4.9, -- Combustion
[198158] = 4.9, -- Mass Invisibility (Arcane PvP Talent)
[205025] = 4.9, -- Presence of Mind
[333100] = 4.9, -- Firestorm (Fire Legendary)
[324220] = 4.9, -- Deathborne (Necrolord Ability)
--Monk [137639] = 4.9 , -- Storm, Earth, and Fire
[152173] = 4.9, -- Serenity
[310454] = 4.9, -- Weapons of Order (Kyrian Ability)
[202335] = 4.9, -- Double Barrel (Brew PvP Talent) - "next cast will..." buff
--Paladin [31884] = 4.9 }, -- Avenging Wrath
[216331] = 4.9, -- Avenging Crusader (Holy Talent)
[231895] = 4.9, -- Crusade (Retribution Talent)
[105809] = 4.9, -- Holy Avenger
[152262] = 4.9, -- Seraphim
[215652] = 4.9, -- Shield of Virtue (Protection PvP Talent) - "next cast will..." buff
--Priest [10060] = 4.9 , -- Power Infusion
[194249] = 4.9, -- Voidform
[197871] = 4.9, -- Dark Archangel (Disc PvP Talent) - on the priest
[197874] = 4.9, -- Dark Archangel (Disc PvP Talent) - on others
[319952] = 4.9, -- Surrender to Madness
[322431] = 4.9, -- Thoughtsteal (Buff)
[325013] = 4.9, -- Boon of the Ascended (Kyrian)
--Rogue [13750] = 4.9 , -- Adrenaline Rush
[51690] = 4.9, -- Killing Spree
[121471] = 4.9, -- Shadow Blades
[185422] = 4.9, -- Shadow Dance
[207736] = 4.9, -- Shadowy Duel
[212283] = 4.9, -- Symbols of Death
[115192] = 4.9, -- Subterfuge
[256735] = 4.9, -- Master Assassin
[340094] = 4.9, -- Master Assassin's Mark (Legendary)
[345569] = 4.9, -- Flagellation (Venthyr Ability)
[347037] = 4.9, -- Sepsis (Night Fae Ability)
--Shaman [114049] = 4.9 , -- Ascendance
[114050] = 4.9, -- Ascendance (Elemental)
[114051] = 4.9, -- Ascendance (Enhancement)
[191634] = 4.9, -- Stormkeeper (Ele)
[320137] = 4.9, -- Stormkeeper (Enh)
[204366] = 4.9, -- Thundercharge (Enhancement PvP Talent)
[335903] = 4.9, -- Doom Winds
[320125] = 4.9, -- Echoing Shock
[333957] = 4.9, -- Feral Spirit
[204361] = 4.9, -- Bloodlust (Enhancement PvP Talent)
[204362] = 4.9, -- Heroism (Enhancement PvP Talent)
[327164] = 4.9, -- Primordial Wave (Necrolord Ability)
--Warlock [113860] = 4.9 , -- Dark Soul: Misery (Affliction)
[113858] = 4.9, -- Dark Soul: Instability (Destruction)
[265273] = 4.9, -- Demonic Power (Demonic Tyrant)
[344566] = 4.9, -- Rapid Contagion (Affliction PvP Talent)
[267171] = 4.9, -- Demonic Strength
[267218] = 4.9, -- Nether Portal
[212295] = 5.2, -- Nether Ward (PvP Talent)
--Warrior
[1719] = 4.9, -- Recklessness
[107574] = 4.9, -- Avatar
[262228] = 4.9, -- Deadly Calm
[198817] = 4.9, -- Sharpen Blade (Arms PvP Talent) - "next cast will..." buff
[324143] = 4.9, -- Conqueror's Banner (Necrolord Ability) - on the warrior
[325862] = 4.9, -- Conqueror's Banner (Necrolord Ability) - on others
},
HARMFUL = {
--Death Knight
[77606] = 4.9, -- Dark Simulacrum
[223929] = 4.9, -- Necrotic Wound
[343294] = 4.9, -- Soul Reaper
[288849] = 4.9, -- Crypt Fever (Necromancer's Bargain Unholy PvP Talent)
--Demon Hunter
[206649] = 4.9, -- Eye of Leotheras
[203704] = 4.9, -- Mana Break
--Hunter
[131894] = 4.9, -- A Murder of Crows
--Monk
[122470] = 4.9, -- Touch of Karma (Debuff)
[344021] = 4.9, -- Keefer's Skyreach
--Paladin
[343721] = 4.9, -- Final Reckoning
[322459] = 4.9, -- Thoughtstolen (Shaman)
[322464] = 4.9, -- Thoughtstolen (Mage)
[322442] = 4.9, -- Thoughtstolen (Druid)
[322462] = 4.9, -- Thoughtstolen (Priest - Holy)
[322457] = 4.9, -- Thoughtstolen (Paladin)
[322463] = 4.9, -- Thoughtstolen (Warlock)
[322461] = 4.9, -- Thoughtstolen (Priest - Discipline)
[322458] = 4.9, -- Thoughtstolen (Monk)
[322460] = 4.9, -- Thoughtstolen (Priest - Shadow)
--Priest
[323673] = 4.9, -- Mindgames
[335467] = 4.9, -- Devouring Plague
[34914] = 4.9, -- Vampiric Touch
[199845] = 4.9, -- Psyflay (Psyfiend) debuff
--Rogue
[79140] = 4.9, -- Vendetta
[328305] = 4.9, -- Sepsis (Night Fae Ability)
--Shaman
[208997] = 4.9, -- Counterstrike Totem (PvP Talent)
--Warlock
[234877] = 4.9, -- Bane of Shadows (Affliction PvP Talent)
[316099] = 4.9, -- Unstable Affliction
[342938] = 4.9, -- Unstable Affliction (Affliction PvP Talent)
[30213] = 4.9, -- Legion Strike
[200587] = 4.9, -- Fel Fissure (PvP Talent)
[80240] = 4.9, -- Havoc
[200548] = 4.9, -- Bane of Havoc (Destro PvP Talent)
--Warrior
[208086] = 4.9, -- Colossus Smash
[198819] = 4.9, -- Mortal Strike when applied with Sharpen Blade (50% healing reduc)
}
}
for spellId, priority in pairs(Data.PriorityAuras) do
if not Data.SpellPriorities[spellId] then
Data.SpellPriorities[spellId] = priority
end
end
Data.BattlegroundspezificBuffs = { --key = mapID, value = table with key = faction(0 for hode, 1 for alliance) value spellId of the flag, minecart
[1339] = { -- Warsong Gulch, used to be mapID 443 before BFA
[0] = 156621, -- Alliance Flag
[1] = 156618 -- Horde Flag
},
[1460] = { -- Warsong Gulch, used in Classic, TBCC
[0] = 301091, -- Alliance Flag
[1] = 301089 -- Horde Flag
},
[112] = { -- Eye of the Storm, used to be mapID 482 before BFA
[0] = 34976, -- Netherstorm Flag
[1] = 34976 -- Netherstorm Flag
},
[1956] = { -- Eye of the Storm, TBCC
[0] = 34976, -- Netherstorm Flag
[1] = 34976 -- Netherstorm Flag
},
[397] = { -- Eye of the Storm (mapID RBG only? Not sure why there are two map IDs for Eye of the Storm), used to be mapID 813 before BFA
[0] = 34976, -- Netherstorm Flag
[1] = 34976 -- Netherstorm Flag
},
[206] = { -- Twin Peaks, used to be mapID 626 before BFA
[0] = 156621, -- Alliance Flag
[1] = 156618 -- Horde Flag
},
[2345] = { -- Deephaul Ravine added in Patch 11.0.2
[0] = 434339, -- Deephaul Crystal
[1] = 434339 -- Deephaul Crystal
}
}
Data.BattlegroundspezificDebuffs = { --key = mapID, value = table with key = number and value = debuff name
[1339] = { -- Warsong Gulch, used to be mapID 443 before BFA
46392, -- Focused Assault
46393 -- Brutal Assault
},
[112] = { -- Eye of the Storm, used to be mapID 482 before BFA
46392, -- Focused Assault
46393 -- Brutal Assault
},
[397] = { -- Eye of the Storm (mapID RBG only? Not sure why there are two map IDs for Eye of the Storm), used to be mapID 813 before BFA
46392, -- Focused Assault
46393 -- Brutal Assault
},
[1956] = { -- Eye of the Storm, TBCC
46392, -- Focused Assault
46393 -- Brutal Assault
},
[206] = { -- Twin Peaks, used to be mapID 626 before BFA
46392, -- Focused Assault
46393 -- Brutal Assault
},
[417] = { -- Temple of Kotmogu, used to be mapID 856 before BFA
121164, -- Orb of Power, Blue
121175, -- Orb of Power, Purple
121177, -- Orb of Power, Orange
121176 -- Orb of Power, Green
}
}
--[[
Classic Data
Insignia of the Alliance 5 min CD
Insignia of the Horde 5 min CD
Medallions got added in TBC and require level 70
Medallion of the Alliance 2 min CD
Medallion of the Horde 2 min CD
]]
local trinketCD
if IsRetail or UnitLevel("player") >= 70 then
trinketCD = 120
else
trinketCD = 300
end
Data.TrinketData = {
[195710] = {cd = 180 }, -- 1: Honorable Medallion, 3. min. CD, detected by Combatlog
[42292] = {cd = trinketCD, itemID = 37865 }, -- 2: Medallion of the Alliance, Medallion of the Horde used in Classic, TBC, and probably some other Expansions 2 min. CD, detected by Combatlog, should show as Medaillon; used in TBC etc
[208683] = {cd = 120 }, -- 2: Gladiator's Medallion, 2 min. CD, detected by Combatlog
[336126] = {cd = 120 }, -- 2: Gladiator's Medallion, 2 min. CD, Shadowlands Update
-- [195901] = {cd = 60, fileID = GetSpellTexture(214027) }, -- 3: Adaptation, 1 min. CD, detected by Aura 195901
-- [214027] = {cd = 60 }, -- 3: Adaptation, 1 min. CD, detected by Aura 195901, for the Arena_cooldownupdate
-- [336135] = {cd = 60 }, -- 3: Adaptation, 1 min. CD, Shadowlands Update
-- [336139] = {cd = 60, fileID = GetSpellTexture(214027) }, -- 3: Adapted, 1 min. CD, Shadowlands Update
[196029] = {cd = false }, -- 4: Relentless, passive, no CD
[336128] = {cd = false }, -- 4: Relentless, passive, no CD, Shadowlands Update
[363117] = {cd = false }, -- 5: Gladiator's Fastidious Resolve, Added in Shadowlands Patch 9.2
}
if IsClassic then
--Classic: there are no spellIDs in the combat log in classic, only spellnames
Mixin(Data.TrinketData, {
[GetSpellName(23273)] = {spellId = 23273, cd = 300, itemID = 18856}, -- Immune Charm/Fear/Polymorph Rogue, Warlock
[GetSpellName(23274)] = {spellId = 23274, cd = 300, itemID = 18856}, -- Immune Fear/Polymorph/Snare Mage
[GetSpellName(23276)] = {spellId = 23276, cd = 300, itemID = 18856}, -- Immune Fear/Polymorph/Stun Paladin, Priest
[GetSpellName(23227)] = {spellId = 23227, cd = 300, itemID = 18856} -- Immune Charm/Fear/Stun Druid
})
end
--see for covenant colors SharedXML/SharedColorConstants.lua
Data.CovenantIcons = {
[1] = GetSpellTexture(324739), --Kyrian
[2] = GetSpellTexture(300728), --Ventyr
[3] = GetSpellTexture(310143), --Night Fae
[4] = GetSpellTexture(324631), --Necrolord
}
--C_Covenants.GetCovenantData()
Data.CovenantSpells = {
--Kyrian
[324739] = 1,--Summon Steward All Classes
[312202] = 1,--Shackle the Unworthy Death Knight
[306830] = 1,--Elysian Decree Demon Hunter
[326434] = 1,--Kindred Spirits Druid
[308491] = 1,--Resonating Arrow Hunter
[307443] = 1,--Radiant Spark Mage
[310454] = 1,--Weapons of Order Monk
[304971] = 1,--Divine Toll Paladin
[325013] = 1,--Boon of the Ascended Priest
[323547] = 1,--Echoing Reprimand Rogue
[324386] = 1,--Vesper Totem Shaman
[312321] = 1,--Scouring Tithe Warrior
[307865] = 1,--Spear of Bastion Warlock
--Ventyr
[300728] = 2, --Door of Shadows All Classes
[311648] = 2,--Swarming Mist Death Knight
[317009] = 2,--Sinful Brand Demon Hunter
[323546] = 2,--Ravenous Frenzy Druid
[324149] = 2,--Flayed Shot Hunter
[314793] = 2,--Mirrors of Torment Mage
[326860] = 2,--Fallen Order Monk
[316958] = 2,--Ashen Hallow Paladin
[323673] = 2,--Mindgames Priest
[323654] = 2,--Flagellation Rogue
[320674] = 2,--Chain Harvest Shaman
[321792] = 2,--Impending Catastrophe Warrior
[317349] = 2,--Condemn Warlock
--Night Fae
[310143] = 3, --Soulshape All Classes
[324128] = 3,--Death's Due Death Knight
[323639] = 3,--The Hunt (ability) Demon Hunter
[323764] = 3,--Convoke the Spirits Druid
[328231] = 3,--Wild Spirits Hunter
[314791] = 3,--Shifting Power Mage
[327104] = 3,--Faeline Stomp Monk
[328278] = 3,--Blessing of the Seasons Paladin
[327661] = 3,--Fae Guardians Priest
[328305] = 3,--Sepsis Rogue
[328923] = 3,--Fae Transfusion Shaman
[325640] = 3,--Soul Rot Warrior
[325886] = 3,--Ancient Aftershock Warlock
--Necrolord
[324631] = 4, --Fleshcraft All Classes
[315443] = 4,--Abomination Limb Death Knight
[329554] = 4,--Fodder to the Flame Demon Hunter
[325727] = 4,--Adaptive Swarm Druid
[325028] = 4,--Death Chakram Hunter
[324220] = 4,--Deathborne Mage
[325216] = 4,--Bonedust Brew Monk
[328204] = 4,--Vanquisher's Hammer Paladin
[324724] = 4,--Unholy Nova Priest
[328547] = 4,--Serrated Bone Spike Rogue
[326059] = 4,--Primordial Wave Shaman
[325289] = 4,--Decimating Bolt Warrior
[324143] = 4,--Conqueror's Banner Warlock
}
Data.RacialSpellIDtoCooldown = {
[7744] = {cd = 120, trinketCD = 30 }, --Will of the Forsaken, Undead Racial, 30 sec cooldown trigger on trinket
[20594] = {cd = 120 }, --Stoneform, Dwarf Racial
[58984] = {cd = 120 }, --Shadowmeld, Night Elf Racial
[59752] = {cd = IsRetail and 180 or 120, trinketCD = 90 }, --Every Man for Himself, Human Racial, 90 sec cooldown trigger on trinket, got renamed in Shadowlands to Will to Survive
[28730] = {cd = 90 }, --Arcane Torrent, Blood Elf Racial, Mage and Warlock,
[50613] = {cd = 90 }, --Arcane Torrent, Blood Elf Racial, Death Knight,
[202719] = {cd = 90 }, --Arcane Torrent, Blood Elf Racial, Demon Hunter,
[80483] = {cd = 90 }, --Arcane Torrent, Blood Elf Racial, Hunter,
[129597] = {cd = 90 }, --Arcane Torrent, Blood Elf Racial, Monk,
[155145] = {cd = 90 }, --Arcane Torrent, Blood Elf Racial, Paladin,
[232633] = {cd = 90 }, --Arcane Torrent, Blood Elf Racial, Priest,
[25046] = {cd = 90 }, --Arcane Torrent, Blood Elf Racial, Rogue,
[69179] = {cd = 90 }, --Arcane Torrent, Blood Elf Racial, Warrior,
[20589] = {cd = 90 }, --Escape Artist, Gnome Racial
[26297] = {cd = 180 }, --Berserkering, Troll Racial
[33702] = {cd = 120 }, --Blood Fury, Orc Racial, Mage, Warlock
[20572] = {cd = 120 }, --Blood Fury, Orc Racial, Warrior, Hunter, Rogue, Death Knight
[33697] = {cd = 120 }, --Blood Fury, Orc Racial, Shaman, Monk
[20577] = {cd = 120 }, --Cannibalize, Undead Racial
[68992] = {cd = 120 }, --Darkflight, Worgen Racial
[59545] = {cd = 180 }, --Gift of the Naaru, Draenei Racial, Death Knight
[59543] = {cd = 180 }, --Gift of the Naaru, Draenei Racial, Hunter
[59548] = {cd = 180 }, --Gift of the Naaru, Draenei Racial, Mage
[121093] = {cd = 180 }, --Gift of the Naaru, Draenei Racial, Monk
[59542] = {cd = 180 }, --Gift of the Naaru, Draenei Racial, Paladin
[59544] = {cd = 180 }, --Gift of the Naaru, Draenei Racial, Priest
[59547] = {cd = 180 }, --Gift of the Naaru, Draenei Racial, Shaman
[28880] = {cd = 180 }, --Gift of the Naaru, Draenei Racial, Warrior
[107079] = {cd = 120 }, --Quaking Palm, Pandaren Racial
[69041] = {cd = 90 }, --Rocket Barrage, Goblin Racial
[69070] = {cd = 90 }, --Rocket Jump, Goblin Racial
[20549] = {cd = 90 }, --War Stomp, Tauren Racial
[312411] = {cd = 90 }, --Bag of Tricks, Vulpera Racial
[265221] = {cd = 120 }, --Fireblood, Dark Iron Dwarf Racial
[255647] = {cd = 150 }, --Light's Judgment, Lightforged Draenei Racial
[255654] = {cd = 120 }, --Bull Rush, Highmountain Tauren Racial
[287712] = {cd = 150 }, --Haymaker, Kul Tiran Racial
[260364] = {cd = 180 } --Arcane Pulse, Nightborne Racial
}
if IsWrath then
Data.RacialSpellIDtoCooldown = {
[7744] = {cd = 120 }, --Will of the Forsaken, Undead Racial, 30 sec cooldown trigger on trinket
[20594] = {cd = 120 }, --Stoneform, Dwarf Racial
[58984] = {cd = 120 }, --Shadowmeld, Night Elf Racial
[20549] = {cd = 120 }, --War Stomp, Tauren Racial
[28730] = {cd = 120 }, --Arcane Torrent, Blood Elf Racial, Mage and Warlock,
[50613] = {cd = 120 }, --Arcane Torrent, Blood Elf Racial, Death Knight,
[202719] = {cd = 120 }, --Arcane Torrent, Blood Elf Racial, Demon Hunter,
[80483] = {cd = 120 }, --Arcane Torrent, Blood Elf Racial, Hunter,
[129597] = {cd = 120 }, --Arcane Torrent, Blood Elf Racial, Monk,
[155145] = {cd = 120 }, --Arcane Torrent, Blood Elf Racial, Paladin,
[232633] = {cd = 120 }, --Arcane Torrent, Blood Elf Racial, Priest,
[25046] = {cd = 120 }, --Arcane Torrent, Blood Elf Racial, Rogue,
[69179] = {cd = 120 }, --Arcane Torrent, Blood Elf Racial, Warrior,
[33702] = {cd = 120 }, --Blood Fury, Orc Racial, Mage, Warlock
[20572] = {cd = 120 }, --Blood Fury, Orc Racial, Warrior, Hunter, Rogue, Death Knight
[33697] = {cd = 120 }, --Blood Fury, Orc Racial, Shaman, Monk
[20589] = {cd = 105 }, --Escape Artist, Gnome Racial
}
end
Data.RacialNameToSpellIDs = {}
Data.Racialnames = {}
for spellId in pairs(Data.RacialSpellIDtoCooldown) do
local racialName = GetSpellName(spellId)
if racialName and racialName ~= "" then
if not Data.RacialNameToSpellIDs[racialName] then
Data.RacialNameToSpellIDs[racialName] = {}
Data.Racialnames[racialName] = racialName
end
Data.RacialNameToSpellIDs[racialName][spellId] = true
end
end
-- Data.EnemiesRangeToRange = {}
-- Data.EnemiesItemIDToRange = {}
-- Data.EnemiesRangeToItemID = {
-- [5] = 37727, -- Ruby Acorn --works, also for allies,
-- [6] = 63427, -- Worgsaw --works, also for allies,
-- [8] = 34368, -- Attuned Crystal Cores --works, also for allies,
-- [10] = 32321, -- Sparrowhawk Net
-- [15] = 33069, -- Sturdy Rope --doesn't work on allies
-- [20] = 10645, -- Gnomish Death Ray --doesn't work on allies
-- [25] = 24268, -- Netherweave Net --doesn't work on allies
-- [30] = 34191, -- Handful of Snowflakes
-- [35] = 18904, -- Zorbin's Ultra-Shrinker