TrinityCore
Loading...
Searching...
No Matches
spell_warlock.cpp
Go to the documentation of this file.
1/*
2 * This file is part of the TrinityCore Project. See AUTHORS file for Copyright information
3 *
4 * This program is free software; you can redistribute it and/or modify it
5 * under the terms of the GNU General Public License as published by the
6 * Free Software Foundation; either version 2 of the License, or (at your
7 * option) any later version.
8 *
9 * This program is distributed in the hope that it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
12 * more details.
13 *
14 * You should have received a copy of the GNU General Public License along
15 * with this program. If not, see <http://www.gnu.org/licenses/>.
16 */
17
18/*
19 * Scripts for spells with SPELLFAMILY_WARLOCK and SPELLFAMILY_GENERIC spells used by warlock players.
20 * Ordered alphabetically using scriptname.
21 * Scriptnames of files in this file should be prefixed with "spell_warl_".
22 */
23
24#include "ScriptMgr.h"
25#include "Creature.h"
26#include "GameObject.h"
27#include "Log.h"
28#include "ObjectMgr.h"
29#include "Optional.h"
30#include "Player.h"
31#include "Random.h"
32#include "SpellAuraEffects.h"
33#include "SpellMgr.h"
34#include "SpellScript.h"
35
37{
98};
99
106
107// -980 - Curse of Agony
109{
111
112 void ApplyEffect(AuraEffect const* aurEff, AuraEffectHandleModes /*mode*/)
113 {
114 _tick_amount = aurEff->GetAmount();
115 }
116
118 {
119 switch (aurEff->GetTickNumber())
120 {
121 // 1..4 ticks, 1/2 from normal tick damage
122 case 1:
123 aurEff->SetAmount(_tick_amount / 2);
124 break;
125 // 5..8 ticks have normal tick damage
126 case 5:
127 aurEff->SetAmount(_tick_amount);
128 break;
129 // 9..12 ticks, 3/2 from normal tick damage
130 case 9:
131 aurEff->SetAmount((_tick_amount + 1) * 3 / 2); // +1 prevent 0.5 damage possible lost at 1..4 ticks
132 break;
133 // 13 and 14 ticks (glyphed only), twice normal tick damage
134 case 13:
135 aurEff->SetAmount(_tick_amount * 2);
136 break;
137 }
138 }
139
145private:
147};
148
149// -710 - Banish
151{
153
154public:
156
157private:
159 {
160 if (missInfo != SPELL_MISS_IMMUNE)
161 return;
162
163 if (Unit* target = GetHitUnit())
164 {
165 // Casting Banish on a banished target will remove applied aura
166 if (Aura * banishAura = target->GetAura(GetSpellInfo()->Id, GetCaster()->GetGUID()))
167 banishAura->Remove();
168 }
169 }
170
175};
176
177// -6201 - Create Healthstone (and ranks)
179{
180 public:
181 spell_warl_create_healthstone() : SpellScriptLoader("spell_warl_create_healthstone") { }
182
184 {
186
187 static uint32 const iTypes[8][3];
188
193
195 {
196 if (Player* caster = GetCaster()->ToPlayer())
197 {
198 uint8 spellRank = GetSpellInfo()->GetRank();
199 ItemPosCountVec dest;
200 InventoryResult msg = caster->CanStoreNewItem(NULL_BAG, NULL_SLOT, dest, iTypes[spellRank - 1][0], 1, nullptr);
201 if (msg != EQUIP_ERR_OK)
203 }
204 return SPELL_CAST_OK;
205 }
206
208 {
209 if (Unit* unitTarget = GetHitUnit())
210 {
211 uint32 rank = 0;
212 // Improved Healthstone
213 if (AuraEffect const* aurEff = unitTarget->GetDummyAuraEffect(SPELLFAMILY_WARLOCK, 284, 0))
214 {
215 switch (aurEff->GetId())
216 {
218 rank = 1;
219 break;
221 rank = 2;
222 break;
223 default:
224 TC_LOG_ERROR("spells", "Unknown rank of Improved Healthstone id: {}", aurEff->GetId());
225 break;
226 }
227 }
228 uint8 spellRank = GetSpellInfo()->GetRank();
229 if (spellRank > 0 && spellRank <= 8)
230 CreateItem(iTypes[spellRank - 1][rank]);
231 }
232 }
233
239 };
240
241 SpellScript* GetSpellScript() const override
242 {
244 }
245};
246
248 { 5512, 19004, 19005}, // Minor Healthstone
249 { 5511, 19006, 19007}, // Lesser Healthstone
250 { 5509, 19008, 19009}, // Healthstone
251 { 5510, 19010, 19011}, // Greater Healthstone
252 { 9421, 19012, 19013}, // Major Healthstone
253 {22103, 22104, 22105}, // Master Healthstone
254 {36889, 36890, 36891}, // Demonic Healthstone
255 {36892, 36893, 36894} // Fel Healthstone
256};
257
258// -603 - Curse of Doom
260{
262
263 bool Validate(SpellInfo const* /*spellInfo*/) override
264 {
266 }
267
268 bool Load() override
269 {
270 return GetCaster() && GetCaster()->GetTypeId() == TYPEID_PLAYER;
271 }
272
273 void OnRemove(AuraEffect const* aurEff, AuraEffectHandleModes /*mode*/)
274 {
275 if (!GetCaster())
276 return;
277
279 if (removeMode != AURA_REMOVE_BY_DEATH || !IsExpired())
280 return;
281
282 if (GetCaster()->ToPlayer()->isHonorOrXPTarget(GetTarget()))
284 }
285
290};
291
292// -63156 - Decimation
294{
296
297 bool CheckProc(ProcEventInfo& eventInfo)
298 {
299 if (SpellInfo const* spellInfo = eventInfo.GetSpellInfo())
300 if (eventInfo.GetActionTarget()->HasAuraState(AURA_STATE_HEALTHLESS_35_PERCENT, spellInfo, eventInfo.GetActor()))
301 return true;
302
303 return false;
304 }
305
310};
311
312// 48018 - Demonic Circle: Summon
314{
316
317 void HandleRemove(AuraEffect const* /*aurEff*/, AuraEffectHandleModes mode)
318 {
319 // If effect is removed by expire remove the summoned demonic circle too.
320 if (!(mode & AURA_EFFECT_HANDLE_REAPPLY))
321 GetTarget()->RemoveGameObject(GetId(), true);
322
324 }
325
326 void HandleDummyTick(AuraEffect const* /*aurEff*/)
327 {
328 if (GameObject* circle = GetTarget()->GetGameObject(GetId()))
329 {
330 // Here we check if player is in demonic circle teleport range, if so add
331 // WARLOCK_DEMONIC_CIRCLE_ALLOW_CAST; allowing him to cast the WARLOCK_DEMONIC_CIRCLE_TELEPORT.
332 // If not in range remove the WARLOCK_DEMONIC_CIRCLE_ALLOW_CAST.
333
334 SpellInfo const* spellInfo = sSpellMgr->AssertSpellInfo(SPELL_WARLOCK_DEMONIC_CIRCLE_TELEPORT);
335
336 if (GetTarget()->IsWithinDist(circle, spellInfo->GetMaxRange(true)))
337 {
340 }
341 else
343 }
344 }
345
351};
352
353// 48020 - Demonic Circle: Teleport
355{
357
358 void HandleTeleport(AuraEffect const* /*aurEff*/, AuraEffectHandleModes /*mode*/)
359 {
360 if (Player* player = GetTarget()->ToPlayer())
361 {
362 if (GameObject* circle = player->GetGameObject(SPELL_WARLOCK_DEMONIC_CIRCLE_SUMMON))
363 {
364 player->NearTeleportTo(circle->GetPositionX(), circle->GetPositionY(), circle->GetPositionZ(), circle->GetOrientation());
365 player->RemoveMovementImpairingAuras(false);
366 }
367 }
368 }
369
374};
375
376// 47193 - Demonic Empowerment
378{
380
392
394 {
395 if (Creature* targetCreature = GetHitCreature())
396 {
397 if (targetCreature->IsPet())
398 {
399 CreatureTemplate const* ci = targetCreature->GetCreatureTemplate();
400 switch (ci->family)
401 {
403 targetCreature->CastSpell(targetCreature, SPELL_WARLOCK_DEMONIC_EMPOWERMENT_SUCCUBUS, true);
404 break;
406 {
407 SpellInfo const* spellInfo = sSpellMgr->AssertSpellInfo(SPELL_WARLOCK_DEMONIC_EMPOWERMENT_VOIDWALKER);
408 int32 hp = targetCreature->CountPctFromMaxHealth(GetCaster()->CalculateSpellDamage(spellInfo->GetEffect(EFFECT_0)));
410 args.AddSpellBP0(hp);
411 targetCreature->CastSpell(targetCreature, SPELL_WARLOCK_DEMONIC_EMPOWERMENT_VOIDWALKER, args);
412 //unitTarget->CastSpell(unitTarget, 54441, true);
413 break;
414 }
416 targetCreature->CastSpell(targetCreature, SPELL_WARLOCK_DEMONIC_EMPOWERMENT_FELGUARD, true);
417 break;
419 targetCreature->CastSpell(targetCreature, SPELL_WARLOCK_DEMONIC_EMPOWERMENT_FELHUNTER, true);
420 break;
422 targetCreature->CastSpell(targetCreature, SPELL_WARLOCK_DEMONIC_EMPOWERMENT_IMP, true);
423 break;
424 default:
425 break;
426 }
427 }
428 }
429 }
430
435};
436
437// -1120 - Drain Soul
439{
441
453
454 bool CheckProc(ProcEventInfo& eventInfo)
455 {
456 // Drain Soul's proc tries to happen each time the warlock lands a killing blow on a unit while channeling.
457 // Make sure that dying unit is afflicted by the caster's Drain Soul debuff in order to avoid a false positive.
458
459 Unit* caster = eventInfo.GetActor();
460 Unit* victim = eventInfo.GetActionTarget();
462 }
463
464 void HandleProc(AuraEffect const* aurEff, ProcEventInfo& eventInfo)
465 {
467
468 Unit* caster = eventInfo.GetActor();
469 // Improved Drain Soul
470 Aura const* impDrainSoul = caster->GetAuraOfRankedSpell(SPELL_WARLOCK_IMPROVED_DRAIN_SOUL_R1, caster->GetGUID());
471 if (!impDrainSoul)
472 return;
473
474 int32 amount = CalculatePct(caster->GetMaxPower(POWER_MANA), impDrainSoul->GetSpellInfo()->GetEffect(EFFECT_2).CalcValue());
475 CastSpellExtraArgs args(aurEff);
476 args.AddSpellBP0(amount);
478 }
479
480 void HandleTick(AuraEffect const* aurEff)
481 {
482 Unit* caster = GetCaster();
483 Unit* target = GetTarget();
484 if (caster && caster->GetTypeId() == TYPEID_PLAYER && caster->ToPlayer()->isHonorOrXPTarget(target))
485 {
486 if (roll_chance_i(20))
487 {
488 caster->CastSpell(caster, SPELL_WARLOCK_CREATE_SOULSHARD, aurEff);
489 // Glyph of Drain Soul - chance to create an additional Soul Shard
491 if (roll_chance_i(aur->GetMiscValue()))
493 }
494 }
495 }
496
503};
504
505// 19505, 67518 - Devour Magic
507{
509
510 bool Validate(SpellInfo const* /*spellInfo*/) override
511 {
513 }
514
516 {
517 Unit* caster = GetCaster();
520 caster->CastSpell(caster, SPELL_WARLOCK_DEVOUR_MAGIC_HEAL, args);
521
522 // Glyph of Felhunter
523 if (Unit* owner = caster->GetOwner())
524 if (owner->HasAura(SPELL_WARLOCK_GLYPH_OF_FELHUNTER))
525 owner->CastSpell(owner, SPELL_WARLOCK_DEVOUR_MAGIC_HEAL, args);
526 }
527
532};
533
534// 47422 - Everlasting Affliction
536{
538
540 {
541 Unit* caster = GetCaster();
542 if (Unit* target = GetHitUnit())
543 {
544 // Refresh corruption on target
545 if (AuraEffect* aur = target->GetAuraEffect(SPELL_AURA_PERIODIC_DAMAGE, SPELLFAMILY_WARLOCK, 0x2, 0, 0, caster->GetGUID()))
546 {
547 aur->ChangeAmount(aur->CalculateAmount(aur->GetCaster()), false);
548 aur->CalculatePeriodic(caster, false, false);
549 aur->GetBase()->RefreshDuration(true);
550 }
551 }
552 }
553
558};
559
560// -47230 - Fel Synergy
562{
564
565 bool Validate(SpellInfo const* /*spellInfo*/) override
566 {
568 }
569
570 bool CheckProc(ProcEventInfo& eventInfo)
571 {
572 DamageInfo* damageInfo = eventInfo.GetDamageInfo();
573 if (!damageInfo || !damageInfo->GetDamage())
574 return false;
575
576 return GetTarget()->GetGuardianPet() != nullptr;
577 }
578
579 void OnProc(AuraEffect const* aurEff, ProcEventInfo& eventInfo)
580 {
582
583 int32 heal = CalculatePct(static_cast<int32>(eventInfo.GetDamageInfo()->GetDamage()), aurEff->GetAmount());
584 CastSpellExtraArgs args(aurEff);
585 args.AddSpellBP0(heal);
586 GetTarget()->CastSpell(nullptr, SPELL_WARLOCK_FEL_SYNERGY_HEAL, args); // TARGET_UNIT_PET
587 }
588
594};
595
596// -18094 - Nightfall
597// 56218 - Glyph of Corruption
599{
601
602 bool Validate(SpellInfo const* /*spellInfo*/) override
603 {
605 }
606
607 void HandleProc(AuraEffect const* aurEff, ProcEventInfo& eventInfo)
608 {
610 Unit* caster = eventInfo.GetActor();
611 caster->CastSpell(caster, SPELL_WARLOCK_SHADOW_TRANCE, aurEff);
612 }
613
618};
619
620// 63320 - Glyph of Life Tap
622{
624
625 bool Validate(SpellInfo const* /*spellInfo*/) override
626 {
628 }
629
630 void HandleProc(AuraEffect const* aurEff, ProcEventInfo& eventInfo)
631 {
633 Unit* caster = eventInfo.GetActor();
635 }
636
641};
642
643// 63310 - Glyph of Shadowflame
664
665// -48181 - Haunt
667{
669
671 {
672 if (Aura* aura = GetHitAura())
673 if (AuraEffect* aurEff = aura->GetEffect(EFFECT_1))
674 aurEff->SetAmount(CalculatePct(GetHitDamage(), aurEff->GetAmount()));
675 }
676
677 void Register() override
678 {
680 }
681};
682
684{
686
687 bool Validate(SpellInfo const* /*spellInfo*/) override
688 {
690 }
691
692 void HandleRemove(AuraEffect const* aurEff, AuraEffectHandleModes /*mode*/)
693 {
694 if (Unit* caster = GetCaster())
695 {
696 CastSpellExtraArgs args(aurEff);
698 args.AddSpellBP0(aurEff->GetAmount());
700 }
701 }
702
707};
708
709// -755 - Health Funnel
740
741// -1454 - Life Tap
743{
745
746 bool Load() override
747 {
748 return GetCaster()->GetTypeId() == TYPEID_PLAYER;
749 }
750
751 bool Validate(SpellInfo const* /*spellInfo*/) override
752 {
754 }
755
757 {
758 Unit* caster = GetCaster();
759 int32 base = GetEffectInfo(effIndex).CalcValue();
760
762 float fmana = (float)base + caster->GetUInt32Value(PLAYER_FIELD_MOD_DAMAGE_DONE_POS + AsUnderlyingType(SPELL_SCHOOL_SHADOW)) * 0.5f * penalty;
763
764 // Improved Life Tap mod
766 AddPct(fmana, aurEff->GetAmount());
767 int32 mana = round(fmana);
768
769 // Shouldn't Appear in Combat Log
770 caster->ModifyHealth(-base);
771
773 args.AddSpellBP0(mana);
774 caster->CastSpell(caster, SPELL_WARLOCK_LIFE_TAP_ENERGIZE, args);
775
776 // Mana Feed
777 int32 manaFeedVal = 0;
779 manaFeedVal = aurEff->GetAmount();
780
781 if (manaFeedVal > 0)
782 {
783 ApplyPct(manaFeedVal, mana);
785 manaFeedArgs.AddSpellBP0(manaFeedVal);
786 caster->CastSpell(caster, SPELL_WARLOCK_LIFE_TAP_ENERGIZE_2, manaFeedArgs);
787 }
788 }
789
791 {
792 if (int32(GetCaster()->GetHealth()) > int32(GetEffectInfo(EFFECT_0).CalcValue()))
793 return SPELL_CAST_OK;
794 return SPELL_FAILED_FIZZLE;
795 }
796
802};
803
804// -30299 - Nether Protection
806{
808
821
822 bool CheckProc(ProcEventInfo& eventInfo)
823 {
824 if (DamageInfo* damageInfo = eventInfo.GetDamageInfo())
825 {
826 switch (GetFirstSchoolInMask(damageInfo->GetSchoolMask()))
827 {
834 return true;
835 default:
836 break;
837 }
838 }
839
840 return false;
841 }
842
843 void HandleProc(AuraEffect const* aurEff, ProcEventInfo& eventInfo)
844 {
846 uint32 triggerspell = 0;
847
848 switch (GetFirstSchoolInMask(eventInfo.GetDamageInfo()->GetSchoolMask()))
849 {
852 break;
855 break;
858 break;
861 break;
864 break;
867 break;
868 default:
869 return;
870 }
871
872 if (Unit* target = eventInfo.GetActionTarget())
873 target->CastSpell(target, triggerspell, aurEff);
874 }
875
881};
882
883// 54909, 53646 - Demonic Pact
885{
887
888 bool Validate(SpellInfo const* /*spellInfo*/) override
889 {
891 }
892
893 bool CheckProc(ProcEventInfo& eventInfo)
894 {
895 return eventInfo.GetActor() && eventInfo.GetActor()->IsPet();
896 }
897
898 void HandleProc(AuraEffect const* /*aurEff*/, ProcEventInfo& eventInfo)
899 {
901
902 if (Unit* owner = eventInfo.GetActor()->GetOwner())
903 {
904 if (AuraEffect* aurEff = owner->GetDummyAuraEffect(SPELLFAMILY_WARLOCK, WARLOCK_ICON_ID_DEMONIC_PACT, EFFECT_0))
905 {
906 int32 bp = static_cast<int32>((aurEff->GetAmount() * owner->SpellBaseDamageBonusDone(SPELL_SCHOOL_MASK_MAGIC) + 100.0f) / 100.0f);
907 CastSpellExtraArgs args(aurEff);
908 args.AddSpellBP0(bp);
910 owner->CastSpell(nullptr, SPELL_WARLOCK_DEMONIC_PACT_PROC, args);
911 }
912 }
913 }
914
920};
921
922// 18541 - Ritual of Doom Effect
938
939// 34145, 58888 - Ritual of Souls Rank X - Trigger Create Soulwell
941{
943
944 bool Validate(SpellInfo const* /*spellInfo*/) override
945 {
947 }
948
949 void HandleScript(SpellEffIndex /*effIndex*/)
950 {
951 Unit* caster = GetCaster();
952 uint32 spellId = _createSoulwellSpellIds[0];
954 spellId = _createSoulwellSpellIds[2];
956 spellId = _createSoulwellSpellIds[1];
957
958 caster->CastSpell(caster, spellId, CastSpellExtraArgs(TRIGGERED_FULL_MASK).SetOriginalCaster(Object::GetGUID(GetOriginalCaster())));
959 }
960
965
966 std::array<uint32, 3> _createSoulwellSpellIds;
967
968public:
969 spell_warl_ritual_of_souls(std::array<uint32, 3> createSoulwellSpellIds) : _createSoulwellSpellIds(createSoulwellSpellIds) { }
970};
971
972// 6358 - Seduction
974{
976
977 bool Validate(SpellInfo const* /*spellInfo*/) override
978 {
980 }
981
982 void HandleDummy(SpellEffIndex /*effIndex*/)
983 {
984 Unit* owner = GetCaster()->GetOwner();
985 if (!owner || !owner->HasAura(SPELL_WARLOCK_GLYPH_OF_SUCCUBUS))
986 return;
987
988 Unit* target = GetHitUnit();
989 target->RemoveAurasByType(SPELL_AURA_PERIODIC_DAMAGE, ObjectGuid::Empty, target->GetAura(32409)); // SW:D shall not be removed.
992 }
993
998};
999
1000// -27285 - Seed of Corruption
1002{
1004
1005 void FilterTargets(std::list<WorldObject*>& targets)
1006 {
1007 targets.remove_if([&](WorldObject const* target)
1008 {
1009 if (Unit const* unitTarget = target->ToUnit())
1010 if (WorldLocation const* dest = GetExplTargetDest())
1011 if (!unitTarget->IsWithinLOS(dest->GetPositionX(), dest->GetPositionY(), dest->GetPositionZ()))
1012 return true;
1013
1014 return false;
1015 });
1016 }
1017
1022};
1023
1024// -27243 - Seed of Corruption
1026{
1028
1029 bool Validate(SpellInfo const* /*spellInfo*/) override
1030 {
1032 }
1033
1034 void CalculateBuffer(AuraEffect const* aurEff, int32& amount, bool& /*canBeRecalculated*/)
1035 {
1036 Unit* caster = GetCaster();
1037 if (!caster)
1038 return;
1039
1040 // effect 1 scales with 14% of caster's SP (DBC data)
1041 amount = caster->SpellDamageBonusDone(GetUnitOwner(), GetSpellInfo(), amount, SPELL_DIRECT_DAMAGE, aurEff->GetSpellEffectInfo(), GetAura()->GetDonePct());
1042 }
1043
1044 void HandleProc(AuraEffect const* aurEff, ProcEventInfo& eventInfo)
1045 {
1047 DamageInfo* damageInfo = eventInfo.GetDamageInfo();
1048 if (!damageInfo || !damageInfo->GetDamage())
1049 return;
1050
1051 int32 amount = aurEff->GetAmount() - damageInfo->GetDamage();
1052 if (amount > 0)
1053 {
1054 const_cast<AuraEffect*>(aurEff)->SetAmount(amount);
1055 if (!GetTarget()->HealthBelowPctDamaged(1, damageInfo->GetDamage()))
1056 return;
1057 }
1058
1059 Remove();
1060
1061 Unit* caster = GetCaster();
1062 if (!caster)
1063 return;
1064
1065 uint32 spellId = sSpellMgr->GetSpellWithRank(SPELL_WARLOCK_SEED_OF_CORRUPTION_DAMAGE_R1, GetSpellInfo()->GetRank());
1066 caster->CastSpell(eventInfo.GetActionTarget(), spellId, aurEff);
1067 }
1068
1074};
1075
1076// 32863 - Seed of Corruption
1077// 36123 - Seed of Corruption
1078// 38252 - Seed of Corruption
1079// 39367 - Seed of Corruption
1080// 44141 - Seed of Corruption
1081// 70388 - Seed of Corruption
1082// Monster spells, triggered only on amount drop (not on death)
1084{
1086
1087 bool Validate(SpellInfo const* /*spellInfo*/) override
1088 {
1090 }
1091
1092 void HandleProc(AuraEffect const* aurEff, ProcEventInfo& eventInfo)
1093 {
1095 DamageInfo* damageInfo = eventInfo.GetDamageInfo();
1096 if (!damageInfo || !damageInfo->GetDamage())
1097 return;
1098
1099 int32 amount = aurEff->GetAmount() - damageInfo->GetDamage();
1100 if (amount > 0)
1101 {
1102 const_cast<AuraEffect*>(aurEff)->SetAmount(amount);
1103 return;
1104 }
1105
1106 Remove();
1107
1108 Unit* caster = GetCaster();
1109 if (!caster)
1110 return;
1111
1113 }
1114
1119};
1120
1121// -6229 - Shadow Ward
1123{
1125
1126 void CalculateAmount(AuraEffect const* /*aurEff*/, int32& amount, bool& canBeRecalculated)
1127 {
1128 canBeRecalculated = false;
1129 if (Unit* caster = GetCaster())
1130 {
1131 // +80.68% from sp bonus
1132 float bonus = 0.8068f;
1133
1134 bonus *= caster->SpellBaseHealingBonusDone(GetSpellInfo()->GetSchoolMask());
1135 bonus *= caster->CalculateSpellpowerCoefficientLevelPenalty(GetSpellInfo());
1136
1137 amount += int32(bonus);
1138 }
1139 }
1140
1145};
1146
1147// 63108 - Siphon Life
1149{
1151
1152 bool Validate(SpellInfo const* /*spellInfo*/) override
1153 {
1154 return ValidateSpellInfo(
1155 {
1158 });
1159 }
1160
1161 bool CheckProc(ProcEventInfo& eventInfo)
1162 {
1163 DamageInfo* damageInfo = eventInfo.GetDamageInfo();
1164 if (!damageInfo || !damageInfo->GetDamage())
1165 return false;
1166
1167 return GetTarget()->IsAlive();
1168 }
1169
1170 void OnProc(AuraEffect const* aurEff, ProcEventInfo& eventInfo)
1171 {
1173
1174 int32 amount = CalculatePct(static_cast<int32>(eventInfo.GetDamageInfo()->GetDamage()), aurEff->GetAmount());
1175 // Glyph of Siphon Life
1176 if (AuraEffect const* glyph = GetTarget()->GetAuraEffect(SPELL_WARLOCK_GLYPH_OF_SIPHON_LIFE, EFFECT_0))
1177 AddPct(amount, glyph->GetAmount());
1178
1179 CastSpellExtraArgs args(aurEff);
1180 args.AddSpellBP0(amount);
1182 }
1183
1189};
1190
1191// -30293 - Soul Leech
1193{
1195
1209
1210 void HandleProc(AuraEffect const* aurEff, ProcEventInfo& eventInfo)
1211 {
1214
1216 DamageInfo* damageInfo = eventInfo.GetDamageInfo();
1217 if (!damageInfo || !damageInfo->GetDamage())
1218 return;
1219
1220 Unit* caster = eventInfo.GetActor();
1222 args.AddSpellBP0(CalculatePct(damageInfo->GetDamage(), aurEff->GetAmount()));
1223 caster->CastSpell(caster, SPELL_WARLOCK_SOUL_LEECH_HEAL, args);
1224
1225 // Improved Soul Leech code below
1227 if (!impSoulLeech)
1228 return;
1229
1230 uint8 impSoulLeechRank = impSoulLeech->GetSpellInfo()->GetRank();
1231 uint32 selfSpellId = casterMana[impSoulLeechRank - 1];
1232 uint32 petSpellId = petMana[impSoulLeechRank - 1];
1233
1234 caster->CastSpell(nullptr, selfSpellId, aurEff);
1235 caster->CastSpell(nullptr, petSpellId, aurEff);
1236
1237 if (roll_chance_i(impSoulLeech->GetAmount()))
1238 caster->CastSpell(nullptr, SPELL_REPLENISHMENT, aurEff);
1239 }
1240
1245};
1246
1247// 29858 - Soulshatter
1249{
1251
1252 bool Validate(SpellInfo const* /*spellInfo*/) override
1253 {
1255 }
1256
1257 void HandleDummy(SpellEffIndex /*effIndex*/)
1258 {
1259 Unit* caster = GetCaster();
1260 if (Unit* target = GetHitUnit())
1261 if (target->GetThreatManager().IsThreatenedBy(caster, true))
1262 caster->CastSpell(target, SPELL_WARLOCK_SOULSHATTER_EFFECT, true);
1263 }
1264
1269};
1270
1271// 37377 - Shadowflame
1272// 39437 - Shadowflame Hellfire and RoF
1273template <uint32 TriggerSpellId>
1275{
1277
1278 bool Validate(SpellInfo const* /*spellInfo*/) override
1279 {
1280 return ValidateSpellInfo({ TriggerSpellId });
1281 }
1282
1283 void HandleProc(AuraEffect const* aurEff, ProcEventInfo& eventInfo)
1284 {
1286 Unit* caster = eventInfo.GetActor();
1287 caster->CastSpell(caster, TriggerSpellId, aurEff);
1288 }
1289
1294};
1295
1296// -30108 - Unstable Affliction
1298{
1300
1301 bool Validate(SpellInfo const* /*spellInfo*/) override
1302 {
1304 }
1305
1306 void HandleDispel(DispelInfo* dispelInfo)
1307 {
1308 if (Unit* caster = GetCaster())
1309 {
1310 if (AuraEffect const* aurEff = GetEffect(EFFECT_0))
1311 {
1312 if (Unit* target = dispelInfo->GetDispeller()->ToUnit())
1313 {
1314 int32 bp = aurEff->GetAmount();
1315 bp = target->SpellDamageBonusTaken(caster, aurEff->GetSpellInfo(), bp, DOT);
1316 bp *= 9;
1317
1318 // backfire damage and silence
1319 CastSpellExtraArgs args(aurEff);
1320 args.AddSpellBP0(bp);
1321 caster->CastSpell(target, SPELL_WARLOCK_UNSTABLE_AFFLICTION_DISPEL, args);
1322 }
1323 }
1324 }
1325 }
1326
1331};
1332
1334{
1369}
uint8_t uint8
Definition Define.h:135
int32_t int32
Definition Define.h:129
uint32_t uint32
Definition Define.h:133
InventoryResult
Definition ItemDefines.h:25
@ EQUIP_ERR_OK
Definition ItemDefines.h:26
#define TC_LOG_ERROR(filterType__,...)
Definition Log.h:165
@ TYPEID_PLAYER
Definition ObjectGuid.h:39
std::vector< ItemPosCount > ItemPosCountVec
Definition Player.h:632
bool roll_chance_i(int chance)
Definition Random.h:59
if(posix_memalign(&__mallocedMemory, __align, __size)) return NULL
#define RegisterSpellAndAuraScriptPair(script_1, script_2)
Definition ScriptMgr.h:1130
#define RegisterSpellScript(spell_script)
Definition ScriptMgr.h:1128
#define RegisterSpellScriptWithArgs(spell_script, script_name,...)
Definition ScriptMgr.h:1127
SpellEffIndex
@ EFFECT_1
@ EFFECT_0
@ EFFECT_2
@ SPELL_SCHOOL_SHADOW
@ SPELL_SCHOOL_NATURE
@ SPELL_SCHOOL_FROST
@ SPELL_SCHOOL_ARCANE
@ SPELL_SCHOOL_FIRE
@ SPELL_SCHOOL_HOLY
@ SPELL_EFFECT_DUMMY
@ SPELL_EFFECT_SCRIPT_EFFECT
@ SPELL_EFFECT_DISPEL
@ SPELL_EFFECT_APPLY_AURA
@ TARGET_UNIT_DEST_AREA_ENEMY
@ CREATURE_FAMILY_FELGUARD
@ CREATURE_FAMILY_IMP
@ CREATURE_FAMILY_VOIDWALKER
@ CREATURE_FAMILY_FELHUNTER
@ CREATURE_FAMILY_SUCCUBUS
@ SPELL_SCHOOL_MASK_MAGIC
SpellSchools GetFirstSchoolInMask(SpellSchoolMask mask)
@ SPELLFAMILY_WARLOCK
@ POWER_MANA
SpellMissInfo
@ SPELL_MISS_IMMUNE
@ AURA_STATE_HEALTHLESS_35_PERCENT
SpellCastResult
@ SPELL_FAILED_TOO_MANY_OF_ITEM
@ SPELL_FAILED_FIZZLE
@ SPELL_CAST_OK
AuraRemoveMode
@ AURA_REMOVE_BY_DEATH
AuraEffectHandleModes
@ AURA_EFFECT_HANDLE_REAL_OR_REAPPLY_MASK
@ AURA_EFFECT_HANDLE_REAPPLY
@ AURA_EFFECT_HANDLE_REAL
@ SPELL_AURA_PERIODIC_DAMAGE
@ SPELL_AURA_PROC_TRIGGER_SPELL
@ SPELL_AURA_ADD_FLAT_MODIFIER
@ SPELL_AURA_PERIODIC_HEAL
@ SPELL_AURA_PERIODIC_DAMAGE_PERCENT
@ SPELL_AURA_DUMMY
@ SPELL_AURA_MECHANIC_IMMUNITY
@ SPELL_AURA_SCHOOL_ABSORB
@ SPELL_AURA_PERIODIC_LEECH
@ SPELL_AURA_PERIODIC_DUMMY
@ TRIGGERED_FULL_MASK
Will return SPELL_FAILED_DONT_REPORT in CheckCast functions.
@ SPELLVALUE_BASE_POINT1
@ SPELLVALUE_BASE_POINT0
#define sSpellMgr
Definition SpellMgr.h:738
#define BeforeSpellHitFn(F)
#define SpellCheckCastFn(F)
#define AuraEffectProcFn(F, I, N)
#define SpellEffectFn(F, I, N)
#define AuraEffectCalcAmountFn(F, I, N)
#define SpellObjectAreaTargetSelectFn(F, I, N)
#define AuraEffectPeriodicFn(F, I, N)
#define AuraEffectUpdatePeriodicFn(F, I, N)
#define AuraEffectApplyFn(F, I, N, M)
#define AuraCheckProcFn(F)
#define SpellHitFn(F)
#define AuraDispelFn(F)
#define AuraEffectRemoveFn(F, I, N, M)
@ NULL_BAG
Definition Unit.h:60
@ NULL_SLOT
Definition Unit.h:61
@ DOT
Definition Unit.h:369
@ SPELL_DIRECT_DAMAGE
Definition Unit.h:368
@ PLAYER_FIELD_MOD_DAMAGE_DONE_POS
T AddPct(T &base, U pct)
Definition Util.h:77
constexpr std::underlying_type< E >::type AsUnderlyingType(E enumValue)
Definition Util.h:554
T ApplyPct(T &base, U pct)
Definition Util.h:83
T CalculatePct(T base, U pct)
Definition Util.h:71
AuraRemoveMode GetRemoveMode() const
Definition SpellAuras.h:88
uint32 GetTickNumber() const
SpellInfo const * GetSpellInfo() const
SpellEffectInfo const & GetSpellEffectInfo() const
void SetAmount(int32 amount)
ObjectGuid GetCasterGUID() const
int32 GetAmount() const
void PreventDefaultAction()
bool IsExpired() const
AuraApplication const * GetTargetApplication() const
HookList< EffectApplyHandler > AfterEffectRemove
HookList< EffectPeriodicHandler > OnEffectPeriodic
SpellInfo const * GetSpellInfo() const
HookList< EffectApplyHandler > AfterEffectApply
HookList< EffectCalcAmountHandler > DoEffectCalcAmount
Unit * GetCaster() const
HookList< EffectUpdatePeriodicHandler > OnEffectUpdatePeriodic
AuraEffect * GetEffect(uint8 effIndex) const
Aura * GetAura() const
Unit * GetTarget() const
ObjectGuid GetCasterGUID() const
HookList< CheckProcHandler > DoCheckProc
HookList< EffectApplyHandler > OnEffectRemove
HookList< AuraDispelHandler > AfterDispel
void Remove(AuraRemoveMode removeMode=AURA_REMOVE_BY_DEFAULT)
HookList< EffectProcHandler > OnEffectProc
Unit * GetUnitOwner() const
HookList< AuraProcHandler > OnProc
HookList< EffectApplyHandler > OnEffectApply
uint32 GetId() const
SpellInfo const * GetSpellInfo() const
Definition SpellAuras.h:140
SpellSchoolMask GetSchoolMask() const
Definition Unit.h:475
uint32 GetDamage() const
Definition Unit.h:478
WorldObject * GetDispeller() const
Definition Unit.h:418
static ObjectGuid const Empty
Definition ObjectGuid.h:140
static Unit * ToUnit(Object *o)
Definition Object.h:195
uint32 GetUInt32Value(uint16 index) const
Definition Object.cpp:241
TypeID GetTypeId() const
Definition Object.h:93
static ObjectGuid GetGUID(Object const *o)
Definition Object.h:78
ObjectGuid GetGUID() const
Definition Object.h:79
static Player * ToPlayer(Object *o)
Definition Object.h:183
bool isHonorOrXPTarget(Unit const *victim) const
Definition Player.cpp:23548
Unit * GetActionTarget() const
Definition Unit.h:523
SpellInfo const * GetSpellInfo() const
Definition Unit.cpp:269
Unit * GetActor()
Definition Unit.h:522
DamageInfo * GetDamageInfo() const
Definition Unit.h:533
int32 CalcValue(WorldObject const *caster=nullptr, int32 const *basePoints=nullptr) const
float GetMaxRange(bool positive=false, WorldObject *caster=nullptr, Spell *spell=nullptr) const
uint8 GetRank() const
SpellEffectInfo const & GetEffect(SpellEffIndex index) const
Definition SpellInfo.h:483
HookList< CheckCastHandler > OnCheckCast
Creature * GetHitCreature() const
int32 GetHitDamage() const
Unit * GetCaster() const
HookList< HitHandler > AfterHit
HookList< EffectHandler > OnEffectHit
Unit * GetHitUnit() const
int32 GetEffectValue() const
SpellEffectInfo const & GetEffectInfo() const
HookList< EffectHandler > OnEffectHitTarget
Aura * GetHitAura(bool dynObjAura=false) const
HookList< EffectHandler > OnEffectLaunchTarget
HookList< BeforeHitHandler > BeforeHit
HookList< EffectHandler > OnEffectSuccessfulDispel
void CreateItem(uint32 itemId)
WorldLocation const * GetExplTargetDest() const
SpellInfo const * GetSpellInfo() const
HookList< ObjectAreaTargetSelectHandler > OnObjectAreaTargetSelect
Unit * GetOriginalCaster() const
Definition Unit.h:783
int32 ModifyHealth(int32 val)
Definition Unit.cpp:8321
void RemoveAurasByType(AuraType auraType, std::function< bool(AuraApplication const *)> const &check, AuraRemoveMode removeMode=AURA_REMOVE_BY_DEFAULT)
Definition Unit.cpp:3788
void RemoveGameObject(GameObject *gameObj, bool del)
Definition Unit.cpp:5161
float CalculateSpellpowerCoefficientLevelPenalty(SpellInfo const *spellInfo) const
Definition Unit.cpp:2345
Aura * GetAura(uint32 spellId, ObjectGuid casterGUID=ObjectGuid::Empty, ObjectGuid itemCasterGUID=ObjectGuid::Empty, uint8 reqEffMask=0) const
Definition Unit.cpp:4462
Aura * GetAuraOfRankedSpell(uint32 spellId, ObjectGuid casterGUID=ObjectGuid::Empty, ObjectGuid itemCasterGUID=ObjectGuid::Empty, uint8 reqEffMask=0) const
Definition Unit.cpp:4480
void RemoveAura(AuraApplicationMap::iterator &i, AuraRemoveMode mode=AURA_REMOVE_BY_DEFAULT)
Definition Unit.cpp:3661
bool IsPet() const
Definition Unit.h:898
AuraEffect * GetAuraEffect(uint32 spellId, uint8 effIndex, ObjectGuid casterGUID=ObjectGuid::Empty) const
Definition Unit.cpp:4382
bool IsAlive() const
Definition Unit.h:1247
bool HasAura(uint32 spellId, ObjectGuid casterGUID=ObjectGuid::Empty, ObjectGuid itemCasterGUID=ObjectGuid::Empty, uint8 reqEffMask=0) const
Definition Unit.cpp:4558
uint32 SpellDamageBonusDone(Unit *victim, SpellInfo const *spellProto, uint32 pdamage, DamageEffectType damagetype, SpellEffectInfo const &spellEffectInfo, Optional< float > const &donePctTotal, uint32 stack=1) const
Definition Unit.cpp:6393
uint32 GetMaxPower(Powers power) const
Definition Unit.h:950
bool HasAuraState(AuraStateType flag, SpellInfo const *spellProto=nullptr, Unit const *Caster=nullptr) const
Definition Unit.cpp:5757
AuraEffect * GetAuraEffectOfRankedSpell(uint32 spellId, uint8 effIndex, ObjectGuid casterGUID=ObjectGuid::Empty) const
Definition Unit.cpp:4396
AuraApplication * GetAuraApplicationOfRankedSpell(uint32 spellId, ObjectGuid casterGUID=ObjectGuid::Empty, ObjectGuid itemCasterGUID=ObjectGuid::Empty, uint8 reqEffMask=0, AuraApplication *except=nullptr) const
Definition Unit.cpp:4468
void RemoveAurasDueToSpell(uint32 spellId, ObjectGuid casterGUID=ObjectGuid::Empty, uint8 reqEffMask=0, AuraRemoveMode removeMode=AURA_REMOVE_BY_DEFAULT)
Definition Unit.cpp:3807
bool HealthBelowPctDamaged(int32 pct, uint32 damage) const
Definition Unit.h:932
AuraEffect * GetDummyAuraEffect(SpellFamilyNames name, uint32 iconId, uint8 effIndex) const
Definition Unit.cpp:4438
Guardian * GetGuardianPet() const
Definition Unit.cpp:5836
SpellCastResult CastSpell(CastSpellTargetArg const &targets, uint32 spellId, CastSpellExtraArgs const &args={ })
Definition Object.cpp:2833
Unit * GetOwner() const
Definition Object.cpp:2181
static bool ValidateSpellInfo(std::initializer_list< uint32 > spellIds)
PrepareSpellScript(spell_warl_banish)
void HandleBanish(SpellMissInfo missInfo)
void Register() override
SpellScript * GetSpellScript() const override
PrepareAuraScript(spell_warl_curse_of_agony)
void ApplyEffect(AuraEffect const *aurEff, AuraEffectHandleModes)
void HandleEffectPeriodicUpdate(AuraEffect *aurEff)
void OnRemove(AuraEffect const *aurEff, AuraEffectHandleModes)
PrepareAuraScript(spell_warl_curse_of_doom)
bool Validate(SpellInfo const *) override
void Register() override
PrepareAuraScript(spell_warl_decimation)
bool CheckProc(ProcEventInfo &eventInfo)
PrepareAuraScript(spell_warl_demonic_circle_summon)
void HandleRemove(AuraEffect const *, AuraEffectHandleModes mode)
void HandleDummyTick(AuraEffect const *)
PrepareAuraScript(spell_warl_demonic_circle_teleport)
void HandleTeleport(AuraEffect const *, AuraEffectHandleModes)
void HandleScriptEffect(SpellEffIndex)
bool Validate(SpellInfo const *) override
PrepareSpellScript(spell_warl_demonic_empowerment)
bool Validate(SpellInfo const *) override
bool CheckProc(ProcEventInfo &eventInfo)
PrepareAuraScript(spell_warl_demonic_pact)
void HandleProc(AuraEffect const *, ProcEventInfo &eventInfo)
bool Validate(SpellInfo const *) override
PrepareSpellScript(spell_warl_devour_magic)
void OnSuccessfulDispel(SpellEffIndex)
void Register() override
bool CheckProc(ProcEventInfo &eventInfo)
void HandleTick(AuraEffect const *aurEff)
void HandleProc(AuraEffect const *aurEff, ProcEventInfo &eventInfo)
bool Validate(SpellInfo const *) override
PrepareAuraScript(spell_warl_drain_soul)
PrepareSpellScript(spell_warl_everlasting_affliction)
bool Validate(SpellInfo const *) override
bool CheckProc(ProcEventInfo &eventInfo)
PrepareAuraScript(spell_warl_fel_synergy)
void OnProc(AuraEffect const *aurEff, ProcEventInfo &eventInfo)
bool Validate(SpellInfo const *) override
void HandleProc(AuraEffect const *aurEff, ProcEventInfo &eventInfo)
PrepareAuraScript(spell_warl_glyph_of_corruption_nightfall)
PrepareAuraScript(spell_warl_glyph_of_life_tap)
bool Validate(SpellInfo const *) override
void HandleProc(AuraEffect const *aurEff, ProcEventInfo &eventInfo)
void HandleProc(AuraEffect const *aurEff, ProcEventInfo &eventInfo)
bool Validate(SpellInfo const *) override
PrepareAuraScript(spell_warl_glyph_of_shadowflame)
void HandleRemove(AuraEffect const *aurEff, AuraEffectHandleModes)
void Register() override
PrepareAuraScript(spell_warl_haunt_aura)
bool Validate(SpellInfo const *) override
void Register() override
PrepareSpellScript(spell_warl_haunt)
void ApplyEffect(AuraEffect const *, AuraEffectHandleModes)
void RemoveEffect(AuraEffect const *, AuraEffectHandleModes)
PrepareAuraScript(spell_warl_health_funnel)
void HandleDummy(SpellEffIndex effIndex)
bool Validate(SpellInfo const *) override
SpellCastResult CheckCast()
void Register() override
PrepareSpellScript(spell_warl_life_tap)
bool Load() override
void HandleProc(AuraEffect const *aurEff, ProcEventInfo &eventInfo)
PrepareAuraScript(spell_warl_nether_protection)
bool CheckProc(ProcEventInfo &eventInfo)
bool Validate(SpellInfo const *) override
PrepareSpellScript(spell_warl_ritual_of_doom_effect)
PrepareSpellScript(spell_warl_ritual_of_souls)
bool Validate(SpellInfo const *) override
spell_warl_ritual_of_souls(std::array< uint32, 3 > createSoulwellSpellIds)
std::array< uint32, 3 > _createSoulwellSpellIds
void HandleScript(SpellEffIndex)
bool Validate(SpellInfo const *) override
void HandleDummy(SpellEffIndex)
PrepareSpellScript(spell_warl_seduction)
void Register() override
PrepareAuraScript(spell_warl_seed_of_corruption_dummy)
void HandleProc(AuraEffect const *aurEff, ProcEventInfo &eventInfo)
void CalculateBuffer(AuraEffect const *aurEff, int32 &amount, bool &)
bool Validate(SpellInfo const *) override
void HandleProc(AuraEffect const *aurEff, ProcEventInfo &eventInfo)
bool Validate(SpellInfo const *) override
PrepareAuraScript(spell_warl_seed_of_corruption_generic)
void FilterTargets(std::list< WorldObject * > &targets)
PrepareSpellScript(spell_warl_seed_of_corruption)
PrepareAuraScript(spell_warl_shadow_ward)
void CalculateAmount(AuraEffect const *, int32 &amount, bool &canBeRecalculated)
bool Validate(SpellInfo const *) override
PrepareAuraScript(spell_warl_siphon_life)
void OnProc(AuraEffect const *aurEff, ProcEventInfo &eventInfo)
bool CheckProc(ProcEventInfo &eventInfo)
void HandleProc(AuraEffect const *aurEff, ProcEventInfo &eventInfo)
bool Validate(SpellInfo const *) override
PrepareAuraScript(spell_warl_soul_leech)
void HandleDummy(SpellEffIndex)
bool Validate(SpellInfo const *) override
PrepareSpellScript(spell_warl_soulshatter)
void HandleProc(AuraEffect const *aurEff, ProcEventInfo &eventInfo)
PrepareAuraScript(spell_warl_t4_2p_bonus)
bool Validate(SpellInfo const *) override
void HandleDispel(DispelInfo *dispelInfo)
PrepareAuraScript(spell_warl_unstable_affliction)
bool Validate(SpellInfo const *) override
void AddSC_warlock_spell_scripts()
@ SPELL_WARLOCK_GLYPH_OF_FELHUNTER
@ SPELL_WARLOCK_HAUNT_HEAL
@ SPELL_WARLOCK_CURSE_OF_DOOM_EFFECT
@ SPELL_WARLOCK_DEMONIC_CIRCLE_TELEPORT
@ SPELL_WARLOCK_DEMONIC_EMPOWERMENT_SUCCUBUS
@ SPELL_WARLOCK_IMPROVED_HEALTH_FUNNEL_BUFF_R2
@ SPELL_WARLOCK_SIPHON_LIFE_HEAL
@ SPELL_WARLOCK_NETHER_PROTECTION_FIRE
@ SPELL_WARLOCK_SHADOWFLAME
@ SPELL_WARLOCK_CREATE_SOULWELL_R2
@ SPELL_WARLOCK_NETHER_PROTECTION_ARCANE
@ SPELL_WARLOCK_SOUL_LEECH_CASTER_MANA_2
@ SPELL_WARLOCK_GLYPH_OF_LIFE_TAP_TRIGGERED
@ SPELL_WARLOCK_SOUL_LEECH_PET_MANA_1
@ SPELL_WARLOCK_IMPROVED_DRAIN_SOUL_R1
@ SPELL_WARLOCK_IMP_SOUL_LEECH_R1
@ SPELL_WARLOCK_DEMONIC_PACT_PROC
@ SPELL_WARLOCK_NETHER_PROTECTION_FROST
@ SPELL_WARLOCK_DEMONIC_CIRCLE_SUMMON
@ SPELL_WARLOCK_SOUL_LEECH_CASTER_MANA_1
@ SPELL_WARLOCK_GLYPH_OF_DRAIN_SOUL_PROC
@ SPELL_WARLOCK_GLYPH_OF_DRAIN_SOUL_AURA
@ SPELL_WARLOCK_IMPROVED_HEALTH_FUNNEL_R1
@ SPELL_WARLOCK_SHADOW_TRANCE
@ SPELL_WARLOCK_LIFE_TAP_ENERGIZE_2
@ SPELL_WARLOCK_DEMONIC_EMPOWERMENT_FELGUARD
@ SPELL_WARLOCK_SOUL_LEECH_PET_MANA_2
@ SPELL_WARLOCK_SEED_OF_CORRUPTION_GENERIC
@ SPELL_WARLOCK_DEVOUR_MAGIC_HEAL
@ SPELL_WARLOCK_HAUNT
@ SPELL_WARLOCK_DRAIN_SOUL_R1
@ SPELL_WARLOCK_CREATE_SOULWELL_R1_IMP_HS_R1
@ SPELL_WARLOCK_SOULSHATTER_EFFECT
@ SPELL_WARLOCK_SEED_OF_CORRUPTION_DAMAGE_R1
@ SPELL_WARLOCK_DEMONIC_EMPOWERMENT_FELHUNTER
@ SPELL_WARLOCK_FEL_SYNERGY_HEAL
@ SPELL_WARLOCK_IMPROVED_DRAIN_SOUL_PROC
@ SPELL_WARLOCK_LIFE_TAP_ENERGIZE
@ SPELL_WARLOCK_DEMONIC_EMPOWERMENT_VOIDWALKER
@ SPELL_WARLOCK_SOUL_LEECH_HEAL
@ SPELL_WARLOCK_DEMONIC_CIRCLE_ALLOW_CAST
@ SPELL_WARLOCK_CREATE_SOULSHARD
@ SPELL_WARLOCK_CREATE_SOULWELL_R1
@ SPELL_WARLOCK_GLYPH_OF_SUCCUBUS
@ SPELL_WARLOCK_GLYPH_OF_SHADOWFLAME
@ SPELL_REPLENISHMENT
@ SPELL_WARLOCK_FLAMESHADOW
@ SPELL_WARLOCK_IMPROVED_HEALTHSTONE_R1
@ SPELL_WARLOCK_CREATE_SOULWELL_R2_IMP_HS_R1
@ SPELL_WARLOCK_NETHER_PROTECTION_NATURE
@ SPELL_WARLOCK_GLYPH_OF_SIPHON_LIFE
@ SPELL_WARLOCK_UNSTABLE_AFFLICTION_DISPEL
@ SPELL_WARLOCK_DEMONIC_EMPOWERMENT_IMP
@ SPELL_WARLOCK_CREATE_SOULWELL_R1_IMP_HS_R2
@ SPELL_WARLOCK_NETHER_PROTECTION_HOLY
@ SPELL_WARLOCK_IMPROVED_HEALTHSTONE_R2
@ SPELL_WARLOCK_NETHER_PROTECTION_SHADOW
@ SPELL_WARLOCK_IMPROVED_HEALTH_FUNNEL_R2
@ SPELL_WARLOCK_IMPROVED_HEALTH_FUNNEL_BUFF_R1
@ SPELL_WARLOCK_CREATE_SOULWELL_R2_IMP_HS_R2
WarlockSpellIcons
@ WARLOCK_ICON_ID_MANA_FEED
@ WARLOCK_ICON_ID_IMPROVED_LIFE_TAP
@ WARLOCK_ICON_ID_DEMONIC_PACT
CastSpellExtraArgs & AddSpellBP0(int32 val)
CastSpellExtraArgs & AddSpellMod(SpellValueMod mod, int32 val)
ObjectGuid OriginalCaster
CreatureFamily family