[10442] Fix armor bonus part of talent 33853 and ranks

This commit is contained in:
Laise 2010-09-04 16:48:08 +03:00
parent b5ed6938ad
commit 924cf7c46b
2 changed files with 20 additions and 3 deletions

View file

@ -5913,7 +5913,7 @@ void Aura::HandleShapeshiftBoosts(bool apply)
if (MasterShaperSpellId)
{
Unit::AuraList const& ShapeShifterAuras = target->GetAurasByType(SPELL_AURA_DUMMY);
for(Unit::AuraList::const_iterator i = ShapeShifterAuras.begin(); i != ShapeShifterAuras.end(); i++)
for(Unit::AuraList::const_iterator i = ShapeShifterAuras.begin(); i != ShapeShifterAuras.end(); ++i)
{
if ((*i)->GetSpellProto()->SpellIconID == 2851)
{
@ -5936,11 +5936,28 @@ void Aura::HandleShapeshiftBoosts(bool apply)
if (form == FORM_CAT && ((Player*)target)->HasAura(52610))
target->CastSpell(target, 62071, true);
// Survival of the Fittest (Armor part)
if (form == FORM_BEAR || form == FORM_DIREBEAR)
{
Unit::AuraList const& modAuras = target->GetAurasByType(SPELL_AURA_MOD_TOTAL_STAT_PERCENTAGE);
for (Unit::AuraList::const_iterator i = modAuras.begin(); i != modAuras.end(); ++i)
{
if ((*i)->GetSpellProto()->SpellFamilyName == SPELLFAMILY_DRUID &&
(*i)->GetSpellProto()->SpellIconID == 961)
{
int32 bp = (*i)->GetSpellProto()->CalculateSimpleValue(EFFECT_INDEX_2);
if (bp)
target->CastCustomSpell(target, 62069, &bp, NULL, NULL, true, NULL, this);
break;
}
}
}
// Improved Moonkin Form
if (form == FORM_MOONKIN)
{
Unit::AuraList const& dummyAuras = target->GetAurasByType(SPELL_AURA_DUMMY);
for(Unit::AuraList::const_iterator i = dummyAuras.begin(); i != dummyAuras.end(); i++)
for(Unit::AuraList::const_iterator i = dummyAuras.begin(); i != dummyAuras.end(); ++i)
{
if ((*i)->GetSpellProto()->SpellFamilyName==SPELLFAMILY_DRUID &&
(*i)->GetSpellProto()->SpellIconID == 2855)

View file

@ -1,4 +1,4 @@
#ifndef __REVISION_NR_H__
#define __REVISION_NR_H__
#define REVISION_NR "10441"
#define REVISION_NR "10442"
#endif // __REVISION_NR_H__