diff options
-rw-r--r-- | sql/updates/world/2013_09_06_02_world_misc.sql | 4 | ||||
-rw-r--r-- | src/server/game/Spells/SpellEffects.cpp | 9 | ||||
-rw-r--r-- | src/server/scripts/Spells/spell_quest.cpp | 7 |
3 files changed, 8 insertions, 12 deletions
diff --git a/sql/updates/world/2013_09_06_02_world_misc.sql b/sql/updates/world/2013_09_06_02_world_misc.sql new file mode 100644 index 00000000000..47ac870f977 --- /dev/null +++ b/sql/updates/world/2013_09_06_02_world_misc.sql @@ -0,0 +1,4 @@ +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=28481; +DELETE FROM `smart_scripts` WHERE `entryorguid`=28481 AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(28481, 0, 0, 0, 8, 0, 100, 0, 51769, 0, 0, 0, 11, 51738, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Runeforge (SE) - On Spellhit Emblazon Runeblade - Cast Shadow Storm'); diff --git a/src/server/game/Spells/SpellEffects.cpp b/src/server/game/Spells/SpellEffects.cpp index edb2139bd46..98c188df08f 100644 --- a/src/server/game/Spells/SpellEffects.cpp +++ b/src/server/game/Spells/SpellEffects.cpp @@ -3879,15 +3879,6 @@ void Spell::EffectScriptEffect(SpellEffIndex effIndex) npc->LoadEquipment(); return; } - // Emblazon Runeblade - case 51770: - { - if (!m_originalCaster) - return; - - m_originalCaster->CastSpell(m_originalCaster, damage, false); - break; - } // Deathbolt from Thalgran Blightbringer // reflected by Freya's Ward // Retribution by Sevenfold Retribution diff --git a/src/server/scripts/Spells/spell_quest.cpp b/src/server/scripts/Spells/spell_quest.cpp index 85f655372c6..6b56c51d6e1 100644 --- a/src/server/scripts/Spells/spell_quest.cpp +++ b/src/server/scripts/Spells/spell_quest.cpp @@ -2118,12 +2118,13 @@ class spell_q12619_emblazon_runeblade : public SpellScriptLoader void HandleEffectPeriodic(AuraEffect const* aurEff) { PreventDefaultAction(); - GetCaster()->CastSpell(GetCaster(), GetSpellInfo()->Effects[aurEff->GetEffIndex()].TriggerSpell, true); + if (Unit* caster = GetCaster()) + caster->CastSpell(caster, GetSpellInfo()->Effects[aurEff->GetEffIndex()].TriggerSpell, true, NULL, aurEff); } void Register() OVERRIDE { - OnEffectPeriodic += AuraEffectPeriodicFn(spell_q12619_emblazon_runeblade_AuraScript::HandleEffectPeriodic, EFFECT_0, SPELL_AURA_PERIODIC_HEAL); + OnEffectPeriodic += AuraEffectPeriodicFn(spell_q12619_emblazon_runeblade_AuraScript::HandleEffectPeriodic, EFFECT_0, SPELL_AURA_PERIODIC_TRIGGER_SPELL); } }; @@ -2145,7 +2146,7 @@ class spell_q12619_emblazon_runeblade_effect : public SpellScriptLoader void HandleScript(SpellEffIndex /*effIndex*/) { - GetCaster()->CastSpell(GetCaster(), uint32(GetEffectValue()), true); + GetCaster()->CastSpell(GetCaster(), uint32(GetEffectValue()), false); } void Register() OVERRIDE |