mirror of
https://github.com/mangosfour/server.git
synced 2025-12-12 19:37:03 +00:00
[9834] Fix damage bonus applying from 49471 and ranks to 49143 and ranks
This commit is contained in:
parent
8a4b520979
commit
9c6b53aca9
2 changed files with 33 additions and 3 deletions
|
|
@ -9107,8 +9107,8 @@ uint32 Unit::SpellDamageBonusDone(Unit *pVictim, SpellEntry const *spellProto, u
|
||||||
}
|
}
|
||||||
case SPELLFAMILY_DEATHKNIGHT:
|
case SPELLFAMILY_DEATHKNIGHT:
|
||||||
{
|
{
|
||||||
// Icy Touch, Howling Blast and Frost Strike
|
// Icy Touch and Howling Blast
|
||||||
if (spellProto->SpellFamilyFlags & UI64LIT(0x0000000600000002))
|
if (spellProto->SpellFamilyFlags & UI64LIT(0x0000000200000002))
|
||||||
{
|
{
|
||||||
// search disease
|
// search disease
|
||||||
bool found = false;
|
bool found = false;
|
||||||
|
|
@ -10179,6 +10179,36 @@ uint32 Unit::MeleeDamageBonusDone(Unit *pVictim, uint32 pdamage,WeaponAttackType
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Frost Strike
|
||||||
|
if (spellProto && spellProto->SpellFamilyName == SPELLFAMILY_DEATHKNIGHT && spellProto->SpellFamilyFlags & UI64LIT(0x0000000400000000))
|
||||||
|
{
|
||||||
|
// search disease
|
||||||
|
bool found = false;
|
||||||
|
Unit::AuraMap const& auras = pVictim->GetAuras();
|
||||||
|
for(Unit::AuraMap::const_iterator itr = auras.begin(); itr!=auras.end(); ++itr)
|
||||||
|
{
|
||||||
|
if(itr->second->GetSpellProto()->Dispel == DISPEL_DISEASE)
|
||||||
|
{
|
||||||
|
found = true;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if(found)
|
||||||
|
{
|
||||||
|
// search for Glacier Rot dummy aura
|
||||||
|
Unit::AuraList const& dummyAuras = GetAurasByType(SPELL_AURA_DUMMY);
|
||||||
|
for(Unit::AuraList::const_iterator i = dummyAuras.begin(); i != dummyAuras.end(); ++i)
|
||||||
|
{
|
||||||
|
if ((*i)->GetSpellProto()->EffectMiscValue[(*i)->GetEffIndex()] == 7244)
|
||||||
|
{
|
||||||
|
DonePercent *= ((*i)->GetModifier()->m_amount+100.0f) / 100.0f;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
// final calculation
|
// final calculation
|
||||||
// =================
|
// =================
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
#ifndef __REVISION_NR_H__
|
#ifndef __REVISION_NR_H__
|
||||||
#define __REVISION_NR_H__
|
#define __REVISION_NR_H__
|
||||||
#define REVISION_NR "9833"
|
#define REVISION_NR "9834"
|
||||||
#endif // __REVISION_NR_H__
|
#endif // __REVISION_NR_H__
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue