aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVincent-Michael <Vincent_Michael@gmx.de>2013-07-23 03:02:42 +0200
committerVincent-Michael <Vincent_Michael@gmx.de>2013-07-23 03:02:42 +0200
commit62944c6d8da6b05b0106e633d5e3f53c6e3fa08e (patch)
tree4bd6a6a36aa73787c290edcbdf7b9d3eddb1bfc9
parent7f7852b750967834f3a6360fa6ab3db14e565568 (diff)
Core/Spells: Small cleanup
-rw-r--r--src/server/scripts/Spells/spell_shaman.cpp20
1 files changed, 9 insertions, 11 deletions
diff --git a/src/server/scripts/Spells/spell_shaman.cpp b/src/server/scripts/Spells/spell_shaman.cpp
index 3fcf767ef75..6b78c3e4c44 100644
--- a/src/server/scripts/Spells/spell_shaman.cpp
+++ b/src/server/scripts/Spells/spell_shaman.cpp
@@ -128,8 +128,7 @@ class spell_sha_ancestral_awakening_proc : public SpellScriptLoader
void HandleDummy(SpellEffIndex /*effIndex*/)
{
- int32 damage = GetEffectValue();
- GetCaster()->CastCustomSpell(GetHitUnit(), SPELL_SHAMAN_ANCESTRAL_AWAKENING_PROC, &damage, NULL, NULL, true);
+ GetCaster()->CastCustomSpell(SPELL_SHAMAN_ANCESTRAL_AWAKENING_PROC, SPELLVALUE_BASE_POINT0, GetEffectValue(), GetHitUnit(), true);
}
void Register() OVERRIDE
@@ -259,9 +258,8 @@ class spell_sha_earth_shield : public SpellScriptLoader
bool Validate(SpellInfo const* /*spellInfo*/) OVERRIDE
{
- if (!sSpellMgr->GetSpellInfo(SPELL_SHAMAN_EARTH_SHIELD_HEAL))
- return false;
- if (!sSpellMgr->GetSpellInfo(SPELL_SHAMAN_GLYPH_OF_EARTH_SHIELD))
+ if (!sSpellMgr->GetSpellInfo(SPELL_SHAMAN_EARTH_SHIELD_HEAL) ||
+ !sSpellMgr->GetSpellInfo(SPELL_SHAMAN_GLYPH_OF_EARTH_SHIELD))
return false;
return true;
}
@@ -322,7 +320,8 @@ class spell_sha_earthbind_totem : public SpellScriptLoader
bool Validate(SpellInfo const* /*spellInfo*/) OVERRIDE
{
- if (!sSpellMgr->GetSpellInfo(SPELL_SHAMAN_TOTEM_EARTHBIND_TOTEM) || !sSpellMgr->GetSpellInfo(SPELL_SHAMAN_TOTEM_EARTHEN_POWER))
+ if (!sSpellMgr->GetSpellInfo(SPELL_SHAMAN_TOTEM_EARTHBIND_TOTEM) ||
+ !sSpellMgr->GetSpellInfo(SPELL_SHAMAN_TOTEM_EARTHEN_POWER))
return false;
return true;
}
@@ -494,9 +493,8 @@ class spell_sha_flame_shock : public SpellScriptLoader
bool Validate(SpellInfo const* /*spell*/) OVERRIDE
{
- if (!sSpellMgr->GetSpellInfo(SPELL_SHAMAN_LAVA_FLOWS_R1))
- return false;
- if (!sSpellMgr->GetSpellInfo(SPELL_SHAMAN_LAVA_FLOWS_TRIGGERED_R1))
+ if (!sSpellMgr->GetSpellInfo(SPELL_SHAMAN_LAVA_FLOWS_R1) ||
+ !sSpellMgr->GetSpellInfo(SPELL_SHAMAN_LAVA_FLOWS_TRIGGERED_R1))
return false;
return true;
}
@@ -799,9 +797,9 @@ class spell_sha_item_mana_surge : public SpellScriptLoader
{
PreventDefaultAction();
int32 mana = eventInfo.GetDamageInfo()->GetSpellInfo()->CalcPowerCost(GetTarget(), SpellSchoolMask(eventInfo.GetDamageInfo()->GetSchoolMask()));
- int32 basePoints0 = int32(CalculatePct(mana, 35));
+ mana = int32(CalculatePct(mana, 35));
- GetTarget()->CastCustomSpell(GetTarget(), SPELL_SHAMAN_ITEM_MANA_SURGE, &basePoints0, NULL, NULL, true, NULL, aurEff);
+ GetTarget()->CastCustomSpell(SPELL_SHAMAN_ITEM_MANA_SURGE, SPELLVALUE_BASE_POINT0, mana, GetTarget(), true, NULL, aurEff);
}
void Register() OVERRIDE