mirror of
https://github.com/liyunfan1223/azerothcore-wotlk.git
synced 2026-08-08 15:58:04 +00:00
fix(Scripts/Spells): Fix Dash applying bonuses in other forms (restor… (#17393)
fix(Scripts/Spells): Fix Dash applying bonuses in other forms (restores previous code functionality)
This commit is contained in:
@@ -410,6 +410,26 @@ class spell_dru_dash : public SpellScript
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// -1850 - Dash
|
||||||
|
class spell_dru_dash_aura : public AuraScript
|
||||||
|
{
|
||||||
|
PrepareAuraScript(spell_dru_dash_aura);
|
||||||
|
|
||||||
|
void CalculateAmount(AuraEffect const* /*aurEff*/, int32& amount, bool& /*canBeRecalculated*/)
|
||||||
|
{
|
||||||
|
// do not set speed if not in cat form
|
||||||
|
if (GetUnitOwner()->GetShapeshiftForm() != FORM_CAT)
|
||||||
|
{
|
||||||
|
amount = 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void Register() override
|
||||||
|
{
|
||||||
|
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_dru_dash_aura::CalculateAmount, EFFECT_0, SPELL_AURA_MOD_INCREASE_SPEED);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
// 5229 - Enrage
|
// 5229 - Enrage
|
||||||
class spell_dru_enrage : public AuraScript
|
class spell_dru_enrage : public AuraScript
|
||||||
{
|
{
|
||||||
@@ -1185,7 +1205,7 @@ void AddSC_druid_spell_scripts()
|
|||||||
RegisterSpellScript(spell_dru_barkskin);
|
RegisterSpellScript(spell_dru_barkskin);
|
||||||
RegisterSpellScript(spell_dru_treant_scaling);
|
RegisterSpellScript(spell_dru_treant_scaling);
|
||||||
RegisterSpellScript(spell_dru_berserk);
|
RegisterSpellScript(spell_dru_berserk);
|
||||||
RegisterSpellScript(spell_dru_dash);
|
RegisterSpellAndAuraScriptPair(spell_dru_dash, spell_dru_dash_aura);
|
||||||
RegisterSpellScript(spell_dru_enrage);
|
RegisterSpellScript(spell_dru_enrage);
|
||||||
RegisterSpellScript(spell_dru_glyph_of_starfire);
|
RegisterSpellScript(spell_dru_glyph_of_starfire);
|
||||||
RegisterSpellScript(spell_dru_idol_lifebloom);
|
RegisterSpellScript(spell_dru_idol_lifebloom);
|
||||||
|
|||||||
Reference in New Issue
Block a user