summaryrefslogtreecommitdiff
path: root/src/scripts/Spells/spell_dk.cpp
diff options
context:
space:
mode:
authorYehonal <yehonal.azeroth@gmail.com>2017-09-18 03:16:32 +0200
committerYehonal <yehonal.azeroth@gmail.com>2017-09-18 03:16:32 +0200
commit5ec07ef31ff972dbe3c3be3fdaab4ab8aad9512c (patch)
tree6b2126773aea642162afaeaa6db99103d55184ef /src/scripts/Spells/spell_dk.cpp
parentcf627d832717c990b02da5e5ba06b4f218079321 (diff)
Removed more warnings, mostly related to unused-variable
issue #121 We still have to work on unused-parameter
Diffstat (limited to 'src/scripts/Spells/spell_dk.cpp')
-rw-r--r--src/scripts/Spells/spell_dk.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/scripts/Spells/spell_dk.cpp b/src/scripts/Spells/spell_dk.cpp
index 7df04d3a18..56af220e42 100644
--- a/src/scripts/Spells/spell_dk.cpp
+++ b/src/scripts/Spells/spell_dk.cpp
@@ -260,7 +260,7 @@ class spell_dk_raise_ally_trigger : public SpellScriptLoader
void HandleEffectRemove(AuraEffect const* /*aurEff*/, AuraEffectHandleModes /*mode*/)
{
if (Unit* charm = GetUnitOwner()->GetCharm())
- if (charm->GetEntry() == GetSpellInfo()->Effects[EFFECT_0].MiscValue)
+ if (GetSpellInfo()->Effects[EFFECT_0].MiscValue >= 0 && charm->GetEntry() == uint32(GetSpellInfo()->Effects[EFFECT_0].MiscValue))
charm->ToCreature()->DespawnOrUnsummon();
}
@@ -782,7 +782,7 @@ class spell_dk_dancing_rune_weapon : public SpellScriptLoader
Unit* target = eventInfo.GetActionTarget();
Unit* dancingRuneWeapon = NULL;
for (Unit::ControlSet::const_iterator itr = player->m_Controlled.begin(); itr != player->m_Controlled.end(); ++itr)
- if ((*itr)->GetEntry() == GetSpellInfo()->Effects[EFFECT_0].MiscValue)
+ if (int32((*itr)->GetEntry()) == GetSpellInfo()->Effects[EFFECT_0].MiscValue)
{
dancingRuneWeapon = *itr;
break;
@@ -1569,7 +1569,6 @@ class spell_dk_death_grip : public SpellScriptLoader
void HandleDummy(SpellEffIndex /*effIndex*/)
{
- int32 damage = GetEffectValue();
float casterZ = GetCaster()->GetPositionZ(); // for Ring of Valor
WorldLocation gripPos = *GetExplTargetDest();
if (Unit* target = GetHitUnit())