Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp
- index 94949e8..ea91a68 100644
- --- a/src/game/Unit.cpp
- +++ b/src/game/Unit.cpp
- @@ -7957,6 +7957,12 @@ uint32 Unit::MeleeDamageBonusDone(Unit *pVictim, uint32 pdamage,WeaponAttackType
- if (!pVictim || pdamage == 0 || (spellProto && spellProto->AttributesEx6 & SPELL_ATTR_EX6_NO_DMG_MODS))
- return pdamage;
- + if (!pVictim->IsInWorld() || !pVictim->GetMap() || !GetMap())
- + return pdamage;
- +
- + MAPLOCK_READ(this,MAP_LOCK_TYPE_AURAS);
- + MAPLOCK_READ1(pVictim,MAP_LOCK_TYPE_AURAS);
- +
- // differentiate for weapon damage based spells
- bool isWeaponDamageBasedSpell = !(spellProto && (damagetype == DOT || IsSpellHaveEffect(spellProto, SPELL_EFFECT_SCHOOL_DAMAGE)));
- Item* pWeapon = GetTypeId() == TYPEID_PLAYER ? ((Player*)this)->GetWeaponForAttack(attType,true,false) : NULL;
Add Comment
Please, Sign In to add comment