[8175] Add shred in spell_check. Author: VladimirMangos
--HG-- branch : trunk
This commit is contained in:
@@ -98,6 +98,7 @@ INSERT INTO spell_check (spellid,SpellFamilyName,SpellFamilyMaskA,SpellFamilyMas
|
||||
( 0,10,0x0010000000000000,0x00000000, -1, -1, -1, 2, -1,-1,'Shield of Righteousness', 'Spell::EffectSchoolDMG'),
|
||||
( 0, 4,0x0000020000000000,0x00000000, -1, -1,1209, 2, -1,-1,'Shield Slam', 'Spell::EffectSchoolDMG'),
|
||||
( 0, 4,0x0000800000000000,0x00000000, -1, -1, -1, 2, -1,-1,'Shockwave', 'Spell::EffectSchoolDMG'),
|
||||
( 0, 7,0x0000000000008000,0x00000000, -1, -1, -1, -1, -1,-1,'Shred', 'Unit::MeleeDamageBonus'),
|
||||
( 0, 9,0x0000000100000000,0x00000000, -1, -1, -1, 2, -1,-1,'Steady Shot', 'Spell::EffectSchoolDMG'),
|
||||
( 0, 7,0x0010000000000000,0x00000000, -1, -1, -1, 2, -1,-1,'Swipe', 'Spell::EffectSchoolDMG'),
|
||||
( 0, 4,0x0000000000000080,0x00000000, -1, -1, -1, 2, -1,-1,'Thunder Clap', 'Spell::EffectSchoolDMG'),
|
||||
|
||||
+16
-15
@@ -10249,6 +10249,22 @@ void Unit::MeleeDamageBonus(Unit *pVictim, uint32 *pdamage,WeaponAttackType attT
|
||||
if((*i)->GetMiscValue() & GetMeleeDamageSchoolMask())
|
||||
TakenTotalMod *= ((*i)->GetAmount()+100.0f)/100.0f;
|
||||
|
||||
// .. taken pct (special attacks)
|
||||
if (spellProto)
|
||||
{
|
||||
// Mod damage from spell mechanic
|
||||
uint32 mechanicMask = GetAllSpellMechanicMask(spellProto);
|
||||
if (mechanicMask)
|
||||
{
|
||||
AuraEffectList const& mDamageDoneMechanic = pVictim->GetAurasByType(SPELL_AURA_MOD_MECHANIC_DAMAGE_TAKEN_PERCENT);
|
||||
for(AuraEffectList::const_iterator i = mDamageDoneMechanic.begin();i != mDamageDoneMechanic.end(); ++i)
|
||||
if((mechanicMask & uint32(1<<((*i)->GetMiscValue())))
|
||||
// Shred - "Effects which increase Bleed damage also increase Shred damage"
|
||||
|| ((*i)->GetMiscValue() == MECHANIC_BLEED && spellProto->SpellFamilyName == SPELLFAMILY_DRUID && spellProto->SpellFamilyFlags[0] & 0x8000))
|
||||
TakenTotalMod *= ((*i)->GetAmount()+100.0f)/100.0f;
|
||||
}
|
||||
}
|
||||
|
||||
// .. taken pct: dummy auras
|
||||
AuraEffectList const& mDummyAuras = pVictim->GetAurasByType(SPELL_AURA_DUMMY);
|
||||
for(AuraEffectList::const_iterator i = mDummyAuras.begin(); i != mDummyAuras.end(); ++i)
|
||||
@@ -10293,21 +10309,6 @@ void Unit::MeleeDamageBonus(Unit *pVictim, uint32 *pdamage,WeaponAttackType attT
|
||||
}
|
||||
}
|
||||
|
||||
if (spellProto)
|
||||
{
|
||||
// Mod damage from spell mechanic
|
||||
uint32 mechanicMask = GetAllSpellMechanicMask(spellProto);
|
||||
if (mechanicMask)
|
||||
{
|
||||
AuraEffectList const& mDamageDoneMechanic = pVictim->GetAurasByType(SPELL_AURA_MOD_MECHANIC_DAMAGE_TAKEN_PERCENT);
|
||||
for(AuraEffectList::const_iterator i = mDamageDoneMechanic.begin();i != mDamageDoneMechanic.end(); ++i)
|
||||
if((mechanicMask & uint32(1<<((*i)->GetMiscValue())))
|
||||
// Shred - "Effects which increase Bleed damage also increase Shred damage"
|
||||
|| ((*i)->GetMiscValue() == MECHANIC_BLEED && spellProto->SpellFamilyName == SPELLFAMILY_DRUID && spellProto->SpellFamilyFlags[0] & 0x8000))
|
||||
TakenTotalMod *= ((*i)->GetAmount()+100.0f)/100.0f;
|
||||
}
|
||||
}
|
||||
|
||||
if(attType != RANGED_ATTACK)
|
||||
{
|
||||
AuraEffectList const& mModMeleeDamageTakenPercent = pVictim->GetAurasByType(SPELL_AURA_MOD_MELEE_DAMAGE_TAKEN_PCT);
|
||||
|
||||
Reference in New Issue
Block a user