fix(Spell/Core): Prayer of Mending Heal not smart Healing [TC Cherry Pick] (#8753)

Co-authored by @Keader
This commit is contained in:
acidmanifesto
2021-11-04 13:24:24 -04:00
committed by GitHub
parent 98f28456bb
commit 8ac01da463
3 changed files with 93 additions and 5 deletions

View File

@@ -6914,7 +6914,12 @@ void AuraEffect::HandleRaidProcFromChargeWithValueAuraProc(AuraApplication* aurA
{
float radius = GetSpellInfo()->Effects[GetEffIndex()].CalcRadius(caster);
if (Unit* triggerTarget = target->GetNextRandomRaidMemberOrPet(radius))
Unit* triggerTarget = nullptr;
Acore::MostHPMissingGroupInRange u_check(target, radius, 0);
Acore::UnitLastSearcher<Acore::MostHPMissingGroupInRange> searcher(target, triggerTarget, u_check);
Cell::VisitAllObjects(target, searcher, radius);
if (triggerTarget)
{
target->CastCustomSpell(triggerTarget, GetId(), &value, nullptr, nullptr, true, nullptr, this, GetCasterGUID());
if (Aura* aura = triggerTarget->GetAura(GetId(), GetCasterGUID()))