-
Notifications
You must be signed in to change notification settings - Fork 41
/
Copy pathPlater_Data.lua
851 lines (769 loc) · 33.2 KB
/
Plater_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
--this file load after Plater_DefaultSettings.lua and before Plater.lua
--_G.Plater doesn't exists yet
local _
local addonName, platerInternal = ...
--namespaces
platerInternal.Scripts = {}
platerInternal.CastBar = {}
platerInternal.Mods = {}
platerInternal.Events = {}
platerInternal.Comms = {}
platerInternal.Frames = {}
platerInternal.Data = {}
platerInternal.Date = {}
platerInternal.Logs = {}
platerInternal.Audio = {}
---@type table<guid, boolean>
platerInternal.HasFriendlyAffiliation = {}
platerInternal.RemoveColor = "!removecolor"
platerInternal.NoColor = "no color"
platerInternal.Defaults = {
dropdownStatusBarTexture = [[Interface\Tooltips\UI-Tooltip-Background]],
dropdownStatusBarColor = {.1, .1, .1, .8},
}
platerInternal.UnitIdCache = {}
platerInternal.UnitIdCache.Party = {"player"}
platerInternal.UnitIdCache.PartyPet = {"playetpet"}
for i = 1, 4 do
table.insert(platerInternal.UnitIdCache.Party, "party" .. i)
table.insert(platerInternal.UnitIdCache.PartyPet, "partypet" .. i)
end
--cache unitIds so string unitId manipulating are no longer required
platerInternal.UnitIdCache.Raid = {}
platerInternal.UnitIdCache.RaidPet = {}
for i = 1, 40 do
platerInternal.UnitIdCache.Raid[i] = "raid" .. i
platerInternal.UnitIdCache.RaidPet[i] = "raidpet" .. i
end
platerInternal.UnitIdCache.Boss = {}
for i = 1, 9 do
platerInternal.UnitIdCache.Boss[i] = "boss" .. i
end
platerInternal.UnitIdCache.Nameplate = {}
for i = 1, 40 do
platerInternal.UnitIdCache.Nameplate[i] = "nameplate" .. i
end
platerInternal.UnitIdCache.Arena = {}
for i = 1, 5 do
platerInternal.UnitIdCache.Arena[i] = "arena" .. i
end
function platerInternal.CreateDataTables(Plater)
--addon comm
Plater.COMM_PLATER_PREFIX = "PLT"
Plater.COMM_SCRIPT_GROUP_EXPORTED = "GE"
Plater.COMM_SCRIPT_MSG = "PLTM"
Plater.COMM_NPC_NAME_EXPORTED = "NN"
Plater.COMM_NPC_COLOR_EXPORTED = "NC"
Plater.COMM_NPC_OR_CAST_CUSTOMIZATION = "NCC"
--unit reaction (saved 3 global locals)
Plater.UnitReaction = {
UNITREACTION_HOSTILE = 3,
UNITREACTION_NEUTRAL = 4,
UNITREACTION_FRIENDLY = 5,
}
--declaring the performance units within the plater namespace
Plater.PerformanceUnits = {}
--namespaces
Plater.Resources = {}
Plater.Auras = {}
--store spell cache. spell cache is loaded when adding new auras to track
Plater.SpellHashTable = {}
Plater.SpellIndexTable = {}
Plater.SpellSameNameTable = {}
--export strings identification
Plater.Export_CastColors = "CastColor"
Plater.Export_CastSoundAlerts = "CastSounds"
Plater.Export_NpcColors = "NpcColor"
--these tables store all bars created by boss mods
Plater.BossModsTimeBarDBM = {}
Plater.BossModsTimeBarBW = {}
--icon texcoords
Plater.WideIconCoords = {.1, .9, .1, .6} --used in extra icons frame, constant, can be changed with scripts
Plater.BorderLessIconCoords = {.1, .9, .1, .9} --used in extra icons frame,constant, can be changed with scripts
--note: regular icons has their texcoords automatically adjusted
--limit the cast bar text to this (this is dynamically adjusted at run time)
Plater.MaxCastBarTextLength = nil -- global overwrite
--auras
Plater.MaxAurasPerRow = 10 --can change during runtime
Plater.ForceInCombatUnits = {
--[] = true, --
[168326] = true, --Shattered Visage, Mueh'zala De Other Side
[170927] = true, --Erupting Ooze, Doctor Ickus Plaguefall
[171887] = true, --Slimy Smorgasbord, Globgrog Plaguefall
[164362] = true, --Slimy Morsel, Globgrog Plaguefall
[169159] = true, --Unstable Canister, Plaguefall
[168394] = true, --Slimy Morsel, Plaguefall
[176581] = true, --Spiked Ball, Painsmith Raznal SoD
[176920] = true, --Domination Arrow, Sylvanas SoD
[178008] = true, --Decrepit Orb, Sylvanas SoD
[179963] = true, --Terror Orb, Sylvanas SoD
[175861] = true, --Glacial Spike, Kel'Thusad SoD
[182778] = true, --Collapsing Quasar, Rygelon SotFO
[182823] = true, --Cosmic Core, Rygelon SotFO
[183945] = true, --Unstable Matter, Rygelon SotFO
[183745] = true, --Protoform Schematic, Lihuvim SotFO
[188302] = true, --Reconfiguration Emitter, Shadowlands S4 Fated affix
[188703] = true, --Protoform Barrier, Shadowlands S4 Fated affix
[176026] = true, --Dancing Fools, Council of Blood CN
[195318] = true,
[195580] = true,
[195820] = true,
[196642] = true,
[189886] = true,
[192955] = true,
[194806] = true,
[196548] = true,
[197398] = true,
[112668] = true,
[96608] = true,
[102019] = true,
[189893] = true, --187894?
[75966] = true, --75451?
[75899] = true,
[76518] = true,
[56792] = true,
[196559] = true,
[190187] = true,
[195138] = true,
[195821] = true,
[99922] = true,
[104822] = true,
[120651] = true, --explosives (M+)
[190381] = true, --Rotburst Totem
[130896] = true, --Blackout Barrel
[129758] = true, --Irontide Grenadier
[196712] = true, --Nullification Device
[195399] = true, --Curious Swoglet
[196043] = true, --Primalist Infuser
[97720] = true, --Blightshard Skitter
[98081] = true, --Bellowing Idol
[101075] = true, --Wormspeaker Devout
[101476] = true, --Molten Charskin
[192464] = true, --Raging Ember
[186696] = true, --Quaking Totem
[186107] = true, --Vault Keeper
[413263] = true, --Skyfall Nova
[202824] = true, --Erratic Remnant
[203230] = true, --Dragonfire Golem
[203812] = true, --Voice From Beyond
[100818] = true, -- Bellowing Idol
[92538] = true, -- Tarspitter Grub
[136330] = true, -- Soul Thorns
[136541] = true, -- Bile Oozeling
[133361] = true, -- Wasting Servant
[99664] = true, -- Restless Soul
[101008] = true, -- Stinging Swarm
[213219] = true, -- Bubbling Ooze
[214117] = true, -- Stormflurry Totem
[84400] = true, -- Flourishing Ancient
[100991] = true, -- Strangling Roots
[131009] = true, -- Spirit of Gold
[127315] = true, -- Reanimation Totem
[125828] = true, -- Soulspawn
[205212] = true, -- Infinite Keeper
[205265] = true, -- Time-Displaced Trooper
}
--textures used in the cooldown animation, scripts can add more values to it, profile holds only the path to it
Plater.CooldownEdgeTextures = {
[[Interface\AddOns\Plater\images\cooldown_edge_1]],
[[Interface\AddOns\Plater\images\cooldown_edge_2]],
"Interface\\Cooldown\\edge",
"Interface\\Cooldown\\edge-LoC",
[[Interface\AddOns\Plater\images\transparent]],
}
--textures used in the castbar, scripts can add more values to it, profile holds only the path to it
Plater.SparkTextures = {
[[Interface\AddOns\Plater\images\spark1]],
[[Interface\AddOns\Plater\images\spark2]],
[[Interface\AddOns\Plater\images\spark3]],
[[Interface\AddOns\Plater\images\spark4]],
[[Interface\AddOns\Plater\images\spark5]],
[[Interface\AddOns\Plater\images\spark6]],
[[Interface\AddOns\Plater\images\spark7]],
[[Interface\AddOns\Plater\images\spark8]],
}
--textures used to indicate which nameplate is the current target, scripts can add more values to it, profile holds only the path to it
Plater.TargetHighlights = {
[[Interface\AddOns\Plater\images\selection_indicator1]],
[[Interface\AddOns\Plater\images\selection_indicator2]],
[[Interface\AddOns\Plater\images\selection_indicator3]],
[[Interface\AddOns\Plater\images\selection_indicator4]],
[[Interface\AddOns\Plater\images\selection_indicator5]],
[[Interface\AddOns\Plater\images\selection_indicator6]],
[[Interface\AddOns\Plater\images\selection_indicator7]],
[[Interface\AddOns\Plater\images\selection_indicator8]],
}
--icons available for any purpose
Plater.Media = {
Icons = {
[[Interface\AddOns\Plater\media\arrow_apple_64]],
[[Interface\AddOns\Plater\media\arrow_double_right_64]],
[[Interface\AddOns\Plater\media\arrow_right_64]],
[[Interface\AddOns\Plater\media\arrow_simple_right_64]],
[[Interface\AddOns\Plater\media\arrow_single_right_64]],
[[Interface\AddOns\Plater\media\arrow_thin_right_64]],
[[Interface\AddOns\Plater\media\blocked_center_64]],
[[Interface\AddOns\Plater\media\crown_64]],
[[Interface\AddOns\Plater\media\drop_64]],
[[Interface\AddOns\Plater\media\duck_64]],
[[Interface\AddOns\Plater\media\exclamation_64]],
[[Interface\AddOns\Plater\media\exclamation2_64]],
[[Interface\AddOns\Plater\media\fire_64]],
[[Interface\AddOns\Plater\media\glasses_64]],
[[Interface\AddOns\Plater\media\glow_horizontal_256]],
[[Interface\AddOns\Plater\media\glow_radial_128]],
[[Interface\AddOns\Plater\media\glow_square_64]],
[[Interface\AddOns\Plater\media\hat_64]],
[[Interface\AddOns\Plater\media\heart_center_64]],
[[Interface\AddOns\Plater\media\line_horizontal_256]],
[[Interface\AddOns\Plater\media\line_vertical_256]],
[[Interface\AddOns\Plater\media\radio_64]],
[[Interface\AddOns\Plater\media\skullbones_64]],
[[Interface\AddOns\Plater\media\stop_64]],
[[Interface\AddOns\Plater\media\star_empty_64]],
[[Interface\AddOns\Plater\media\star_full_64]],
[[Interface\AddOns\Plater\media\x_64]],
[[Interface\AddOns\Plater\media\checked_64]],
[[Interface\AddOns\Plater\media\sphere_full_64]],
[[Interface\AddOns\Plater\media\eye_64]],
[[Interface\AddOns\Plater\media\cross_64]],
},
}
--these are the images shown in the nameplate of the current target, they are placed in the left and right side of the health bar, scripts can add more options
--if the coords has 2 tables, it uses two textures attach in the left and right sides of the health bar
--if the coords has 4 tables, it uses 4 textures attached in top left, bottom left, top right and bottom right corners
Plater.TargetIndicators = {
["NONE"] = {
path = [[Interface\ACHIEVEMENTFRAME\UI-Achievement-WoodBorder-Corner]],
coords = {{.9, 1, .9, 1}, {.9, 1, .9, 1}, {.9, 1, .9, 1}, {.9, 1, .9, 1}}, --texcoords, support 4 or 8 coords method
desaturated = false,
width = 10,
height = 10,
x = 1, --offset
y = 1, --offset
},
["Magneto"] = {
path = [[Interface\Artifacts\RelicIconFrame]],
coords = {{0, .5, 0, .5}, {0, .5, .5, 1}, {.5, 1, .5, 1}, {.5, 1, 0, .5}},
desaturated = false,
width = 8,
height = 10,
autoScale = true,
--scale = 1,
x = 2,
y = 2,
},
["Gray Bold"] = {
path = [[Interface\ContainerFrame\UI-Icon-QuestBorder]],
coords = {{0, .5, 0, .5}, {0, .5, .5, 1}, {.5, 1, .5, 1}, {.5, 1, 0, .5}},
desaturated = true,
width = 10,
height = 10,
autoScale = true,
--scale = 1,
x = 2,
y = 2,
},
["Pins"] = {
path = [[Interface\ITEMSOCKETINGFRAME\UI-ItemSockets]],
coords = {{145/256, 161/256, 3/256, 19/256}, {145/256, 161/256, 19/256, 3/256}, {161/256, 145/256, 19/256, 3/256}, {161/256, 145/256, 3/256, 19/256}},
desaturated = 1,
width = 4,
height = 4,
autoScale = false,
--scale = 1,
x = 2,
y = 2,
},
["Silver"] = {
path = [[Interface\PETBATTLES\PETBATTLEHUD]],
coords = {
{848/1024, 868/1024, 454/512, 474/512},
{848/1024, 868/1024, 474/512, 495/512},
{868/1024, 889/1024, 474/512, 495/512},
{868/1024, 889/1024, 454/512, 474/512}
}, --848 889 454 495
desaturated = false,
width = 6,
height = 6,
autoScale = true,
--scale = 1,
x = 1,
y = 1,
},
["Ornament"] = {
path = [[Interface\PETBATTLES\PETJOURNAL]],
coords = {
{124/512, 161/512, 71/1024, 99/1024},
{119/512, 156/512, 29/1024, 57/1024}
},
desaturated = false,
width = 18,
height = 12,
wscale = 1,
hscale = 1.2,
autoScale = true,
--scale = 1,
x = 14,
y = 0,
},
["Golden"] = {
path = [[Interface\Artifacts\Artifacts]],
coords = {
{137/1024, (137+29)/1024, 920/1024, 978/1024},
{(137+30)/1024, 195/1024, 920/1024, 978/1024},
},
desaturated = false,
width = 8,
height = 12,
wscale = 1,
hscale = 1.2,
autoScale = true,
--scale = 1,
x = 0,
y = 0,
},
["Ornament Gray"] = {
path = [[Interface\Challenges\challenges-besttime-bg]],
coords = {
{89/512, 123/512, 0, 1},
{123/512, 89/512, 0, 1},
},
desaturated = false,
width = 8,
height = 12,
alpha = 0.7,
wscale = 1,
hscale = 1.2,
autoScale = true,
--scale = 1,
x = 0,
y = 0,
color = "red",
},
["Epic"] = {
path = [[Interface\UNITPOWERBARALT\WowUI_Horizontal_Frame]],
coords = {
{30/256, 40/256, 15/64, 49/64},
{40/256, 30/256, 15/64, 49/64},
},
desaturated = false,
width = 6,
height = 12,
wscale = 1,
hscale = 1.2,
autoScale = true,
--scale = 1,
x = 3,
y = 0,
blend = "ADD",
},
["Arrow"] = {
path = [[Interface\AddOns\Plater\media\arrow_single_right_64]],
coords = {
{0, 1, 0, 1},
{1, 0, 0, 1}
},
desaturated = false,
width = 20,
height = 20,
x = 28,
y = 0,
wscale = 1.5,
hscale = 2,
autoScale = true,
--scale = 1,
blend = "ADD",
color = "white",
},
["Arrow Thin"] = {
path = [[Interface\AddOns\Plater\media\arrow_thin_right_64]],
coords = {
{0, 1, 0, 1},
{1, 0, 0, 1}
},
desaturated = false,
width = 20,
height = 20,
x = 28,
y = 0,
wscale = 1.5,
hscale = 2,
autoScale = true,
--scale = 1,
blend = "ADD",
color = "white",
},
["Double Arrows"] = {
path = [[Interface\AddOns\Plater\media\arrow_double_right_64]],
coords = {
{0, 1, 0, 1},
{1, 0, 0, 1}
},
desaturated = false,
width = 20,
height = 20,
x = 28,
y = 0,
wscale = 1.5,
hscale = 2,
autoScale = true,
--scale = 1,
blend = "ADD",
color = "white",
},
}
--which specs each class has available
Plater.SpecList = { --private
["DEMONHUNTER"] = {
[577] = true,
[581] = true,
},
["DEATHKNIGHT"] = {
[250] = true,
[251] = true,
[252] = true,
},
["WARRIOR"] = {
[71] = true,
[72] = true,
[73] = true,
},
["MAGE"] = {
[62] = true,
[63] = true,
[64] = true,
},
["ROGUE"] = {
[259] = true,
[260] = true,
[261] = true,
},
["DRUID"] = {
[102] = true,
[103] = true,
[104] = true,
[105] = true,
},
["HUNTER"] = {
[253] = true,
[254] = true,
[255] = true,
},
["SHAMAN"] = {
[262] = true,
[263] = true,
[264] = true,
},
["PRIEST"] = {
[256] = true,
[257] = true,
[258] = true,
},
["WARLOCK"] = {
[265] = true,
[266] = true,
[267] = true,
},
["PALADIN"] = {
[65] = true,
[66] = true,
[70] = true,
},
["MONK"] = {
[268] = true,
[269] = true,
[270] = true,
},
["EVOKER"] = {
[1467] = true,
[1468] = true,
[1473] = true,
},
}
--default ranges to use in the range check proccess against enemies, player can select a different range in the options panel
Plater.DefaultSpellRangeList = {
--classes
[1] = 10, --Warrior
[2] = 30, --Paladin
[3] = 30, --Hunter
[4] = 10, --Rogue
[5] = 30, --Priest
[6] = 10, --DeathKnight
[7] = 30, --Shaman
[8] = 30, --Mage
[9] = 30, --Warlock
[10] = 10, --Monk
[11] = 30, --Druid
[12] = 10, --DH
[577] = 30, --> havoc demon hunter
[581] = 30, --> vengeance demon hunter
[250] = 30, --> blood dk
[251] = 30, --> frost dk
[252] = 30, --> unholy dk
[102] = 45, --> druid balance
[103] = 40, --> druid feral
[104] = 30, --> druid guardian
[105] = 40, --> druid resto
[253] = 40, --> hunter bm - Cobra Shot
[254] = 40, --> hunter marks - Aimed Shot
[255] = 40, --> hunter survivor - Serpent Sting
[62] = 40, --> mage arcane
[63] = 40, --> mage fire
[64] = 40, --> mage frost
[268] = 30 , --> monk bm
[269] = 40, --> monk ww
[270] = 40, --> monk mw
[65] = 40, --> paladin holy
[66] = 30, --> paladin protect
[70] = 30, --> paladin ret
[256] = 40, --> priest disc
[257] = 40, --> priest holy
[258] = 40, --> priest shadow
[259] = 30, --> rogue assassination
[260] = 20, --> rogue outlaw
[261] = 30, --> rogue sub
[262] = 40, --> shaman elemental
[263] = 40, --> shaman enhancement
[264] = 40, --> shaman resto
[265] = 40, --> warlock aff
[266] = 40, --> warlock demo
[267] = 40, --> warlock destro
[71] = 30, --> warrior arms
[72] = 30, --> warrior fury
[73] = 30, --> warrior protect
[1467] = 25, --> evoker devastation
[1468] = 25, --> evoker preservation
[1473] = 25, --> evoker augmentation
-- low-level (without spec)
[1444] = 40, --> Initial SHAMAN
[1446] = 40, --> Initial WARRIOR
[1447] = 40, --> Initial DRUID
[1448] = 40, --> Initial HUNTER
[1449] = 40, --> Initial MAGE
[1450] = 40, --> Initial MONK
[1451] = 40, --> Initial PALADIN
[1452] = 40, --> Initial PRIEST
[1453] = 40, --> Initial ROGUE
[1454] = 40, --> Initial WARLOCK
[1455] = 40, --> Initial DK
[1456] = 40, --> Initial DH
}
--default ranges to use in the range check proccess against friendlies, player can select a different range in the options panel
Plater.DefaultSpellRangeListF = {
--classes
[1] = 30, --Warrior
[2] = 40, --Paladin
[3] = 40, --Hunter
[4] = 10, --Rogue
[5] = 40, --Priest
[6] = 30, --DeathKnight
[7] = 40, --Shaman
[8] = 40, --Mage
[9] = 40, --Warlock
[10] = 40, --Monk
[11] = 40, --Druid
[12] = 30, --DH
[577] = 30, --> havoc demon hunter
[581] = 30, --> vengeance demon hunter
[250] = 30, --> blood dk
[251] = 30, --> frost dk
[252] = 30, --> unholy dk
[102] = 45, --> druid balance
[103] = 40, --> druid feral
[104] = 30, --> druid guardian
[105] = 40, --> druid resto
[253] = 40, --> hunter bm - Cobra Shot
[254] = 40, --> hunter marks - Aimed Shot
[255] = 40, --> hunter survivor - Serpent Sting
[62] = 40, --> mage arcane
[63] = 40, --> mage fire
[64] = 40, --> mage frost
[268] = 30 , --> monk bm
[269] = 40, --> monk ww
[270] = 40, --> monk mw
[65] = 40, --> paladin holy
[66] = 30, --> paladin protect
[70] = 30, --> paladin ret
[256] = 40, --> priest disc
[257] = 40, --> priest holy
[258] = 40, --> priest shadow
[259] = 10, --> rogue assassination
[260] = 10, --> rogue outlaw
[261] = 10, --> rogue sub
[262] = 40, --> shaman elemental
[263] = 40, --> shaman enhancement
[264] = 40, --> shaman resto
[265] = 40, --> warlock aff
[266] = 40, --> warlock demo
[267] = 40, --> warlock destro
[71] = 30, --> warrior arms
[72] = 30, --> warrior fury
[73] = 30, --> warrior protect
[1467] = 25, --> evoker devastation
[1468] = 25, --> evoker preservation
[1473] = 25, --> evoker augmentation
-- low-level (without spec)
[1444] = 40, --> Initial SHAMAN
[1446] = 40, --> Initial WARRIOR
[1447] = 40, --> Initial DRUID
[1448] = 40, --> Initial HUNTER
[1449] = 40, --> Initial MAGE
[1450] = 40, --> Initial MONK
[1451] = 40, --> Initial PALADIN
[1452] = 40, --> Initial PRIEST
[1453] = 40, --> Initial ROGUE
[1454] = 40, --> Initial WARLOCK
[1455] = 40, --> Initial DK
[1456] = 40, --> Initial DH
}
--types of codes for each script in the Scripting tab (do not change these inside scripts)
Plater.CodeTypeNames = { --private
[1] = "UpdateCode",
[2] = "ConstructorCode",
[3] = "OnHideCode",
[4] = "OnShowCode",
[5] = "Initialization",
}
--hook options
--types of codes available to add in a script in the Hooking tab
Plater.HookScripts = { --private
"Initialization",
"Deinitialization",
"Constructor",
"Destructor",
"Nameplate Created",
"Nameplate Added",
"Nameplate Removed",
"Nameplate Updated",
"Cast Start",
"Cast Update",
"Cast Stop",
"Target Changed",
"Raid Target",
"Enter Combat",
"Leave Combat",
"Player Power Update",
"Player Talent Update",
"Health Update",
"Zone Changed",
"Name Updated",
"Load Screen",
"Player Logon",
"Receive Comm Message",
"Send Comm Message",
"Option Changed",
"Mod Option Changed",
}
Plater.HookScriptsDesc = { --private
["Initialization"] = "Executed once for the mod every time it is loaded or compiled. Used to initialize the global mod environment 'modTable'.",
["Deinitialization"] = "Executed once for the mod every time it is unloaded. Used to de-initialize the global mod environment 'modTable' and the mod.",
["Constructor"] = "Executed once when the nameplate run the hook for the first time.\n\nUse to initialize configs in the environment.\n\nAlways receive unitFrame in 'self' parameter.",
["Destructor"] = "Run when the hook is Disabled or unloaded due to Load Conditions.\n\nUse to hide all frames created.\n\n|cFF44FF44Run on all nameplates shown in the screen|r.",
["Nameplate Created"] = "Executed when a nameplate is created.\n\nRequires a |cFFFFFF22/reload|r after changing the code.",
["Nameplate Added"] = "Run after a nameplate is added to the screen.",
["Nameplate Removed"] = "Run when the nameplate is removed from the screen.",
["Nameplate Updated"] = "Run after the nameplate gets an updated from Plater.\n\n|cFFFFFF22Important:|r doesn't run every frame.",
["Cast Start"] = "When the unit starts to cast a spell.\n\n|cFFFFFF22self|r is unitFrame.castBar",
["Cast Update"] = "When the cast bar receives an update from Plater.\n\n|cFFFFFF22Important:|r doesn't run every frame.\n\n|cFFFFFF22self|r is unitFrame.castBar",
["Cast Stop"] = "When the cast is finished for any reason or the nameplate has been removed from the screen.\n\n|cFFFFFF22self|r is unitFrame.castBar",
["Target Changed"] = "Run after the player selects a new target.\n\n|cFF44FF44Run on all nameplates shown in the screen|r.",
["Raid Target"] = "A raid target mark has added, modified or removed (skull, cross, etc).\n\n|cFF44FF44Run on all nameplates shown in the screen|r.",
["Enter Combat"] = "Executed shortly after the player enter combat.\n\n|cFF44FF44Run on all nameplates shown in the screen|r.",
["Leave Combat"] = "Executed shortly after the player leave combat.\n\n|cFF44FF44Run on all nameplates shown in the screen|r.",
["Player Power Update"] = "Run when the player power, such as combo points, gets an update.\n\n|cFF44FF44Run only on the nameplate of your current target|r.",
["Player Talent Update"] = "When the player changes a talent or specialization.\n\n|cFF44FF44Run on all nameplates shown in the screen|r.",
["Health Update"] = "When the health of the unit changes.",
["Zone Changed"] = "Run when the player enter into a new zone.\n\n|cFF44FF44Run on all nameplates already created, on screen or not|r.",
["Name Updated"] = "Executed when the name of the unit shown in the nameplate receives an update.",
["Load Screen"] = "Run when a load screen finishes.\n\nUse to change settings for a specific area or map.\n\n|cFF44FF44Do not run on nameplates|r.",
["Player Logon"] = "Run when the player login into the game.\n\nUse to register textures, indicators, etc.\n\n|cFF44FF44Do not run on nameplates,\nrun only once after login\nor /reload|r.",
["Receive Comm Message"] = "Executed when a comm is received, a comm can be sent using Plater.SendComm(payload) in 'Send Comm Message' hook.",
["Send Comm Message"] = "Executed on an internal timer for each mod. Used to send comm data via Plater.SendComm(payload).",
["Option Changed"] = "Executed when a option in the options panel has changed",
["Mod Option Changed"] = "Executed when a option in the mod options panel has changed",
}
--all functions below can be overridden by scripts, hooks or any external code
--this allows the user to fully modify Plater at a high level
--how to override a function:
--create a script in the hooking tab, add a 'Constructor' and a 'Nameplate Created'
--copy the entire function from this file and paste in the constructor, hit save.
--then when the first nameplate appears in the screen the function get rewritten
--for fast debugging is recomended to paste the function in a 'Nameplate Updated' hook so just by saving the script (SHIFT + ENTER) you get the function to update immediately.
Plater.CanOverride_Functions = {
RefreshDBUpvalues = true, --refresh cache
RefreshDBLists = true, --refresh cache
UpdateAuraCache = true, --refresh cache
CreateShowAuraIconAnimation = true, --creates the animation for aura icons played when they are shown
GetHealthCutoffValue = true, --check if the character has a execute range and enable or disable the health cut off indicators
CheckRange = true, --check if the player is in range of the unit
GetSpellForRangeCheck = true, --get a spell to be used in the range check
SetFontOutlineAndShadow = true, --apply the outline and shadow of a text
UpdatePersonalBar = true, --update the personal bar
UpdateResourceFrame = true, --anchors the resource frame (soul shards, combo points, etc)
UpdateCastbarTargetText = true, --update the settings of the cast target (font color, size, etc)
UpdateSpellNameSize = true, --receive a fontString and set the length of the spell name size in the cast bar
QuickHealthUpdate = true, --update the health bar during NAMEPLATE_ADDED
OnUpdateHealth = true, --when the healthbar get a new health value
OnUpdateHealthMax = true, --when the maxhealth of the healthbar get updated
UpdateIconAspecRatio = true, --adjust the icon texcoords depending on its size
FormatTime = true, --get a number and return it formated into time, e.g. 63 return "1m" 1 minute
FormatTimeDecimal = true, --get a number and return it formated into time with decimals below 10sec, e.g. 9.5 return "9.5s"
GetAuraIcon = true, --return an icon to be use to show an aura
AddAura = true, --adds an aura into the nameplate, require all the aura data and an icon
AddExtraIcon = true, --adds an aura into the extra buff row of icons, require the aura data
HideNonUsedAuraIcons = true, --after an aura refresh, hide all non used icons in the aura container
ResetAuraContainer = true, --reset the aura container to be ready to a refresh
TrackSpecificAuras = true, --refresh the aura container using a list of auras to track
UpdateAuras_Manual = true, --start an aura refresh for manual aura tracking
UpdateAuras_Automatic = true, --start an aura refresh for automatic aura tracking
UpdateAuras_Self_Automatic = true, --start an aura refresh on the personal bar nameplate
ColorOverrider = true, --control which color que nameplate will have when the Override Default Colors are enabled
FindAndSetNameplateColor = true, --Plater tries to find a color for the nameplate
SetTextColorByClass = true, --adds the class color into a text with scape sequence
UpdatePlateSize = true, --control the size of health, cast, power bars
SetPlateBackground = true, --set the backdrop when showing the nameplate area
UpdateNameplateThread = true, --change the nameplate color based on threat
UpdateTargetHighlight = true, --adjust the highlight on the player target nameplate
UpdateTargetIndicator = true, --adjust the target indicator on the player target nameplate
UpdateLifePercentVisibility = true, --control when the life percent text is shown
UpdateLifePercentText = true, --update the health shown in the nameplate
AddGuildNameToPlayerName = true, --adds the guild name into the player name
UpdateUnitName = true, --update the unit name
UpdateUnitNameTextSize = true, --controls the length of the unit name text
UpdateBorderColor = true, --update the color of the border
UpdatePlateBorderThickness = true, --adjust how thick is the border around the health bar
UpdatePlateRaidMarker = true, --update the raid marker in the nameplate
UpdateIndicators = true, --check which indicators will be shown in the nameplate (rare, elite, etc)
AddIndicator = true, --adds an indicator
ClearIndicators = true, --clear all indicators in the nameplate
GetPlateAlpha = true, --get the absolute alpha amount for the nameplate (when in range)
CheckHighlight = true, --check if the mouse is over the nameplate and show the highlight
EnableHighlight = true, --enable the highlight check
DisableHighlight = true, --disable the highlight check
GetUnitType = true, --return if an unit is a pet, minor or regular
AnimateLeftWithAccel = true, --move the health bar to left when health animation is enabled
AnimateRightWithAccel = true, --move the health bar to right when health animation is enabled
IsQuestObjective = true, --check if the npc from the nameplate is a quest mob
}
--store functions and members which can be overridden by scripts
Plater.CanOverride_Members = {
TargetIndicators = true, --table with all options for target indicators
TargetHighlights = true, --table with all options for target highlight
SparkTextures = true, --table with all textures available for castbar sparks
CooldownEdgeTextures = true, --table with all textures available for cooldown edges
AurasHorizontalPadding = true, --space in pixels between each row of buffs
WideIconCoords = true, --used on buff special icons, are the texcoordinates when using wide icons
BorderLessIconCoords = true, --used on buff special icons, when not using wide icons
PlayerIsTank = true, --for aggro checks, if true the function will consider the player as tank
CombatTime = true, --GetTime() of when the player entered in combat, affect aggro animations
CurrentEncounterID = true, --store the current encounter ID if in combat and fighiting a boss
LatestEncounter = true, --store time() from the latest ENCOUNTER_END
ZoneInstanceType = true, --from GetInstanceInfo zone type, can be party, raid, arena, pvp, none
ZonePvpType = true, --from GetZonePVPInfo
PlayerGuildName = true, --name of the player's guild
SpellForRangeCheck = true, --spell name used for range check
PlayerGUID = true, --store the GUID of the player
PlayerClass = true, --store the name for the player (non localized)
}
end