mirror of
https://github.com/mangosfour/server.git
synced 2025-12-13 22:37:03 +00:00
[8175] More fixes for 33878/33876 and ranks.
* Apply SPELL_AURA_MOD_MECHANIC_DAMAGE_TAKEN_PERCENT in melee binus for special attacks * In damage calulcation spell 5221 and ranks considered have MECHANIC_BLEED. * Drop more dead code related to 33878/33876 and ranks.
This commit is contained in:
parent
9759a2279c
commit
647e1c5a8b
3 changed files with 21 additions and 9 deletions
|
|
@ -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'),
|
||||
|
|
|
|||
|
|
@ -8710,6 +8710,25 @@ void Unit::MeleeDamageBonus(Unit *pVictim, uint32 *pdamage,WeaponAttackType attT
|
|||
if((*i)->GetModifier()->m_miscvalue & GetMeleeDamageSchoolMask())
|
||||
TakenTotalMod *= ((*i)->GetModifier()->m_amount+100.0f)/100.0f;
|
||||
|
||||
// .. taken pct (special attacks)
|
||||
if (spellProto)
|
||||
{
|
||||
uint32 mechanicMask = GetAllSpellMechanicMask(spellProto);
|
||||
|
||||
// Shred also have bonus as MECHANIC_BLEED damages
|
||||
if(spellProto->SpellFamilyName==SPELLFAMILY_DRUID && (spellProto->SpellFamilyFlags & UI64LIT(0x00008000)))
|
||||
mechanicMask |= (1 << MECHANIC_BLEED);
|
||||
|
||||
// Mod damage from spell mechanic
|
||||
if (mechanicMask)
|
||||
{
|
||||
AuraList const& mDamageDoneMechanic = pVictim->GetAurasByType(SPELL_AURA_MOD_MECHANIC_DAMAGE_TAKEN_PERCENT);
|
||||
for(AuraList::const_iterator i = mDamageDoneMechanic.begin();i != mDamageDoneMechanic.end(); ++i)
|
||||
if(mechanicMask & uint32(1<<((*i)->GetModifier()->m_miscvalue)))
|
||||
TakenTotalMod *= ((*i)->GetModifier()->m_amount+100.0f)/100.0f;
|
||||
}
|
||||
}
|
||||
|
||||
// .. taken pct: dummy auras
|
||||
AuraList const& mDummyAuras = pVictim->GetAurasByType(SPELL_AURA_DUMMY);
|
||||
for(AuraList::const_iterator i = mDummyAuras.begin(); i != mDummyAuras.end(); ++i)
|
||||
|
|
@ -8728,14 +8747,6 @@ void Unit::MeleeDamageBonus(Unit *pVictim, uint32 *pdamage,WeaponAttackType attT
|
|||
TakenTotalMod *= (mod+100.0f)/100.0f;
|
||||
}
|
||||
break;
|
||||
//Mangle
|
||||
case 2312:
|
||||
if(spellProto==NULL)
|
||||
break;
|
||||
// Should increase Shred (initial Damage of Lacerate and Rake handled in Spell::EffectSchoolDMG)
|
||||
if(spellProto->SpellFamilyName==SPELLFAMILY_DRUID && (spellProto->SpellFamilyFlags == UI64LIT(0x00008000)))
|
||||
TakenTotalMod *= (100.0f+(*i)->GetModifier()->m_amount)/100.0f;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
#ifndef __REVISION_NR_H__
|
||||
#define __REVISION_NR_H__
|
||||
#define REVISION_NR "8174"
|
||||
#define REVISION_NR "8175"
|
||||
#endif // __REVISION_NR_H__
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue