mirror of
https://github.com/mangosfour/server.git
synced 2025-12-21 01:37:05 +00:00
Merge commit 'origin/master' into 320
This commit is contained in:
commit
258e19a4a3
48 changed files with 744 additions and 206 deletions
|
|
@ -460,6 +460,13 @@ m_isRemovedOnShapeLost(true), m_in_use(0), m_deleted(false)
|
|||
m_spellProto->Stances &&
|
||||
!(m_spellProto->AttributesEx2 & SPELL_ATTR_EX2_NOT_NEED_SHAPESHIFT) &&
|
||||
!(m_spellProto->Attributes & SPELL_ATTR_NOT_SHAPESHIFT));
|
||||
|
||||
if (caster && m_spellProto->Id == 22959) // Improved Scorch
|
||||
{
|
||||
// Glyph of Improved Scorch
|
||||
if (Aura* glyph = caster->GetDummyAura(56371))
|
||||
m_stackAmount = glyph->GetModifier()->m_amount;
|
||||
}
|
||||
}
|
||||
|
||||
Aura::~Aura()
|
||||
|
|
@ -754,8 +761,8 @@ void AreaAura::Update(uint32 diff)
|
|||
TypeContainerVisitor<MaNGOS::UnitListSearcher<MaNGOS::AnyFriendlyUnitInObjectRangeCheck>, WorldTypeMapContainer > world_unit_searcher(searcher);
|
||||
TypeContainerVisitor<MaNGOS::UnitListSearcher<MaNGOS::AnyFriendlyUnitInObjectRangeCheck>, GridTypeMapContainer > grid_unit_searcher(searcher);
|
||||
CellLock<GridReadGuard> cell_lock(cell, p);
|
||||
cell_lock->Visit(cell_lock, world_unit_searcher, *caster->GetMap());
|
||||
cell_lock->Visit(cell_lock, grid_unit_searcher, *caster->GetMap());
|
||||
cell_lock->Visit(cell_lock, world_unit_searcher, *caster->GetMap(), *caster, m_radius);
|
||||
cell_lock->Visit(cell_lock, grid_unit_searcher, *caster->GetMap(), *caster, m_radius);
|
||||
break;
|
||||
}
|
||||
case AREA_AURA_ENEMY:
|
||||
|
|
@ -770,8 +777,8 @@ void AreaAura::Update(uint32 diff)
|
|||
TypeContainerVisitor<MaNGOS::UnitListSearcher<MaNGOS::AnyAoETargetUnitInObjectRangeCheck>, WorldTypeMapContainer > world_unit_searcher(searcher);
|
||||
TypeContainerVisitor<MaNGOS::UnitListSearcher<MaNGOS::AnyAoETargetUnitInObjectRangeCheck>, GridTypeMapContainer > grid_unit_searcher(searcher);
|
||||
CellLock<GridReadGuard> cell_lock(cell, p);
|
||||
cell_lock->Visit(cell_lock, world_unit_searcher, *caster->GetMap());
|
||||
cell_lock->Visit(cell_lock, grid_unit_searcher, *caster->GetMap());
|
||||
cell_lock->Visit(cell_lock, world_unit_searcher, *caster->GetMap(), *caster, m_radius);
|
||||
cell_lock->Visit(cell_lock, grid_unit_searcher, *caster->GetMap(), *caster, m_radius);
|
||||
break;
|
||||
}
|
||||
case AREA_AURA_OWNER:
|
||||
|
|
@ -5001,7 +5008,8 @@ void Aura::HandleAuraModIncreaseHealth(bool apply, bool Real)
|
|||
case 12976: // Warrior Last Stand triggered spell
|
||||
case 28726: // Nightmare Seed ( Nightmare Seed )
|
||||
case 34511: // Valor (Bulwark of Kings, Bulwark of the Ancient Kings)
|
||||
case 44055: // Tremendous Fortitude (Battlemaster's Alacrity)
|
||||
// FIXME: add case 67596: in 3.2.x
|
||||
case 44055: case 55915: case 55917: // Tremendous Fortitude (Battlemaster's Alacrity)
|
||||
case 50322: // Survival Instincts
|
||||
case 54443: // Demonic Empowerment (Voidwalker)
|
||||
{
|
||||
|
|
@ -6141,6 +6149,15 @@ void Aura::HandleSchoolAbsorb(bool apply, bool Real)
|
|||
//+30% from +spell bonus
|
||||
DoneActualBenefit = caster->SpellBaseDamageBonus(GetSpellSchoolMask(m_spellProto)) * 0.30f;
|
||||
break;
|
||||
case SPELLFAMILY_PALADIN:
|
||||
// Sacred Shield
|
||||
// (check not strictly needed, only Sacred Shield has SPELL_AURA_SCHOOL_ABSORB in SPELLFAMILY_PALADIN at this time)
|
||||
if (m_spellProto->SpellFamilyFlags & UI64LIT(0x0008000000000000))
|
||||
{
|
||||
// +75% from spell power
|
||||
DoneActualBenefit = caster->SpellBaseHealingBonus(GetSpellSchoolMask(m_spellProto)) * 0.75f;
|
||||
}
|
||||
break;
|
||||
case SPELLFAMILY_DRUID:
|
||||
// Savage Defense (amount store original percent of attack power applied)
|
||||
if (m_spellProto->SpellIconID == 50) // only spell with this aura fit
|
||||
|
|
@ -6153,6 +6170,26 @@ void Aura::HandleSchoolAbsorb(bool apply, bool Real)
|
|||
DoneActualBenefit *= caster->CalculateLevelPenalty(GetSpellProto());
|
||||
|
||||
m_modifier.m_amount += (int32)DoneActualBenefit;
|
||||
|
||||
// now that the correct amount is computed, apply caster aura, if any
|
||||
switch(m_spellProto->SpellFamilyName)
|
||||
{
|
||||
case SPELLFAMILY_PRIEST:
|
||||
// Power Word: Shield
|
||||
if (m_spellProto->SpellFamilyFlags & UI64LIT(0x0000000000000001))
|
||||
{
|
||||
// Glyph of Power Word: Shield
|
||||
if(Aura* glyph = caster->GetAura(55672,0))
|
||||
{
|
||||
// instant heal glyph m_amount% of the absorbed amount
|
||||
int32 heal = (glyph->GetModifier()->m_amount * m_modifier.m_amount)/100;
|
||||
caster->CastCustomSpell(m_target, 56160, &heal, NULL, NULL, true, 0, this);
|
||||
}
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
|
|
@ -7025,8 +7062,8 @@ void Aura::PeriodicDummyTick()
|
|||
|
||||
CellLock<GridReadGuard> cell_lock(cell, p);
|
||||
|
||||
cell_lock->Visit(cell_lock, grid_object_checker, *caster->GetMap());
|
||||
cell_lock->Visit(cell_lock, world_object_checker, *caster->GetMap());
|
||||
cell_lock->Visit(cell_lock, grid_object_checker, *caster->GetMap(), *caster, radius);
|
||||
cell_lock->Visit(cell_lock, world_object_checker, *caster->GetMap(), *caster, radius);
|
||||
}
|
||||
|
||||
if(targets.empty())
|
||||
|
|
@ -7175,7 +7212,7 @@ void Aura::HandleManaShield(bool apply, bool Real)
|
|||
switch(m_spellProto->SpellFamilyName)
|
||||
{
|
||||
case SPELLFAMILY_MAGE:
|
||||
if(m_spellProto->SpellFamilyFlags & UI64LIT(0x8000))
|
||||
if(m_spellProto->SpellFamilyFlags & UI64LIT(0x0000000000008000))
|
||||
{
|
||||
// Mana Shield
|
||||
// +50% from +spd bonus
|
||||
|
|
@ -7256,13 +7293,13 @@ void Aura::HandleAuraConvertRune(bool apply, bool Real)
|
|||
{
|
||||
if(!plr->GetRuneCooldown(i))
|
||||
{
|
||||
plr->ConvertRune(i, GetSpellProto()->EffectMiscValueB[m_effIndex]);
|
||||
plr->ConvertRune(i, RuneType(GetSpellProto()->EffectMiscValueB[m_effIndex]));
|
||||
break;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if(plr->GetCurrentRune(i) == GetSpellProto()->EffectMiscValueB[m_effIndex])
|
||||
if(plr->GetCurrentRune(i) == RuneType(GetSpellProto()->EffectMiscValueB[m_effIndex]))
|
||||
{
|
||||
plr->ConvertRune(i, plr->GetBaseRune(i));
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue