-
Notifications
You must be signed in to change notification settings - Fork 762
Expand file tree
/
Copy pathsc_warlock.hpp
More file actions
1243 lines (1069 loc) · 46.1 KB
/
sc_warlock.hpp
File metadata and controls
1243 lines (1069 loc) · 46.1 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
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
#pragma once
#include "simulationcraft.hpp"
#include "player/pet_spawner.hpp"
#include "sc_warlock_pets.hpp"
#include "action/parse_effects.hpp"
#include "class_modules/apl/warlock.hpp"
namespace warlock
{
enum dimensional_rift_pet_e
{
DR_PET_SHADOWY_TEAR,
DR_PET_UNSTABLE_TEAR,
DR_PET_CHAOS_TEAR,
DR_PET_OVERFIEND
};
enum dominion_of_argus_pet_e
{
DOA_PET_RANDOM = -1,
DOA_PET_JAILER,
DOA_PET_SACROLASH,
DOA_PET_GRAND_WARLOCK,
DOA_PET_INQUISITOR,
DOA_PET_MAX
};
struct warlock_t;
// Finds an action with the given name. If no action exists, a new one will
// be created.
//
// Use this with secondary background actions to ensure the player only has
// one copy of the action.
template <typename Action, typename Actor, typename... Args>
action_t* get_action( util::string_view name, Actor* actor, Args&&... args )
{
action_t* a = actor->find_action( name );
if ( !a )
a = new Action( name, actor, std::forward<Args>( args )... );
assert( dynamic_cast<Action*>( a ) && a->name_str == name && a->background );
return a;
}
struct warlock_td_t : public actor_target_data_t
{
struct debuffs_t
{
// Aff
propagate_const<buff_t*> haunt;
// Demo
propagate_const<buff_t*> doom;
// Destruction
propagate_const<buff_t*> lake_of_fire;
propagate_const<buff_t*> shadowburn;
propagate_const<buff_t*> havoc;
// Diabolist
propagate_const<buff_t*> cloven_soul;
// Hellcaller
propagate_const<buff_t*> blackened_soul; // Dummy/Hidden debuff that triggers stack collapse
propagate_const<buff_t*> wither; // Dummy debuff to show Wither dot info (stacks, uptime, ...) in the final report
} debuffs;
struct dots_t
{
// Cross-spec
propagate_const<dot_t*> drain_life;
propagate_const<dot_t*> corruption;
// Aff
propagate_const<dot_t*> agony;
propagate_const<dot_t*> seed_of_corruption;
propagate_const<dot_t*> drain_soul;
propagate_const<dot_t*> unstable_affliction;
propagate_const<dot_t*> malefic_grasp;
// Destro
propagate_const<dot_t*> immolate;
// Hellcaller
propagate_const<dot_t*> wither;
// Soul Harvester
propagate_const<dot_t*> soul_anathema;
propagate_const<dot_t*> shared_fate;
} dots;
double soc_threshold; // Aff - Seed of Corruption counts damage from cross-spec spells such as Drain Life
warlock_t& warlock;
warlock_td_t( player_t* target, warlock_t& p );
void reset()
{ soc_threshold = 0; }
void target_demise();
int count_affliction_dots() const;
};
// Shuffled Bag RNG (sampling without replacement)
// Each draw removes an item until the bag is exhausted, then it automatically resets
template <typename T>
struct shuffled_bag_rng_t
{
private:
player_t* player;
std::vector<T> bag;
int remaining;
public:
shuffled_bag_rng_t( std::vector<T> items, player_t* p )
: player( p ), bag( std::move( items ) ), remaining( as<int>( bag.size() ) )
{ assert( !bag.empty() ); }
shuffled_bag_rng_t( std::initializer_list<T> items, player_t* p )
: shuffled_bag_rng_t( std::vector<T>( items ), p )
{}
void reset()
{ remaining = as<int>( bag.size() ); }
T draw()
{
if ( remaining == 0 )
reset();
const int index = player->rng().range( 0, remaining );
const T item = bag[ index ];
std::swap( bag[ index ], bag[ remaining - 1 ] );
remaining--;
return item;
}
int num_remaining() const
{ return remaining; }
int size() const
{ return as<int>( bag.size() ); }
};
// Fixed-cycle proc helper
// Advances a counter on each call and triggers every Nth event
struct fixed_cycle_proc_t : public proc_rng_t
{
private:
using proc_reset_counter_fn = std::function<unsigned( unsigned )>;
proc_reset_counter_fn proc_reset_fn;
unsigned counter;
unsigned trigger_count;
bool random_initial_state;
public:
static constexpr rng_type_e rng_type = RNG_CUSTOM;
fixed_cycle_proc_t( std::string_view n, player_t* p, unsigned trigger_count_,
bool random_initial_state_ = false, proc_reset_counter_fn proc_reset_fn_ = nullptr )
: proc_rng_t( rng_type, n, p ),
proc_reset_fn( proc_reset_fn_ ),
counter( 0u ),
trigger_count( trigger_count_ ),
random_initial_state( random_initial_state_ )
{ assert( trigger_count > 0u ); }
void reset( reset_type_e reset_type ) override
{
switch ( reset_type )
{
case reset_type_e::COMBAT:
counter = proc_reset_fn ? proc_reset_fn( trigger_count ) : 0u;
assert( counter < trigger_count );
break;
case reset_type_e::ITERATION:
counter = random_initial_state ? player->rng().range( 0u, trigger_count ) : 0u;
break;
default:
assert( false && "Unhandled reset_type_e value" );
}
}
int trigger( action_state_t* = nullptr ) override
{
counter++;
if ( player->sim->debug )
player->sim->print_debug( "Fixed Cycle Proc: {}, current_count={} trigger_count={}, proc={}", name(), counter,
trigger_count, counter >= trigger_count );
if ( counter >= trigger_count )
{
reset( reset_type_e::COMBAT );
return true;
}
return false;
}
unsigned get_counter() const
{ return counter; }
unsigned get_trigger_count() const
{ return trigger_count; }
void set_counter( unsigned v )
{
assert( v < trigger_count );
counter = v;
}
};
// utility to create target_effect_t compatible functions from warlock_td_t member references
template <typename T>
static std::function<int( actor_target_data_t* )> d_fn( T d, bool stack = true )
{
if constexpr ( std::is_invocable_v<T, warlock_td_t::debuffs_t> )
{
if ( stack )
return [ d ]( actor_target_data_t* t ) {
return std::invoke( d, static_cast< warlock_td_t*>( t )->debuffs )->check();
};
else
return [ d ]( actor_target_data_t* t ) {
return std::invoke( d, static_cast< warlock_td_t*>( t )->debuffs )->check() > 0;
};
}
else if constexpr ( std::is_invocable_v<T, warlock_td_t::dots_t> )
{
if ( stack )
return [ d ]( actor_target_data_t* t ) {
return std::invoke( d, static_cast< warlock_td_t*>( t )->dots )->current_stack();
};
else
return [ d ]( actor_target_data_t* t ) {
return std::invoke( d, static_cast< warlock_td_t*>( t )->dots )->is_ticking();
};
}
else
{
static_assert( static_false<T>, "Not a valid member of warlock_td_t" );
return nullptr;
}
}
struct warlock_t : public parse_player_effects_t
{
public:
player_t* havoc_target;
bool bugged_mayhem; // Used to control if in a particular moment mayhem is bugged and its not working
std::vector<action_t*> havoc_spells; // Used for smarter target cache invalidation.
player_t* haunt_target; // Used for tracking the current haunt target
std::vector<event_t*> wild_imp_spawns; // Used for tracking incoming imps from HoG TODO: Is this still needed with faster spawns?
int diabolic_ritual; // Used to cycle between the three different Diabolic Ritual buffs
bool demonic_art_buff_replaced; // Used to not spawn the Demonic Art demon if the buff is replaced by another
unsigned n_active_pets;
// This should hold any spell data that is guaranteed in the base class or spec, without talents or other external systems required
struct base_t
{
// Shared
const spell_data_t* nethermancy; // Int bonus for all cloth slots
const spell_data_t* drain_life;
const spell_data_t* corruption;
const spell_data_t* shadow_bolt;
// Affliction
const spell_data_t* affliction_warlock; // Spec aura
const spell_data_t* potent_afflictions; // Affliction Mastery - Increased DoT and Malefic Rapture damage
// Demonology
const spell_data_t* demonology_warlock; // Spec aura
const spell_data_t* master_demonologist; // Demonology Mastery - Increased demon damage
const spell_data_t* wild_imp; // Data for pet summoning (HoG)
const spell_data_t* wild_imp_2; // Data for pet summoning (Inner Demons / Spiteful Reconstitution / To Hell and Back)
const spell_data_t* fel_firebolt_2; // Still a separate spell (learned automatically). Reduces pet's energy cost
// Destruction
const spell_data_t* destruction_warlock; // Spec aura
const spell_data_t* chaotic_energies; // Destruction Mastery - Increased spell damage with random range
const spell_data_t* immolate; // Replaces Corruption
const spell_data_t* immolate_old; // For some reason, the spellbook spell is now a new spell, but it points to this old one
const spell_data_t* immolate_dot; // Primary spell data only contains information on direct damage
const spell_data_t* incinerate; // Replaces Shadow Bolt
const spell_data_t* incinerate_energize; // Soul Shard data is in a separate spell
} warlock_base;
// Main pet held in active, guardians should be handled by pet spawners.
struct pets_t
{
warlock_pet_t* active;
spawner::pet_spawner_t<pets::destruction::infernal_t, warlock_t> infernals;
spawner::pet_spawner_t<pets::affliction::darkglare_t, warlock_t> darkglares;
spawner::pet_spawner_t<pets::demonology::dreadstalker_t, warlock_t> dreadstalkers;
spawner::pet_spawner_t<pets::demonology::vilefiend_t, warlock_t> vilefiends;
spawner::pet_spawner_t<pets::demonology::demonic_tyrant_t, warlock_t> demonic_tyrants;
spawner::pet_spawner_t<pets::demonology::grimoire_imp_lord_t, warlock_t> grimoire_imp_lords;
spawner::pet_spawner_t<pets::demonology::grimoire_fel_ravager_t, warlock_t> grimoire_fel_ravagers;
spawner::pet_spawner_t<pets::demonology::wild_imp_pet_t, warlock_t> wild_imps;
spawner::pet_spawner_t<pets::demonology::doomguard_t, warlock_t> doomguards;
spawner::pet_spawner_t<pets::demonology::lady_sacrolash_t, warlock_t> lady_sacrolash;
spawner::pet_spawner_t<pets::demonology::grand_warlock_alythess_t, warlock_t> grand_warlock_alythess;
spawner::pet_spawner_t<pets::demonology::antoran_inquisitor_t, warlock_t> antoran_inquisitor;
spawner::pet_spawner_t<pets::demonology::antoran_jailer_t, warlock_t> antoran_jailer;
spawner::pet_spawner_t<pets::destruction::shadowy_tear_t, warlock_t> shadow_rifts;
spawner::pet_spawner_t<pets::destruction::unstable_tear_t, warlock_t> unstable_rifts;
spawner::pet_spawner_t<pets::destruction::chaos_tear_t, warlock_t> chaos_rifts;
spawner::pet_spawner_t<pets::destruction::infernal_roc_t, warlock_t> rocs;
spawner::pet_spawner_t<pets::destruction::overfiend_t, warlock_t> overfiends;
spawner::pet_spawner_t<pets::diabolist::overlord_t, warlock_t> overlords;
spawner::pet_spawner_t<pets::diabolist::mother_of_chaos_t, warlock_t> mothers;
spawner::pet_spawner_t<pets::diabolist::pit_lord_t, warlock_t> pit_lords;
spawner::pet_spawner_t<pets::diabolist::infernal_fragment_t, warlock_t> fragments;
spawner::pet_spawner_t<pets::diabolist::diabolic_imp_t, warlock_t> diabolic_imps;
spawner::pet_spawner_t<pets::soul_harvester::rampaging_demonic_soul_t, warlock_t> demonic_souls;
pets_t( warlock_t* w );
} warlock_pet_list;
std::vector<std::string> pet_name_list;
// Talents
struct talents_t
{
// Class Tree
player_talent_t demonic_embrace;
player_talent_t demonic_fortitude;
player_talent_t pact_of_the_annihilan;
player_talent_t pact_of_the_satyr;
player_talent_t pact_of_the_eredar;
player_talent_t soulburn;
const spell_data_t* soulburn_buff; // This buff is applied after using Soulburn and prevents another usage unless cleared
// Specializations
// Shared
player_talent_t summoners_embrace;
player_talent_t grimoire_of_sacrifice; // Aff/Destro only
const spell_data_t* grimoire_of_sacrifice_buff; // 1 hour duration, enables proc functionality, canceled if pet summoned
const spell_data_t* grimoire_of_sacrifice_proc; // Damage data is here, but RPPM of proc trigger is in buff data
// Affliction
const spell_data_t* agony;
player_talent_t unstable_affliction;
const spell_data_t* unstable_affliction_2; // Soul Shard on demise (learned automatically)
player_talent_t seed_of_corruption;
const spell_data_t* seed_of_corruption_aoe; // Explosion damage when Seed ticks
const spell_data_t* seed_of_corruption_is_out_dnt;
player_talent_t nightfall;
const spell_data_t* nightfall_buff;
const spell_data_t* nightfall_buff_2;
player_talent_t haunt;
player_talent_t shared_agony;
player_talent_t improved_shadow_bolt;
player_talent_t drain_soul; // This represents the talent node but not much else
const spell_data_t* drain_soul_dot; // Contains all channel data
player_talent_t improved_haunt;
player_talent_t absolute_corruption;
player_talent_t siphon_life;
player_talent_t cunning_cruelty; // Note: Damage formula in the tooltip indicates this is affected by Imp. Shadow Bolt and Sargerei Technique
const spell_data_t* shadowbolt_volley; // Proc chance is not listed on spell data. Appears to be 50% regardless of talent. Last checked 2024-07-07
player_talent_t withering_bolt; // Increased damage on Shadow Bolt/Drain Soul based on active DoT count on target
player_talent_t creeping_death;
player_talent_t dark_harvest; // Buffs from hitting targets with Soul Rot
const spell_data_t* dark_harvest_dmg;
player_talent_t practiced_pestilence;
player_talent_t summon_darkglare;
const spell_data_t* eye_beam; // Darkglare pet ability
const spell_data_t* darkglare_presence_buff; // DoT +% dmg buff
// Summoner's Embrace (shared with Destruction)
// Grimoire of Sacrifice (shared with Destruction)
player_talent_t cull_the_weak;
player_talent_t malediction;
player_talent_t sudden_onset;
player_talent_t eye_contract;
player_talent_t malefic_grasp;
const spell_data_t* malefic_grasp_2;
const spell_data_t* malefic_grasp_3;
const spell_data_t* agony_mg;
const spell_data_t* unstable_affliction_mg;
const spell_data_t* corruption_mg;
const spell_data_t* wither_mg;
player_talent_t nether_plating;
player_talent_t sacrolashs_dark_strike; // Increased Corruption ticking damage, and ticks extend Curses (not implemented)
player_talent_t contagion;
player_talent_t shard_instability;
const spell_data_t* shard_instability_buff;
player_talent_t niskaran_methods;
player_talent_t potent_soul_shards;
player_talent_t nocturnal_yield;
player_talent_t xavius_gambit; // Unstable Affliction Damage Multiplier
player_talent_t ravenous_afflictions;
player_talent_t seeds_of_destruction;
player_talent_t fatal_echoes;
player_talent_t cascading_calamity;
const spell_data_t* cascading_calamity_buff;
player_talent_t deaths_embrace; // Volatile Agony and Perpetual Unstability are unaffected by this
player_talent_t patient_zero;
player_talent_t sow_the_seeds;
// Affliction Apex
player_talent_t shadow_of_nathreza_1;
player_talent_t shadow_of_nathreza_2;
player_talent_t shadow_of_nathreza_3;
const spell_data_t* shadow_of_nathreza_dot;
const spell_data_t* wrath_of_nathreza; // Trigger missile spell
const spell_data_t* wrath_of_nathreza_impact;
// Demonology
player_talent_t hand_of_guldan;
const spell_data_t* hand_of_guldan_cast;
const spell_data_t* hog_impact; // Secondary spell responsible for impact damage
player_talent_t demoniac;
const spell_data_t* demonbolt_spell;
const spell_data_t* demonic_core_spell;
const spell_data_t* demonic_core_buff;
player_talent_t call_dreadstalkers;
const spell_data_t* call_dreadstalkers_2; // Contains duration data
player_talent_t dominant_hand;
player_talent_t fel_intellect;
player_talent_t practiced_rituals;
player_talent_t dreadlash;
player_talent_t imperator; // Increased critical strike chance for Wild Imps' Fel Firebolt (additive)
player_talent_t implosion;
const spell_data_t* implosion_aoe; // Note: in combat logs this is attributed to the player, not the imploding pet
player_talent_t power_siphon;
const spell_data_t* power_siphon_buff; // Semi-hidden aura that controls the bonus Demonbolt damage
player_talent_t summon_felguard;
player_talent_t infernal_rapidity;
player_talent_t rune_of_shadows;
player_talent_t carnivorous_stalkers; // Chance for Dreadstalkers to perform additional Dreadbites
player_talent_t fel_armaments;
const spell_data_t* fel_armaments_2; // Another effect of Fel Armaments that, due to a bug, is always active
player_talent_t imp_gang_boss;
const spell_data_t* imp_gang_boss_buff; // Buff on Wild Imps
player_talent_t demonic_brutality;
player_talent_t inner_demons;
player_talent_t summon_demonic_tyrant;
const spell_data_t* demonic_power_buff;
player_talent_t blighted_maw;
const spell_data_t* blighted_maw_dmg;
player_talent_t improved_demonic_tactics;
player_talent_t empowered_felstorm;
player_talent_t spiteful_reconstitution; // Increased Implosion damage and consuming Demonic Core may spawn a Wild Imp
player_talent_t tyrants_oblation;
const spell_data_t* tyrants_oblation_buff;
player_talent_t antoran_armaments;
player_talent_t flametouched;
const spell_data_t* ferocity_of_fharg_buff;
player_talent_t demonic_knowledge;
player_talent_t sacrificed_souls;
player_talent_t reign_of_tyranny;
player_talent_t master_summoner;
player_talent_t demonic_calling;
player_talent_t doom;
const spell_data_t* doom_debuff;
const spell_data_t* doom_dmg;
player_talent_t hellbent_commander;
const spell_data_t* hellbent_commander_buff;
player_talent_t grimoire_imp_lord;
player_talent_t grimoire_fel_ravager;
const spell_data_t* grimoire_of_service_buff;
player_talent_t summon_vilefiend;
const spell_data_t* vilefiend;
const spell_data_t* gloomhound;
const spell_data_t* charhound;
const spell_data_t* bile_spit;
const spell_data_t* headbutt;
player_talent_t summon_doomguard;
const spell_data_t* doom_bolt_volley;
player_talent_t to_hell_and_back;
const spell_data_t* unstable_soul_buff;
player_talent_t stabilized_portals;
player_talent_t mark_of_shatug;
const spell_data_t* gloom_slash;
player_talent_t mark_of_fharg;
const spell_data_t* infernal_presence;
const spell_data_t* infernal_presence_dmg;
// Demo Apex Talents
player_talent_t dominion_of_argus_1;
player_talent_t dominion_of_argus_2;
player_talent_t dominion_of_argus_3;
const spell_data_t* dominion_of_argus_1_buff;
const spell_data_t* dominion_of_argus_3_gain;
const spell_data_t* doa_lady_sacrolash_summon;
const spell_data_t* doa_grand_warlock_alythess_summon;
const spell_data_t* doa_antoran_inquisitor_summon;
const spell_data_t* doa_antoran_jailer_summon;
// Destruction
player_talent_t chaos_bolt;
player_talent_t conflagrate; // Base 2 charges
const spell_data_t* conflagrate_2; // Energize data
player_talent_t rain_of_fire;
const spell_data_t* rain_of_fire_tick;
player_talent_t improved_conflagrate; // +1 charge for Conflagrate
player_talent_t backdraft;
const spell_data_t* backdraft_buff;
player_talent_t practiced_chaos;
player_talent_t roaring_blaze;
player_talent_t explosive_potential; // Reduces base Conflagrate cooldown by 2 seconds
player_talent_t mayhem; // It appears that the only spells that can proc Mayhem are ones that can be Havoc'd
player_talent_t havoc; // Talent data for Havoc is both the debuff and the action
const spell_data_t* havoc_debuff; // This is a second copy of the talent data for use in places that are shared by Havoc and Mayhem
player_talent_t scalding_flames; // Increased Immolate damage and duration
player_talent_t shadowburn;
const spell_data_t* shadowburn_2; // Contains Soul Shard energize data
player_talent_t backlash; // Crit chance increase. NOT IMPLEMENTED: Instant Incinerate proc when physically attacked
player_talent_t improved_havoc;
player_talent_t ashen_remains; // Increased Chaos Bolt and Incinerate damage to targets afflicted by Immolate
player_talent_t cataclysm;
player_talent_t fiendish_cruelty;
const spell_data_t* fiendish_cruelty_buff;
player_talent_t chaotic_inferno;
const spell_data_t* chaotic_inferno_buff;
player_talent_t flashpoint; // Stacking haste buff from Immolate ticks on high-health targets
const spell_data_t* flashpoint_buff;
player_talent_t summon_infernal;
const spell_data_t* summon_infernal_main; // Data for main infernal summoning
const spell_data_t* infernal_awakening; // AoE on impact is attributed to the Warlock
const spell_data_t* immolation_buff; // Buff on Infernal pet
const spell_data_t* immolation_dmg; // Ticking AoE damage from buff
const spell_data_t* embers; // Buff which generates Soul Shards
const spell_data_t* burning_ember; // Energize data for Soul Shards
player_talent_t emberstorm;
player_talent_t fire_and_brimstone;
player_talent_t lake_of_fire;
const spell_data_t* lake_of_fire_aoe;
const spell_data_t* lake_of_fire_tick;
const spell_data_t* lake_of_fire_debuff;
player_talent_t reverse_entropy;
const spell_data_t* reverse_entropy_buff;
player_talent_t internal_combustion;
const spell_data_t* internal_combustion_dmg;
player_talent_t crashing_chaos; // Summon Infernal increases the damage of next 8 Chaos Bolt or Rain of Fire casts
const spell_data_t* crashing_chaos_buff;
player_talent_t rain_of_chaos;
const spell_data_t* rain_of_chaos_buff;
const spell_data_t* summon_infernal_roc; // Contains Rain of Chaos infernal duration
// Summoner's Embrace (shared with Affliction)
// Grimoire of Sacrifice (shared with Affliction)
player_talent_t ruin; // Damage increase to several spells
player_talent_t improved_chaos_bolt;
player_talent_t destructive_rapidity;
player_talent_t devastation;
player_talent_t dimensional_rift;
const spell_data_t* shadowy_tear_summon; // This only creates the "pet"
const spell_data_t* shadow_barrage; // Casts Rift version of Shadow Bolt on ticks
const spell_data_t* rift_shadow_bolt; // Separate ID from Warlock's Shadow Bolt
const spell_data_t* unstable_tear_summon; // This only creates the "pet"
const spell_data_t* chaos_barrage; // Triggers ticks of Chaos Barrage bolts
const spell_data_t* chaos_barrage_tick;
const spell_data_t* chaos_tear_summon; // This only creates the "pet"
const spell_data_t* rift_chaos_bolt; // Separate ID from Warlock's Chaos Bolt
player_talent_t soul_fire;
const spell_data_t* soul_fire_2; // Contains Soul Shard energize data
player_talent_t inferno;
player_talent_t conflagration_of_chaos; // Conflagrate/Shadowburn has chance to make next cast of it a guaranteed crit
const spell_data_t* conflagration_of_chaos_cf; // Player buff which affects next Conflagrate
const spell_data_t* conflagration_of_chaos_sb; // Player buff which affects next Shadowburn
player_talent_t diabolic_embers; // Incinerate generates more Soul Shards
player_talent_t demonfire_infusion;
player_talent_t channel_demonfire;
const spell_data_t* channel_demonfire_tick;
const spell_data_t* channel_demonfire_travel; // Only holds travel speed
player_talent_t avatar_of_destruction;
const spell_data_t* summon_overfiend;
const spell_data_t* overfiend_buff; // Buff on Warlock while Overfiend is out, generates Soul Shards
const spell_data_t* overfiend_cb; // Chaos Bolt cast by Overfiend
player_talent_t chaos_incarnate; // Greater mastery value for some spells
player_talent_t alythesss_ire;
const spell_data_t* alythesss_ire_buff;
player_talent_t raging_demonfire;
player_talent_t embers_of_nihilam_1;
player_talent_t embers_of_nihilam_2;
player_talent_t embers_of_nihilam_3;
const spell_data_t* echo_of_sargeras; // Damage spell (1265884)
const spell_data_t* vision_of_nihilam; // Crit/Haste buff (1265939)
} talents;
struct hero_talents_t
{
// Diabolist
player_talent_t diabolic_ritual;
const spell_data_t* ritual_overlord; // Diabolic Ritual: X buffs
const spell_data_t* ritual_mother;
const spell_data_t* ritual_pit_lord;
const spell_data_t* art_overlord; // Demonic Art: X buffs
const spell_data_t* art_mother;
const spell_data_t* art_pit_lord;
const spell_data_t* summon_overlord;
const spell_data_t* summon_mother;
const spell_data_t* summon_pit_lord;
const spell_data_t* wicked_cleave; // Overlord
const spell_data_t* chaos_salvo; // Mother of Chaos
const spell_data_t* chaos_salvo_missile;
const spell_data_t* chaos_salvo_dmg;
const spell_data_t* felseeker; // Pit Lord
const spell_data_t* felseeker_dmg;
player_talent_t cloven_souls;
const spell_data_t* cloven_soul_debuff;
player_talent_t touch_of_rancora;
player_talent_t secrets_of_the_coven;
const spell_data_t* infernal_bolt;
const spell_data_t* infernal_bolt_buff;
player_talent_t cruelty_of_kerxan;
player_talent_t infernal_machine;
player_talent_t flames_of_xoroth;
player_talent_t abyssal_dominion;
const spell_data_t* abyssal_dominion_buff;
const spell_data_t* infernal_fragmentation; // TODO: Re-check damage of Infernal Fragments
player_talent_t gloom_of_nathreza;
player_talent_t ruination; // TODO: Check damage and buff values closer to release, affected_by lists may be on cast spell not damage in data and could be changed later by Blizzard
const spell_data_t* ruination_buff;
const spell_data_t* ruination_cast;
const spell_data_t* ruination_impact;
const spell_data_t* diabolic_imp;
const spell_data_t* diabolic_bolt;
player_talent_t diabolic_oculi;
const spell_data_t* demonic_oculi_buff;
const spell_data_t* eye_explosion;
player_talent_t looks_that_kill;
const spell_data_t* diabolic_gaze_dmg_1;
const spell_data_t* diabolic_gaze_dmg_2;
const spell_data_t* diabolic_gaze_dmg_3;
player_talent_t minds_eyes;
const spell_data_t* minds_eyes_buff;
// Hellcaller
player_talent_t wither;
const spell_data_t* wither_direct; // TODO: Damage values are picking up some other weird effects similar to Flames of Xoroth. Check damage again after main implementation work is done
const spell_data_t* wither_dot;
player_talent_t xalans_ferocity;
player_talent_t blackened_soul;
const spell_data_t* blackened_soul_trigger; // Contains interval for stack collapse
const spell_data_t* blackened_soul_dmg;
player_talent_t xalans_cruelty;
player_talent_t hatefury_rituals;
player_talent_t bleakheart_tactics;
player_talent_t illhoofs_design;
player_talent_t mark_of_xavius;
player_talent_t seeds_of_their_demise;
player_talent_t mark_of_perotharn;
player_talent_t through_the_felvine;
player_talent_t devil_fruit;
player_talent_t alzzins_iniquity;
player_talent_t malevolence;
const spell_data_t* malevolence_buff;
const spell_data_t* malevolence_dmg;
// Soul Harvester
player_talent_t demonic_soul;
const spell_data_t* succulent_soul; // Buff triggered by Demonic Soul proc
const spell_data_t* demonic_soul_dmg;
player_talent_t necrolyte_teachings;
player_talent_t soul_anathema;
const spell_data_t* soul_anathema_dot;
player_talent_t demoniacs_fervor;
player_talent_t shared_fate;
const spell_data_t* shared_fate_dot;
player_talent_t feast_of_souls;
player_talent_t wicked_reaping;
const spell_data_t* wicked_reaping_dmg;
player_talent_t quietus;
player_talent_t sataiels_volition;
player_talent_t shadow_of_death;
const spell_data_t* shadow_of_death_energize;
player_talent_t manifested_avarice;
const spell_data_t* manifested_avarice_spell;
player_talent_t shared_vessel;
player_talent_t eternal_hunger;
} hero;
struct proc_actions_t
{
action_t* doom_proc;
action_t* rain_of_fire_tick;
action_t* lake_of_fire_tick;
action_t* blackened_soul;
action_t* malevolence;
action_t* demonic_soul;
action_t* shared_fate;
action_t* wicked_reaping;
action_t* dimensional_rift;
action_t* demonfire_infusion;
action_t* eye_explosion;
action_t* diabolic_gaze_1;
action_t* diabolic_gaze_2;
action_t* diabolic_gaze_3;
action_t* diabolic_oculi;
action_t* blighted_maw;
action_t* echo_of_sargeras;
action_t* echo_of_sargeras_cb;
action_t* echo_of_sargeras_sb;
action_t* echo_of_sargeras_rof;
action_t* embers_of_nihilam;
action_t* shadow_of_nathreza;
action_t* wrath_of_nathreza;
} proc_actions;
struct pet_summons_t
{
propagate_const<action_t*> lady_sacrolash;
propagate_const<action_t*> grand_warlock_alythess;
propagate_const<action_t*> antoran_inquisitor;
propagate_const<action_t*> antoran_jailer;
} summon;
struct tier_sets_t
{
const spell_data_t* wl_affliction_12_0_class_set_2pc;
const spell_data_t* wl_affliction_12_0_class_set_4pc;
const spell_data_t* wl_demonology_12_0_class_set_2pc;
const spell_data_t* wl_demonology_12_0_class_set_4pc;
const spell_data_t* wl_destruction_12_0_class_set_2pc;
const spell_data_t* wl_destruction_12_0_class_set_4pc;
} tier;
// Cooldowns - Used for accessing cooldowns outside of their respective actions, such as reductions/resets
struct cooldowns_t
{
propagate_const<cooldown_t*> haunt;
propagate_const<cooldown_t*> dark_harvest;
propagate_const<cooldown_t*> soul_fire;
propagate_const<cooldown_t*> summon_doomguard;
propagate_const<cooldown_t*> felstorm_icd;
propagate_const<cooldown_t*> echo_of_sargeras; // ICD for Embers of Nihilam rank 4 procs
propagate_const<cooldown_t*> blackened_soul; // Internal cooldown on triggering stack increase to Wither
propagate_const<cooldown_t*> seeds_of_their_demise; // Estimated internal cooldown, a guess at how Blizzard is minimizing lucky streaks
} cooldowns;
// Buffs
struct buffs_t
{
// Shared Buffs
propagate_const<buff_t*> grimoire_of_sacrifice; // Buff which grants damage proc
propagate_const<buff_t*> soulburn;
propagate_const<buff_t*> pet_movement; // One unified buff for some form of pet movement stat tracking
// Affliction Buffs
propagate_const<buff_t*> nightfall;
propagate_const<buff_t*> darkglare_presence;
propagate_const<buff_t*> shard_instability;
propagate_const<buff_t*> cascading_calamity;
propagate_const<buff_t*> seed_of_corruption_is_out_dnt;
// Demonology Buffs
propagate_const<buff_t*> demonic_core;
propagate_const<buff_t*> power_siphon; // Hidden buff from Power Siphon that increases damage of successive Demonbolts
propagate_const<buff_t*> inner_demons;
propagate_const<buff_t*> tyrants_oblation;
propagate_const<buff_t*> hellbent_commander;
propagate_const<buff_t*> wild_imps; // Buff for tracking how many Wild Imps are currently out (does NOT include imps waiting to be spawned)
propagate_const<buff_t*> dreadstalkers; // Buff for tracking number of Dreadstalkers currently out
propagate_const<buff_t*> vilefiend; // Buff for tracking number of Vilefiends currently out
propagate_const<buff_t*> grimoire_imp_lord;
propagate_const<buff_t*> grimoire_fel_ravager;
propagate_const<buff_t*> doomguard;
propagate_const<buff_t*> tyrant; // Buff for tracking if Demonic Tyrant is currently out
propagate_const<buff_t*> dominion_of_argus;
// Destruction Buffs
propagate_const<buff_t*> backdraft;
propagate_const<buff_t*> reverse_entropy;
propagate_const<buff_t*> fiendish_cruelty;
propagate_const<buff_t*> chaotic_inferno;
propagate_const<buff_t*> rain_of_chaos;
propagate_const<buff_t*> conflagration_of_chaos_cf;
propagate_const<buff_t*> conflagration_of_chaos_sb;
propagate_const<buff_t*> flashpoint;
propagate_const<buff_t*> crashing_chaos;
propagate_const<buff_t*> alythesss_ire;
propagate_const<buff_t*> summon_overfiend;
propagate_const<buff_t*> vision_of_nihilam;
// Diabolist Buffs
propagate_const<buff_t*> ritual_overlord;
propagate_const<buff_t*> ritual_mother;
propagate_const<buff_t*> ritual_pit_lord;
propagate_const<buff_t*> art_overlord;
propagate_const<buff_t*> art_mother;
propagate_const<buff_t*> art_pit_lord;
propagate_const<buff_t*> infernal_bolt;
propagate_const<buff_t*> abyssal_dominion;
propagate_const<buff_t*> ruination;
propagate_const<buff_t*> demonic_oculi;
propagate_const<buff_t*> minds_eyes;
// Hellcaller Buffs
propagate_const<buff_t*> malevolence;
// Soul Harvester Buffs
propagate_const<buff_t*> succulent_soul;
propagate_const<buff_t*> manifested_demonic_soul;
} buffs;
// Gains - Many are automatically handled
struct gains_t
{
// Class Talents
// Affliction
gain_t* agony;
gain_t* drain_soul;
gain_t* unstable_affliction_refund;
// Demonology
gain_t* soul_strike; // Only with Fel Invocation talent
// Destruction
gain_t* incinerate_crits;
gain_t* immolate;
gain_t* immolate_crits;
gain_t* infernal;
gain_t* shadowburn_refund;
gain_t* summon_overfiend;
gain_t* dominion_of_argus;
// Diabolist
// Hellcaller
gain_t* wither;
gain_t* wither_crits;
// Soul Harvester
gain_t* feast_of_souls;
gain_t* shadow_of_death;
} gains;
// Procs
struct procs_t
{
// Class Talents
// Affliction
proc_t* nightfall;
proc_t* shadowbolt_volley;
proc_t* ravenous_afflictions;
proc_t* shard_instability;
proc_t* fatal_echoes;
proc_t* wrath_of_nathreza;
// Demonology
proc_t* demonic_core_dogs;
proc_t* demonic_core_imps;
proc_t* carnivorous_stalkers;
proc_t* infernal_rapidity;
proc_t* spiteful_reconstitution;
proc_t* demonic_knowledge;
// Destruction
proc_t* reverse_entropy;
proc_t* rain_of_chaos;
proc_t* mayhem;
proc_t* fiendish_cruelty;
proc_t* chaotic_inferno;
proc_t* dimensional_rift;
proc_t* avatar_of_destruction;
proc_t* conflagration_of_chaos_cf;
proc_t* conflagration_of_chaos_sb;
proc_t* demonfire_infusion_inc;
proc_t* demonfire_infusion_dot;
proc_t* alythesss_ire;
proc_t* echo_of_sargeras;
proc_t* echo_of_sargeras_cb;
proc_t* echo_of_sargeras_sb;
proc_t* echo_of_sargeras_rof;
// Diabolist
// Hellcaller
proc_t* blackened_soul;
proc_t* bleakheart_tactics;
proc_t* seeds_of_their_demise;
proc_t* mark_of_perotharn;
proc_t* devil_fruit;
// Soul Harvester
proc_t* succulent_soul;
proc_t* feast_of_souls;
proc_t* manifested_avarice;
} procs;
struct cycle_proc_t
{
fixed_cycle_proc_t* alythesss_ire;
} cycle_proc;
struct deck_rng_t
{
shuffled_rng_t* rain_of_chaos;
shuffled_rng_t* demonic_knowledge;
std::unique_ptr<shuffled_bag_rng_t<dimensional_rift_pet_e>> dimensional_rift_summon;
} deck_rng;
struct rppm_rng_t
{
real_ppm_t* ravenous_afflictions;
real_ppm_t* wrath_of_nathreza;
real_ppm_t* devil_fruit;
} rppm_rng;
struct progress_rng_t
{
threshold_rng_t* agony_energize;
threshold_rng_t* nightfall;
} progress_rng;
struct prd_rng_t
{
accumulated_rng_t* cunning_cruelty;
accumulated_rng_t* shard_instability_ds;
accumulated_rng_t* shard_instability_sb;
accumulated_rng_t* fatal_echoes;
accumulated_rng_t* fiendish_cruelty;
accumulated_rng_t* chaotic_inferno;
accumulated_rng_t* dimensional_rift;
accumulated_rng_t* echo_of_sargeras;
accumulated_rng_t* succulent_soul;
accumulated_rng_t* manifested_avarice;
accumulated_rng_t* feast_of_souls;
accumulated_rng_t* spiteful_reconstitution;
} prd_rng;
struct flat_rng_t
{
simple_proc_t* immolate_crit_energize; // TODO: Need to check the type of rng
simple_proc_t* carnivorous_stalkers;
simple_proc_t* infernal_rapidity;
simple_proc_t* demonfire_infusion_dot; // TODO: Need to check the type of rng
simple_proc_t* demonfire_infusion_inc; // TODO: Need to check the type of rng
simple_proc_t* alythesss_ire_shift;
simple_proc_t* wither_crit_energize; // TODO: Need to check the type of rng
simple_proc_t* blackened_soul; // TODO: Need to check the type of rng and chance value
simple_proc_t* bleakheart_tactics; // TODO: Need to check the type of rng and chance value
simple_proc_t* seeds_of_their_demise; // TODO: Need to check the type of rng and chance value
simple_proc_t* mark_of_perotharn; // TODO: Need to check the type of rng and chance value
} flat_rng;
// TODO: Need to check that these RNG values are still correct in Midnight
struct rng_settings_t
{