[10923] Cleanup some magic numbers

This commit is contained in:
zergtmn 2010-12-27 19:04:54 +05:00
parent 3c58f25ad9
commit 72b1d30a1c
3 changed files with 7 additions and 6 deletions

View file

@ -130,7 +130,7 @@ m_creatureInfo(NULL), m_splineFlags(SPLINEFLAG_WALKMODE)
m_regenTimer = 200;
m_valuesCount = UNIT_END;
for(int i = 0; i < 4; ++i)
for(int i = 0; i < CREATURE_MAX_SPELLS; ++i)
m_spells[i] = 0;
m_CreatureSpellCooldowns.clear();

View file

@ -8736,15 +8736,16 @@ int32 Unit::CalculateSpellDamage(Unit const* target, SpellEntry const* spellProt
if (Player* modOwner = GetSpellModOwner())
{
modOwner->ApplySpellMod(spellProto->Id, SPELLMOD_ALL_EFFECTS, value);
switch(effect_index)
{
case 0:
case EFFECT_INDEX_0:
modOwner->ApplySpellMod(spellProto->Id, SPELLMOD_EFFECT1, value);
break;
case 1:
case EFFECT_INDEX_1:
modOwner->ApplySpellMod(spellProto->Id, SPELLMOD_EFFECT2, value);
break;
case 2:
case EFFECT_INDEX_2:
modOwner->ApplySpellMod(spellProto->Id, SPELLMOD_EFFECT3, value);
break;
}

View file

@ -1,4 +1,4 @@
#ifndef __REVISION_NR_H__
#define __REVISION_NR_H__
#define REVISION_NR "10922"
#define REVISION_NR "10923"
#endif // __REVISION_NR_H__