aboutsummaryrefslogtreecommitdiff
path: root/src/game/Unit.cpp
diff options
context:
space:
mode:
authorvisagalis <none@none>2008-11-14 17:50:48 -0600
committervisagalis <none@none>2008-11-14 17:50:48 -0600
commit3085e66b966fec0012decf2543c7e32064b47102 (patch)
tree3aa057fa15ce224932340fa6870d41f0b9422033 /src/game/Unit.cpp
parent053b671cb5481dacc85fe192ceea937462361948 (diff)
[svn] *** Source: MaNGOS ***
* Fixed english spelling in src/game/WorldSocket.h/cpp. Author: Derex * [240_world.sql] Create new command .senditems and remove from moderator level command .sendmail possibility send items. Author: Vladimir * Added new command: .sendmoney player "subject" "message" money - Sends a mail with money to a player. Author: fredi * Correctly apply taken damage debufs/bonuses in cases non-physical melee damage. Author: Frankir * Fix a crash in add friend/ignore callback. (check if player still logged in). Author: Hunuza * Better args checking in .sendmoney command. Author: Vladimir --HG-- branch : trunk
Diffstat (limited to 'src/game/Unit.cpp')
-rw-r--r--src/game/Unit.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp
index 0ca07ff2c1c..c620b86748d 100644
--- a/src/game/Unit.cpp
+++ b/src/game/Unit.cpp
@@ -7332,7 +7332,7 @@ uint32 Unit::SpellDamageBonus(Unit *pVictim, SpellEntry const *spellProto, uint3
// ..taken
AuraList const& mModDamagePercentTaken = pVictim->GetAurasByType(SPELL_AURA_MOD_DAMAGE_PERCENT_TAKEN);
for(AuraList::const_iterator i = mModDamagePercentTaken.begin(); i != mModDamagePercentTaken.end(); ++i)
- if( (*i)->GetModifier()->m_miscvalue & GetSpellSchoolMask(spellProto) )
+ if((*i)->GetModifier()->m_miscvalue & GetSpellSchoolMask(spellProto))
TakenTotalMod *= ((*i)->GetModifier()->m_amount+100.0f)/100.0f;
// .. taken pct: scripted (increases damage of * against targets *)
@@ -8232,7 +8232,7 @@ void Unit::MeleeDamageBonus(Unit *pVictim, uint32 *pdamage,WeaponAttackType attT
// ..taken
AuraList const& mDamageTaken = pVictim->GetAurasByType(SPELL_AURA_MOD_DAMAGE_TAKEN);
for(AuraList::const_iterator i = mDamageTaken.begin();i != mDamageTaken.end(); ++i)
- if((*i)->GetModifier()->m_miscvalue & SPELL_SCHOOL_MASK_NORMAL)
+ if((*i)->GetModifier()->m_miscvalue & GetMeleeDamageSchoolMask())
TakenFlatBenefit += (*i)->GetModifier()->m_amount;
if(attType!=RANGED_ATTACK)
@@ -8256,7 +8256,7 @@ void Unit::MeleeDamageBonus(Unit *pVictim, uint32 *pdamage,WeaponAttackType attT
// ..taken
AuraList const& mModDamagePercentTaken = pVictim->GetAurasByType(SPELL_AURA_MOD_DAMAGE_PERCENT_TAKEN);
for(AuraList::const_iterator i = mModDamagePercentTaken.begin(); i != mModDamagePercentTaken.end(); ++i)
- if((*i)->GetModifier()->m_miscvalue & SPELL_SCHOOL_MASK_NORMAL)
+ if((*i)->GetModifier()->m_miscvalue & GetMeleeDamageSchoolMask())
TakenTotalMod *= ((*i)->GetModifier()->m_amount+100.0f)/100.0f;
// .. taken pct: dummy auras