792 {
795
796 if (!caster || !target)
797 return;
799 uint32 tick = (aurEff->GetTickNumber() + 7) % 8;
800
801
803 if (tick <= 3)
805 else
806 target->
SetOrientation(forward - 0.75f * M_PI + (8 - tick) * M_PI / 8);
807
808 target->
CastSpell(target, spellForTick[tick],
true);
810 }
std::uint32_t uint32
Definition: Define.h:107
@ SPELL_SHADOW_BOLT_WHIRL6
Definition: boss_emerald_dragons.cpp:387
@ SPELL_SHADOW_BOLT_WHIRL5
Definition: boss_emerald_dragons.cpp:386
@ SPELL_SHADOW_BOLT_WHIRL4
Definition: boss_emerald_dragons.cpp:385
@ SPELL_SHADOW_BOLT_WHIRL3
Definition: boss_emerald_dragons.cpp:384
@ SPELL_SHADOW_BOLT_WHIRL7
Definition: boss_emerald_dragons.cpp:388
@ SPELL_SHADOW_BOLT_WHIRL1
Definition: boss_emerald_dragons.cpp:382
@ SPELL_SHADOW_BOLT_WHIRL2
Definition: boss_emerald_dragons.cpp:383
@ SPELL_SHADOW_BOLT_WHIRL8
Definition: boss_emerald_dragons.cpp:389
float GetOrientation() const
Definition: Position.h:119
void SetOrientation(float orientation)
Definition: Position.h:111
SpellCastResult CastSpell(SpellCastTargets const &targets, SpellInfo const *spellInfo, CustomSpellValues const *value, TriggerCastFlags triggerFlags=TRIGGERED_NONE, Item *castItem=nullptr, AuraEffect const *triggeredByAura=nullptr, ObjectGuid originalCaster=ObjectGuid::Empty)
Definition: Unit.cpp:1167
Unit * GetCaster() const
Definition: SpellScript.cpp:1020
Unit * GetTarget() const
Definition: SpellScript.cpp:1165