aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorVincent-Michael <Vincent_Michael@gmx.de>2013-08-18 13:54:20 +0200
committerVincent-Michael <Vincent_Michael@gmx.de>2013-08-18 13:54:20 +0200
commit9eb01d63bd4cd3c2c297db4bcf1899debba0ee49 (patch)
tree39adddffd1ceb6f3ff4e71ae63a78753db7e3d21 /src
parent7dbf68cbfc36a819f1e259128a71cc7ce0517540 (diff)
Core: Fix warnings
Diffstat (limited to 'src')
-rw-r--r--src/server/game/Spells/Spell.cpp6
-rw-r--r--src/server/scripts/Spells/spell_hunter.cpp1
2 files changed, 3 insertions, 4 deletions
diff --git a/src/server/game/Spells/Spell.cpp b/src/server/game/Spells/Spell.cpp
index be88179b168..539b38bdac4 100644
--- a/src/server/game/Spells/Spell.cpp
+++ b/src/server/game/Spells/Spell.cpp
@@ -3052,12 +3052,12 @@ void Spell::prepare(SpellCastTargets const* targets, AuraEffect const* triggered
if (Player* player = m_caster->ToPlayer())
{
- if (!m_caster->ToPlayer()->GetCommandStatus(CHEAT_CASTTIME))
+ if (!player->GetCommandStatus(CHEAT_CASTTIME))
{
- m_caster->ToPlayer()->SetSpellModTakingSpell(this, true);
+ player->SetSpellModTakingSpell(this, true);
// calculate cast time (calculated after first CheckCast check to prevent charge counting for first CheckCast fail)
m_casttime = m_spellInfo->CalcCastTime(this);
- m_caster->ToPlayer()->SetSpellModTakingSpell(this, false);
+ player->SetSpellModTakingSpell(this, false);
}
else
m_casttime = 0; // Set cast time to 0 if .cheat casttime is enabled.
diff --git a/src/server/scripts/Spells/spell_hunter.cpp b/src/server/scripts/Spells/spell_hunter.cpp
index b8f29f276ae..b93efe3b0f2 100644
--- a/src/server/scripts/Spells/spell_hunter.cpp
+++ b/src/server/scripts/Spells/spell_hunter.cpp
@@ -149,7 +149,6 @@ class spell_hun_ascpect_of_the_viper : public SpellScriptLoader
void OnRemove(AuraEffect const* /*aurEff*/, AuraEffectHandleModes /*mode*/)
{
// Hunter T7 4P Bonus
- Unit* target = GetTarget();
if (GetTarget()->HasAura(SPELL_HUNTER_VIPER_ATTACK_SPEED))
GetTarget()->RemoveAurasDueToSpell(SPELL_HUNTER_VICIOUS_VIPER);
}