aboutsummaryrefslogtreecommitdiff
path: root/src/server/game/Spells/SpellEffects.cpp
diff options
context:
space:
mode:
authorRat <gmstreetrat@gmail.com>2011-11-26 20:38:25 +0100
committerRat <gmstreetrat@gmail.com>2011-11-26 20:38:25 +0100
commitca03e79ce787702f97f3b3e3a09e39646bedc28f (patch)
treef4df95bb5bf59823f002fd3e456f569936677283 /src/server/game/Spells/SpellEffects.cpp
parent8cf3fde3291e8fdadef564232c2981d670a1e274 (diff)
parentbc37c75dfde1882b208be13731f9ffdc54938d62 (diff)
Merge branch '4.x' of github.com:TrinityCore/TrinityCore into 4.x
Diffstat (limited to 'src/server/game/Spells/SpellEffects.cpp')
-rwxr-xr-xsrc/server/game/Spells/SpellEffects.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/server/game/Spells/SpellEffects.cpp b/src/server/game/Spells/SpellEffects.cpp
index a4cf8e6a469..e95203d97be 100755
--- a/src/server/game/Spells/SpellEffects.cpp
+++ b/src/server/game/Spells/SpellEffects.cpp
@@ -694,13 +694,13 @@ void Spell::EffectSchoolDMG(SpellEffIndex effIndex)
Item* item = m_caster->ToPlayer()->GetWeaponForAttack(RANGED_ATTACK);
if (item)
{
- float dmg_min = item->GetTemplate()->Damage->DamageMin;
- float dmg_max = item->GetTemplate()->Damage->DamageMax;
+ float dmg_min = item->GetTemplate()->DamageMin;
+ float dmg_max = item->GetTemplate()->DamageMax;
if (dmg_max == 0.0f && dmg_min > dmg_max)
damage += int32(dmg_min);
else
damage += irand(int32(dmg_min), int32(dmg_max));
- damage += int32(m_caster->ToPlayer()->GetAmmoDPS()*item->GetTemplate()->Delay*0.001f);
+ damage += int32(item->GetTemplate()->Delay*0.001f);
}
}
}
@@ -6195,6 +6195,7 @@ void Spell::EffectSelfResurrect(SpellEffIndex effIndex)
player->SetPower(POWER_MANA, mana);
player->SetPower(POWER_RAGE, 0);
player->SetPower(POWER_ENERGY, player->GetMaxPower(POWER_ENERGY));
+ player->SetPower(POWER_FOCUS, 0);
player->SpawnCorpseBones();
}
@@ -7343,7 +7344,7 @@ void Spell::EffectCastButtons(SpellEffIndex effIndex)
if (!(spellInfo->AttributesEx7 & SPELL_ATTR7_SUMMON_PLAYER_TOTEM))
continue;
- uint32 cost = spellInfo->CalcPowerCost(m_caster, spellInfo->GetSchoolMask());
+ int32 cost = spellInfo->CalcPowerCost(m_caster, spellInfo->GetSchoolMask());
if (m_caster->GetPower(POWER_MANA) < cost)
continue;