TrinityCore
spell_monk.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_MONK and SPELLFAMILY_GENERIC spells used by monk players.
20 * Scriptnames of files in this file should be prefixed with "spell_monk_".
21 */
22
23#include "ScriptMgr.h"
24#include "DB2Stores.h"
25#include "Player.h"
26#include "Spell.h"
27#include "SpellAuraEffects.h"
28#include "SpellInfo.h"
29#include "SpellMgr.h"
30#include "SpellScript.h"
31
33{
54};
55
56// 117952 - Crackling Jade Lightning
58{
59 bool Validate(SpellInfo const* /*spellInfo*/) override
60 {
61 return ValidateSpellInfo(
62 {
65 });
66 }
67
68 void OnTick(AuraEffect const* /*aurEff*/)
69 {
70 if (Unit* caster = GetCaster())
71 if (caster->HasAura(SPELL_MONK_STANCE_OF_THE_SPIRITED_CRANE))
73 }
74
75 void Register() override
76 {
78 }
79};
80
81// 117959 - Crackling Jade Lightning
83{
84 bool Validate(SpellInfo const* /*spellInfo*/) override
85 {
86 return ValidateSpellInfo(
87 {
90 });
91 }
92
93 bool CheckProc(ProcEventInfo& eventInfo)
94 {
96 return false;
97
99 return false;
100
101 Spell* currentChanneledSpell = GetTarget()->GetCurrentSpell(CURRENT_CHANNELED_SPELL);
102 if (!currentChanneledSpell || currentChanneledSpell->GetSpellInfo()->Id != SPELL_MONK_CRACKLING_JADE_LIGHTNING_CHANNEL)
103 return false;
104
105 return true;
106 }
107
108 void HandleProc(AuraEffect* /*aurEff*/, ProcEventInfo& eventInfo)
109 {
112 }
113
114 void Register() override
115 {
118 }
119};
120
121// 116849 - Life Cocoon
123{
124 bool Validate(SpellInfo const* /*spellInfo*/) override
125 {
127 }
128
130 {
132 if (Player* player = GetCaster()->ToPlayer())
133 AddPct(absorb, player->GetRatingBonusValue(CR_VERSATILITY_HEALING_DONE));
134
135 if (AuraEffect* calmingCoalescence = GetCaster()->GetAuraEffect(SPELL_MONK_CALMING_COALESCENCE, EFFECT_0, GetCaster()->GetGUID()))
136 {
137 AddPct(absorb, calmingCoalescence->GetAmount());
138 calmingCoalescence->GetBase()->Remove();
139 }
140
142 }
143
144 void Register() override
145 {
147 }
148};
149
150// 392972 - Open Palm Strikes
152{
153 bool Validate(SpellInfo const* /*spellInfo*/) override
154 {
156 }
157
158 bool CheckProc(AuraEffect const* /*aurEff*/, ProcEventInfo& /*procInfo*/)
159 {
161 return talent && roll_chance_i(talent->GetAmount());
162 }
163
164 void Register() override
165 {
167 }
168};
169
170// 121817 - Power Strike
172{
173 bool Validate(SpellInfo const* /*spellInfo*/) override
174 {
176 }
177
178 void HandlePeriodic(AuraEffect const* /*aurEff*/)
179 {
181 }
182
183 void Register() override
184 {
186 }
187};
188
189// 129914 - Power Strike Proc
191{
192 bool Validate(SpellInfo const* /*spellInfo*/) override
193 {
195 }
196
197 void HandleProc(AuraEffect* /*aurEff*/, ProcEventInfo& /*eventInfo*/)
198 {
200 }
201
202 void Register() override
203 {
205 }
206};
207
208// 115546 - Provoke
210{
211 static uint32 const BlackOxStatusEntry = 61146;
212
213 bool Validate(SpellInfo const* spellInfo) override
214 {
215 if (!(spellInfo->GetExplicitTargetMask() & TARGET_FLAG_UNIT_MASK)) // ensure GetExplTargetUnit() will return something meaningful during CheckCast
216 return false;
217 return ValidateSpellInfo(
218 {
221 });
222 }
223
225 {
227 {
228 SpellInfo const* singleTarget = sSpellMgr->AssertSpellInfo(SPELL_MONK_PROVOKE_SINGLE_TARGET, GetCastDifficulty());
229 SpellCastResult singleTargetExplicitResult = singleTarget->CheckExplicitTarget(GetCaster(), GetExplTargetUnit());
230 if (singleTargetExplicitResult != SPELL_CAST_OK)
231 return singleTargetExplicitResult;
232 }
233 else if (GetExplTargetUnit()->GetOwnerGUID() != GetCaster()->GetGUID())
235
236 return SPELL_CAST_OK;
237 }
238
240 {
241 PreventHitDefaultEffect(effIndex);
244 else
246 }
247
248 void Register() override
249 {
252 }
253};
254
255// 109132 - Roll
257{
258 bool Validate(SpellInfo const* /*spellInfo*/) override
259 {
261 }
262
264 {
265 if (GetCaster()->HasUnitState(UNIT_STATE_ROOT))
266 return SPELL_FAILED_ROOTED;
267 return SPELL_CAST_OK;
268 }
269
270 void HandleDummy(SpellEffIndex /*effIndex*/)
271 {
275 }
276
277 void Register() override
278 {
281 }
282};
283
284// 107427 - Roll
285// 109131 - Roll (backward)
287{
288 void CalcMovementAmount(AuraEffect const* /*aurEff*/, int32& amount, bool& /*canBeRecalculated*/)
289 {
290 amount += 100;
291 }
292
293 void CalcImmunityAmount(AuraEffect const* /*aurEff*/, int32& amount, bool& /*canBeRecalculated*/)
294 {
295 amount -= 100;
296 }
297
298 void ChangeRunBackSpeed(AuraEffect const* /*aurEff*/, AuraEffectHandleModes /*mode*/)
299 {
301 }
302
303 void RestoreRunBackSpeed(AuraEffect const* /*aurEff*/, AuraEffectHandleModes /*mode*/)
304 {
306 }
307
308 void Register() override
309 {
310 // Values need manual correction
315
316 // This is a special aura that sets backward run speed equal to forward speed
319 }
320};
321
322// Utility for stagger scripts
324{
325 if (Aura* auraLight = unit->GetAura(SPELL_MONK_STAGGER_LIGHT))
326 return auraLight;
327
328 if (Aura* auraModerate = unit->GetAura(SPELL_MONK_STAGGER_MODERATE))
329 return auraModerate;
330
331 if (Aura* auraHeavy = unit->GetAura(SPELL_MONK_STAGGER_HEAVY))
332 return auraHeavy;
333
334 return nullptr;
335}
336
339
340// 115069 - Stagger
342{
343 bool Validate(SpellInfo const* /*spellInfo*/) override
344 {
346 }
347
348 void AbsorbNormal(AuraEffect* /*aurEff*/, DamageInfo& dmgInfo, uint32& /*absorbAmount*/)
349 {
350 Absorb(dmgInfo, 1.0f);
351 }
352
353 void AbsorbMagic(AuraEffect* /*aurEff*/, DamageInfo& dmgInfo, uint32& /*absorbAmount*/)
354 {
355 AuraEffect const* effect = GetEffect(EFFECT_4);
356 if (!effect)
357 return;
358
359 Absorb(dmgInfo, float(effect->GetAmount()) / 100.0f);
360 }
361
362 void Absorb(DamageInfo& dmgInfo, float multiplier)
363 {
364 // Prevent default action (which would remove the aura)
366
367 // make sure damage doesn't come from stagger damage spell SPELL_MONK_STAGGER_DAMAGE_AURA
368 if (SpellInfo const* dmgSpellInfo = dmgInfo.GetSpellInfo())
369 if (dmgSpellInfo->Id == SPELL_MONK_STAGGER_DAMAGE_AURA)
370 return;
371
373 if (!effect)
374 return;
375
376 Unit* target = GetTarget();
377 float agility = target->GetStat(STAT_AGILITY);
378 float base = CalculatePct(agility, float(effect->GetAmount()));
379 float K = sDB2Manager.EvaluateExpectedStat(ExpectedStatType::ArmorConstant, target->GetLevel(), -2, 0, Classes(target->GetClass()), 0);
380
381 float newAmount = (base / (base + K));
382 newAmount *= multiplier;
383
384 // Absorb X percentage of the damage
385 float absorbAmount = float(dmgInfo.GetDamage()) * newAmount;
386 if (absorbAmount > 0)
387 {
388 dmgInfo.AbsorbDamage(absorbAmount);
389
390 // Cast stagger and make it tick on each tick
391 AddAndRefreshStagger(absorbAmount);
392 }
393 }
394
395 void Register() override
396 {
399 }
400
401private:
402 void AddAndRefreshStagger(float amount)
403 {
404 Unit* target = GetTarget();
405 if (Aura* auraStagger = FindExistingStaggerEffect(target))
406 {
407 AuraEffect* effStaggerRemaining = auraStagger->GetEffect(AuraStaggerEffectTotal);
408 if (!effStaggerRemaining)
409 return;
410
411 float newAmount = effStaggerRemaining->GetAmount() + amount;
412 uint32 spellId = GetStaggerSpellId(target, newAmount);
413 if (spellId == effStaggerRemaining->GetSpellInfo()->Id)
414 {
415 auraStagger->RefreshDuration();
416 effStaggerRemaining->ChangeAmount(newAmount, false, true /* reapply */);
417 }
418 else
419 {
420 // amount changed the stagger type so we need to change the stagger amount (e.g. from medium to light)
421 GetTarget()->RemoveAura(auraStagger);
422 AddNewStagger(target, spellId, newAmount);
423 }
424 }
425 else
426 AddNewStagger(target, GetStaggerSpellId(target, amount), amount);
427 }
428
429 uint32 GetStaggerSpellId(Unit* unit, float amount)
430 {
431 const float StaggerHeavy = 0.6f;
432 const float StaggerModerate = 0.3f;
433
434 float staggerPct = amount / float(unit->GetMaxHealth());
435 return (staggerPct >= StaggerHeavy) ? SPELL_MONK_STAGGER_HEAVY :
436 (staggerPct >= StaggerModerate) ? SPELL_MONK_STAGGER_MODERATE :
438 }
439
440 void AddNewStagger(Unit* unit, uint32 staggerSpellId, float staggerAmount)
441 {
442 // We only set the total stagger amount. The amount per tick will be set by the stagger spell script
443 unit->CastSpell(unit, staggerSpellId, CastSpellExtraArgs(SPELLVALUE_BASE_POINT1, staggerAmount).SetTriggerFlags(TRIGGERED_FULL_MASK));
444 }
445};
446
447// 124255 - Stagger - SPELL_MONK_STAGGER_DAMAGE_AURA
449{
450 bool Validate(SpellInfo const* /*spellInfo*/) override
451 {
453 }
454
455 void OnPeriodicDamage(AuraEffect const* aurEff)
456 {
457 // Update our light/medium/heavy stagger with the correct stagger amount left
458 if (Aura* auraStagger = FindExistingStaggerEffect(GetTarget()))
459 {
460 if (AuraEffect* auraEff = auraStagger->GetEffect(AuraStaggerEffectTotal))
461 {
462 float total = float(auraEff->GetAmount());
463 float tickDamage = float(aurEff->GetAmount());
464 auraEff->ChangeAmount(total - tickDamage);
465 }
466 }
467 }
468
469 void Register() override
470 {
472 }
473};
474
475// 124273, 124274, 124275 - Light/Moderate/Heavy Stagger - SPELL_MONK_STAGGER_LIGHT / SPELL_MONK_STAGGER_MODERATE / SPELL_MONK_STAGGER_HEAVY
477{
478 bool Validate(SpellInfo const* /*spellInfo*/) override
479 {
482 }
483
484 bool Load() override
485 {
486 _period = float(sSpellMgr->AssertSpellInfo(SPELL_MONK_STAGGER_DAMAGE_AURA, GetCastDifficulty())->GetEffect(EFFECT_0).ApplyAuraPeriod);
487 return true;
488 }
489
490 void OnReapply(AuraEffect const* aurEff, AuraEffectHandleModes /*mode*/)
491 {
492 // Calculate damage per tick
493 float total = float(aurEff->GetAmount());
494 float perTick = total * _period / float(GetDuration()); // should be same as GetMaxDuration() TODO: verify
495
496 // Set amount on effect for tooltip
498 if (effInfo)
499 effInfo->ChangeAmount(perTick);
500
501 // Set amount on damage aura (or cast it if needed)
502 CastOrChangeTickDamage(perTick);
503 }
504
505 void OnRemove(AuraEffect const* /*aurEff*/, AuraEffectHandleModes mode)
506 {
507 if (mode != AURA_EFFECT_HANDLE_REAL)
508 return;
509
510 // Remove damage aura
512 }
513
514 void Register() override
515 {
518 }
519
520private:
521 float _period = 0.0f;
522
523 void CastOrChangeTickDamage(float tickDamage)
524 {
525 Unit* unit = GetTarget();
526 Aura* auraDamage = unit->GetAura(SPELL_MONK_STAGGER_DAMAGE_AURA);
527 if (!auraDamage)
528 {
529 unit->CastSpell(unit, SPELL_MONK_STAGGER_DAMAGE_AURA, true);
530 auraDamage = unit->GetAura(SPELL_MONK_STAGGER_DAMAGE_AURA);
531 }
532
533 if (auraDamage)
534 if (AuraEffect* eff = auraDamage->GetEffect(AuraStaggerEffectTick))
535 eff->ChangeAmount(tickDamage);
536 }
537};
538
540{
553}
T GetEntry(std::unordered_map< uint32, T > const &map, CriteriaTreeEntry const *tree)
#define sDB2Manager
Definition: DB2Stores.h:538
int32_t int32
Definition: Define.h:138
uint32_t uint32
Definition: Define.h:142
bool roll_chance_i(int chance)
Definition: Random.h:59
#define RegisterSpellScript(spell_script)
Definition: ScriptMgr.h:1369
SpellEffIndex
Definition: SharedDefines.h:29
@ EFFECT_6
Definition: SharedDefines.h:36
@ EFFECT_1
Definition: SharedDefines.h:31
@ EFFECT_5
Definition: SharedDefines.h:35
@ EFFECT_0
Definition: SharedDefines.h:30
@ EFFECT_4
Definition: SharedDefines.h:34
@ EFFECT_2
Definition: SharedDefines.h:32
Classes
@ SPELL_EFFECT_DUMMY
SpellCastResult
@ SPELL_FAILED_ROOTED
@ SPELL_FAILED_BAD_TARGETS
@ SPELL_CAST_OK
@ STAT_AGILITY
AuraEffectHandleModes
@ AURA_EFFECT_HANDLE_REAL_OR_REAPPLY_MASK
@ AURA_EFFECT_HANDLE_REAL
@ SPELL_AURA_PERIODIC_DAMAGE
@ SPELL_AURA_PROC_TRIGGER_SPELL
@ SPELL_AURA_DUMMY
@ SPELL_AURA_MECHANIC_IMMUNITY
@ SPELL_AURA_MOD_MINIMUM_SPEED
@ SPELL_AURA_MOD_SPEED_NO_CONTROL
@ SPELL_AURA_PERIODIC_DUMMY
@ SPELL_AURA_USE_NORMAL_MOVEMENT_SPEED
@ TARGET_FLAG_UNIT_MASK
Definition: SpellDefines.h:307
@ TRIGGERED_FULL_MASK
Used when doing CastSpell with triggered == true.
Definition: SpellDefines.h:266
@ TRIGGERED_IGNORE_CAST_IN_PROGRESS
Will not check if a current cast is in progress.
Definition: SpellDefines.h:252
@ SPELLVALUE_BASE_POINT1
Definition: SpellDefines.h:197
@ SPELLVALUE_BASE_POINT0
Definition: SpellDefines.h:196
#define sSpellMgr
Definition: SpellMgr.h:849
#define SpellCheckCastFn(F)
Definition: SpellScript.h:830
#define AuraEffectProcFn(F, I, N)
Definition: SpellScript.h:2160
#define SpellEffectFn(F, I, N)
Definition: SpellScript.h:842
#define AuraEffectCalcAmountFn(F, I, N)
Definition: SpellScript.h:2058
#define AuraEffectPeriodicFn(F, I, N)
Definition: SpellScript.h:2046
#define AuraCheckEffectProcFn(F, I, N)
Definition: SpellScript.h:2136
#define AuraEffectAbsorbFn(F, I)
Definition: SpellScript.h:2090
#define AuraEffectApplyFn(F, I, N, M)
Definition: SpellScript.h:2029
#define AuraCheckProcFn(F)
Definition: SpellScript.h:2130
#define AuraEffectRemoveFn(F, I, N, M)
Definition: SpellScript.h:2040
@ MOVE_RUN
Definition: UnitDefines.h:118
@ MOVE_RUN_BACK
Definition: UnitDefines.h:119
@ MOVEMENTFLAG_BACKWARD
Definition: UnitDefines.h:359
@ CURRENT_CHANNELED_SPELL
Definition: Unit.h:591
@ UNIT_STATE_ROOT
Definition: Unit.h:265
@ CR_VERSATILITY_HEALING_DONE
Definition: Unit.h:340
T AddPct(T &base, U pct)
Definition: Util.h:85
T CalculatePct(T base, U pct)
Definition: Util.h:72
SpellInfo const * GetSpellInfo() const
void ChangeAmount(int32 newAmount, bool mark=true, bool onStackOrReapply=false, AuraEffect const *triggeredBy=nullptr)
int32 GetAmount() const
void PreventDefaultAction()
int32 GetDuration() const
HookList< EffectApplyHandler > AfterEffectRemove
Definition: SpellScript.h:2039
HookList< CheckEffectProcHandler > DoCheckEffectProc
Definition: SpellScript.h:2135
HookList< EffectPeriodicHandler > OnEffectPeriodic
Definition: SpellScript.h:2045
HookList< EffectApplyHandler > AfterEffectApply
Definition: SpellScript.h:2028
HookList< EffectCalcAmountHandler > DoEffectCalcAmount
Definition: SpellScript.h:2057
Unit * GetCaster() const
AuraEffect * GetEffect(uint8 effIndex) const
HookList< EffectAbsorbHandler > OnEffectAbsorb
Definition: SpellScript.h:2089
Aura * GetAura() const
Unit * GetTarget() const
Difficulty GetCastDifficulty() const
HookList< CheckProcHandler > DoCheckProc
Definition: SpellScript.h:2129
HookList< EffectProcHandler > OnEffectProc
Definition: SpellScript.h:2155
AuraEffect * GetEffect(uint32 index) const
Definition: SpellAuras.cpp:529
void AbsorbDamage(uint32 amount)
Definition: Unit.cpp:211
SpellInfo const * GetSpellInfo() const
Definition: Unit.h:442
uint32 GetDamage() const
Definition: Unit.h:446
Unit * GetActor() const
Definition: Unit.h:493
uint32 const Id
Definition: SpellInfo.h:325
uint32 GetExplicitTargetMask() const
Definition: SpellInfo.cpp:2533
SpellCastResult CheckExplicitTarget(WorldObject const *caster, WorldObject const *target, Item const *itemTarget=nullptr) const
Definition: SpellInfo.cpp:2359
static bool ValidateSpellInfo(std::initializer_list< uint32 > spellIds)
Definition: SpellScript.h:162
static bool ValidateSpellEffect(std::initializer_list< std::pair< uint32, SpellEffIndex > > effects)
Definition: SpellScript.h:173
HookList< CheckCastHandler > OnCheckCast
Definition: SpellScript.h:829
Unit * GetCaster() const
void PreventHitDefaultEffect(SpellEffIndex effIndex)
Unit * GetHitUnit() const
int32 GetEffectValue() const
HookList< EffectHandler > OnEffectHitTarget
Definition: SpellScript.h:840
Spell * GetSpell() const
Definition: SpellScript.h:987
Difficulty GetCastDifficulty() const
HookList< EffectHandler > OnEffectLaunch
Definition: SpellScript.h:837
Unit * GetExplTargetUnit() const
Definition: Spell.h:255
SpellInfo const * GetSpellInfo() const
Definition: Spell.h:650
void SetSpellValue(SpellValueMod mod, int32 value)
Definition: Spell.cpp:8566
Definition: Unit.h:627
void RemoveAura(AuraApplicationMap::iterator &i, AuraRemoveMode mode=AURA_REMOVE_BY_DEFAULT)
Definition: Unit.cpp:3685
uint8 GetClass() const
Definition: Unit.h:752
void UpdateSpeed(UnitMoveType mtype)
Definition: Unit.cpp:8361
void SetSpeed(UnitMoveType mtype, float newValue)
Definition: Unit.cpp:8520
AuraEffect * GetAuraEffect(uint32 spellId, uint8 effIndex, ObjectGuid casterGUID=ObjectGuid::Empty) const
Definition: Unit.cpp:4464
uint64 GetMaxHealth() const
Definition: Unit.h:777
Aura * GetAura(uint32 spellId, ObjectGuid casterGUID=ObjectGuid::Empty, ObjectGuid itemCasterGUID=ObjectGuid::Empty, uint32 reqEffMask=0) const
Definition: Unit.cpp:4560
uint64 CountPctFromMaxHealth(int32 pct) const
Definition: Unit.h:785
bool HasAura(uint32 spellId, ObjectGuid casterGUID=ObjectGuid::Empty, ObjectGuid itemCasterGUID=ObjectGuid::Empty, uint32 reqEffMask=0) const
Definition: Unit.cpp:4664
float GetStat(Stats stat) const
Definition: Unit.h:760
uint8 GetLevel() const
Definition: Unit.h:746
Spell * GetCurrentSpell(CurrentSpellTypes spellType) const
Definition: Unit.h:1442
SpellCastResult CastSpell(CastSpellTargetArg const &targets, uint32 spellId, CastSpellExtraArgs const &args={ })
Definition: Object.cpp:2896
void HandleProc(AuraEffect *, ProcEventInfo &eventInfo)
Definition: spell_monk.cpp:108
bool Validate(SpellInfo const *) override
Definition: spell_monk.cpp:59
void OnTick(AuraEffect const *)
Definition: spell_monk.cpp:68
void Register() override
Definition: spell_monk.cpp:144
bool Validate(SpellInfo const *) override
Definition: spell_monk.cpp:124
void CalculateAbsorb(SpellEffIndex)
Definition: spell_monk.cpp:129
bool Validate(SpellInfo const *) override
Definition: spell_monk.cpp:153
bool CheckProc(AuraEffect const *, ProcEventInfo &)
Definition: spell_monk.cpp:158
void HandlePeriodic(AuraEffect const *)
Definition: spell_monk.cpp:178
bool Validate(SpellInfo const *) override
Definition: spell_monk.cpp:173
void HandleProc(AuraEffect *, ProcEventInfo &)
Definition: spell_monk.cpp:197
bool Validate(SpellInfo const *) override
Definition: spell_monk.cpp:192
void HandleDummy(SpellEffIndex effIndex)
Definition: spell_monk.cpp:239
static uint32 const BlackOxStatusEntry
Definition: spell_monk.cpp:211
bool Validate(SpellInfo const *spellInfo) override
Definition: spell_monk.cpp:213
void Register() override
Definition: spell_monk.cpp:248
SpellCastResult CheckExplicitTarget()
Definition: spell_monk.cpp:224
void RestoreRunBackSpeed(AuraEffect const *, AuraEffectHandleModes)
Definition: spell_monk.cpp:303
void CalcImmunityAmount(AuraEffect const *, int32 &amount, bool &)
Definition: spell_monk.cpp:293
void Register() override
Definition: spell_monk.cpp:308
void CalcMovementAmount(AuraEffect const *, int32 &amount, bool &)
Definition: spell_monk.cpp:288
void ChangeRunBackSpeed(AuraEffect const *, AuraEffectHandleModes)
Definition: spell_monk.cpp:298
void Register() override
Definition: spell_monk.cpp:277
bool Validate(SpellInfo const *) override
Definition: spell_monk.cpp:258
SpellCastResult CheckCast()
Definition: spell_monk.cpp:263
void HandleDummy(SpellEffIndex)
Definition: spell_monk.cpp:270
bool Validate(SpellInfo const *) override
Definition: spell_monk.cpp:450
void OnPeriodicDamage(AuraEffect const *aurEff)
Definition: spell_monk.cpp:455
void OnReapply(AuraEffect const *aurEff, AuraEffectHandleModes)
Definition: spell_monk.cpp:490
void CastOrChangeTickDamage(float tickDamage)
Definition: spell_monk.cpp:523
bool Validate(SpellInfo const *) override
Definition: spell_monk.cpp:478
void OnRemove(AuraEffect const *, AuraEffectHandleModes mode)
Definition: spell_monk.cpp:505
void AbsorbMagic(AuraEffect *, DamageInfo &dmgInfo, uint32 &)
Definition: spell_monk.cpp:353
void Absorb(DamageInfo &dmgInfo, float multiplier)
Definition: spell_monk.cpp:362
void AbsorbNormal(AuraEffect *, DamageInfo &dmgInfo, uint32 &)
Definition: spell_monk.cpp:348
void Register() override
Definition: spell_monk.cpp:395
void AddNewStagger(Unit *unit, uint32 staggerSpellId, float staggerAmount)
Definition: spell_monk.cpp:440
bool Validate(SpellInfo const *) override
Definition: spell_monk.cpp:343
void AddAndRefreshStagger(float amount)
Definition: spell_monk.cpp:402
uint32 GetStaggerSpellId(Unit *unit, float amount)
Definition: spell_monk.cpp:429
void AddSC_monk_spell_scripts()
Definition: spell_monk.cpp:539
Aura * FindExistingStaggerEffect(Unit *unit)
Definition: spell_monk.cpp:323
MonkSpells
Definition: spell_monk.cpp:33
@ SPELL_MONK_NO_FEATHER_FALL
Definition: spell_monk.cpp:43
@ SPELL_MONK_PROVOKE_AOE
Definition: spell_monk.cpp:42
@ SPELL_MONK_STAGGER_LIGHT
Definition: spell_monk.cpp:51
@ SPELL_MONK_CRACKLING_JADE_LIGHTNING_KNOCKBACK_CD
Definition: spell_monk.cpp:38
@ SPELL_MONK_CRACKLING_JADE_LIGHTNING_KNOCKBACK
Definition: spell_monk.cpp:37
@ SPELL_MONK_CRACKLING_JADE_LIGHTNING_CHANNEL
Definition: spell_monk.cpp:35
@ SPELL_MONK_POWER_STRIKE_ENERGIZE
Definition: spell_monk.cpp:40
@ SPELL_MONK_STAGGER_HEAVY
Definition: spell_monk.cpp:50
@ SPELL_MONK_OPEN_PALM_STRIKES_TALENT
Definition: spell_monk.cpp:44
@ SPELL_MONK_ROLL_BACKWARD
Definition: spell_monk.cpp:45
@ SPELL_MONK_STAGGER_MODERATE
Definition: spell_monk.cpp:52
@ SPELL_MONK_PROVOKE_SINGLE_TARGET
Definition: spell_monk.cpp:41
@ SPELL_MONK_STAGGER_DAMAGE_AURA
Definition: spell_monk.cpp:49
@ SPELL_MONK_POWER_STRIKE_PROC
Definition: spell_monk.cpp:39
@ SPELL_MONK_SURGING_MIST_HEAL
Definition: spell_monk.cpp:53
@ SPELL_MONK_ROLL_FORWARD
Definition: spell_monk.cpp:46
@ SPELL_MONK_CALMING_COALESCENCE
Definition: spell_monk.cpp:34
@ SPELL_MONK_STANCE_OF_THE_SPIRITED_CRANE
Definition: spell_monk.cpp:48
@ SPELL_MONK_CRACKLING_JADE_LIGHTNING_CHI_PROC
Definition: spell_monk.cpp:36
@ SPELL_MONK_SOOTHING_MIST
Definition: spell_monk.cpp:47
static constexpr SpellEffIndex AuraStaggerEffectTick
Definition: spell_monk.cpp:337
static constexpr SpellEffIndex AuraStaggerEffectTotal
Definition: spell_monk.cpp:338