diff options
Diffstat (limited to 'src')
-rwxr-xr-x | src/server/game/Entities/Player/Player.cpp | 5 | ||||
-rwxr-xr-x | src/server/game/Entities/Unit/Unit.cpp | 10 | ||||
-rwxr-xr-x | src/server/game/Spells/Auras/SpellAuraEffects.cpp | 11 | ||||
-rwxr-xr-x | src/server/game/Spells/Auras/SpellAuras.cpp | 23 |
4 files changed, 46 insertions, 3 deletions
diff --git a/src/server/game/Entities/Player/Player.cpp b/src/server/game/Entities/Player/Player.cpp index 38669109d6e..ccfb5f0635f 100755 --- a/src/server/game/Entities/Player/Player.cpp +++ b/src/server/game/Entities/Player/Player.cpp @@ -20854,8 +20854,9 @@ bool Player::CanReportAfkDueToLimit() ///This player has been blamed to be inactive in a battleground void Player::ReportedAfkBy(Player* reporter) { - Battleground *bg = GetBattleground(); - if (!bg || bg != reporter->GetBattleground() || GetTeam() != reporter->GetTeam()) + Battleground* bg = GetBattleground(); + // Battleground also must be in progress! + if (!bg || bg != reporter->GetBattleground() || GetTeam() != reporter->GetTeam() || bg->GetStatus() != STATUS_IN_PROGRESS) return; // check if player has 'Idle' or 'Inactive' debuff diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp index 6a84acfa257..06de958d23a 100755 --- a/src/server/game/Entities/Unit/Unit.cpp +++ b/src/server/game/Entities/Unit/Unit.cpp @@ -10836,6 +10836,16 @@ bool Unit::isSpellCrit(Unit *pVictim, SpellEntry const *spellProto, SpellSchoolM break; } break; + case SPELLFAMILY_WARRIOR: + // Victory Rush + if (spellProto->SpellFamilyFlags[1] & 0x100) + { + // Glyph of Victory Rush + if (AuraEffect const* aurEff = GetAuraEffect(58382, 0)) + crit_chance += aurEff->GetAmount(); + break; + } + break; case SPELLFAMILY_PALADIN: // Judgement of Command proc always crits on stunned target if (spellProto->SpellFamilyName == SPELLFAMILY_PALADIN) diff --git a/src/server/game/Spells/Auras/SpellAuraEffects.cpp b/src/server/game/Spells/Auras/SpellAuraEffects.cpp index fa37ad9daad..b65f8700ddd 100755 --- a/src/server/game/Spells/Auras/SpellAuraEffects.cpp +++ b/src/server/game/Spells/Auras/SpellAuraEffects.cpp @@ -5927,6 +5927,15 @@ void AuraEffect::HandleAuraDummy(AuraApplication const * aurApp, uint8 mode, boo } break; } + case 43681: // Inactive + { + if (!target || target->GetTypeId() != TYPEID_PLAYER || aurApp->GetRemoveMode() != AURA_REMOVE_BY_EXPIRE) + return; + + if (target->GetMap()->IsBattleground()) + target->ToPlayer()->LeaveBattleground(); + break; + } case 42783: // Wrath of the Astromancer target->CastSpell(target, GetAmount(), true, NULL, this); break; @@ -5982,7 +5991,7 @@ void AuraEffect::HandleAuraDummy(AuraApplication const * aurApp, uint8 mode, boo break; case SPELLFAMILY_PRIEST: // Vampiric Touch - if (m_spellProto->SpellFamilyFlags[1] & 0x0400 && aurApp->GetRemoveMode() == AURA_REMOVE_BY_ENEMY_SPELL) + if (m_spellProto->SpellFamilyFlags[1] & 0x0400 && aurApp->GetRemoveMode() == AURA_REMOVE_BY_ENEMY_SPELL && GetEffIndex() == 0) { if (AuraEffect const * aurEff = GetBase()->GetEffect(1)) { diff --git a/src/server/game/Spells/Auras/SpellAuras.cpp b/src/server/game/Spells/Auras/SpellAuras.cpp index 8f1f4dd571b..894775179e1 100755 --- a/src/server/game/Spells/Auras/SpellAuras.cpp +++ b/src/server/game/Spells/Auras/SpellAuras.cpp @@ -955,6 +955,20 @@ void Aura::HandleAuraSpecificMods(AuraApplication const * aurApp, Unit * caster, break; } break; + case SPELLFAMILY_DRUID: + if (!caster) + break; + // Rejuvenation + if (GetSpellProto()->SpellFamilyFlags[0] & 0x10 && GetEffect(EFFECT_0)) + { + // Druid T8 Restoration 4P Bonus + if (AuraEffect const* aurEff = caster->GetAuraEffect(64760, EFFECT_0)) + { + int32 heal = GetEffect(EFFECT_0)->GetAmount(); + caster->CastCustomSpell(target, 64801, &heal, NULL, NULL, true, NULL, GetEffect(EFFECT_0)); + } + } + break; case SPELLFAMILY_MAGE: if (!caster) break; @@ -1488,6 +1502,15 @@ void Aura::HandleAuraSpecificMods(AuraApplication const * aurApp, Unit * caster, else target->RemoveAurasDueToSpell(64364, GetCasterGUID()); break; + case 31842: + if (caster->HasAura(70755)) + { + if (apply) + caster->CastSpell(caster, 71166, true); + else + caster->RemoveAurasDueToSpell(71166); + } + break; } break; case SPELLFAMILY_DEATHKNIGHT: |