bool CheckProc(ProcEventInfo& eventInfo) { if (!eventInfo.GetActionTarget()) return false; if (eventInfo.GetActionTarget()->HasAura(SPELL_PALADIN_BEACON_OF_LIGHT, eventInfo.GetActor()->GetGUID())) return false; return true; }
void HandleProc(AuraEffect const* aurEff, ProcEventInfo& eventInfo) { PreventDefaultAction(); Unit* caster = eventInfo.GetActionTarget(); int32 bp = CalculatePct(static_cast<int32>(caster->GetMaxPower(POWER_MANA)), aurEff->GetAmount()); caster->CastCustomSpell(SPELL_MAGE_MAGIC_ABSORPTION_MANA, SPELLVALUE_BASE_POINT0, bp, caster, true, nullptr, aurEff); }
void HandleProc(AuraEffect const* aurEff, ProcEventInfo& eventInfo) { PreventDefaultAction(); DamageInfo* damageInfo = eventInfo.GetDamageInfo(); if (!damageInfo || !damageInfo->GetDamage()) return; eventInfo.GetActionTarget()->CastSpell(eventInfo.GetActor(), SPELL_TWISTED_REFLECTION_HEAL, true, nullptr, aurEff); }
bool HandleCheckProc(ProcEventInfo &eventInfo) { if (!canProc) return false; auto const caster = eventInfo.GetActionTarget(); if (caster && caster->HasAura(SPELL_ULTIMATE_POWER)) return false; auto const target = eventInfo.GetActor(); if (!target || target->GetTypeId() != TYPEID_PLAYER) return false; return true; }
void OnProc(constAuraEffectPtr aurEff, ProcEventInfo& eventInfo) { PreventDefaultAction(); if (!GetCaster()) return; if (!eventInfo.GetHealInfo() || !eventInfo.GetHealInfo()->GetHeal()) return; Unit* unitTarget = eventInfo.GetActionTarget(); Player* plr = GetCaster()->ToPlayer(); if (!unitTarget || !plr) return; float Mastery = plr->GetFloatValue(PLAYER_MASTERY) * 1.25f / 100.0f; int32 bp = (Mastery * eventInfo.GetHealInfo()->GetHeal()) / 6; bp += unitTarget->GetRemainingPeriodicAmount(plr->GetGUID(), SPELL_PRIEST_ECHO_OF_LIGHT, SPELL_AURA_PERIODIC_HEAL); plr->CastCustomSpell(unitTarget, SPELL_PRIEST_ECHO_OF_LIGHT, &bp, NULL, NULL, true); }
bool CheckProc(ProcEventInfo& eventInfo) { if (eventInfo.GetActionTarget()->GetEntry() != NPC_XS013_SCRAPBOT) return false; return true; }
void HandleProc(AuraEffect const* aurEff, ProcEventInfo& eventInfo) { PreventDefaultAction(); if (Unit* target = eventInfo.GetActionTarget()) target->CastSpell(target, SPELL_MAGE_BLAZING_SPEED, true, nullptr, aurEff); }
void HandleProc(AuraEffect const* aurEff, ProcEventInfo& eventInfo) { Unit* caster = eventInfo.GetActionTarget(); caster->CastSpell(caster, SPELL_MAGE_ARCANE_SURGE, true, nullptr, aurEff); }
void HandleEffectProc(AuraEffect const* aurEff, ProcEventInfo& eventInfo) { PreventDefaultAction(); Unit* attacker = eventInfo.GetActor(); int32 damage = int32(attacker->GetTotalAttackPowerValue(BASE_ATTACK) * 0.125f / 2600 * attacker->GetBaseAttackTime(BASE_ATTACK)); attacker->CastCustomSpell(SPELL_SHAMAN_FLAMETONGUE_ATTACK, SPELLVALUE_BASE_POINT0, damage, eventInfo.GetActionTarget(), TRIGGERED_FULL_MASK, nullptr, aurEff); }
bool CheckProc(ProcEventInfo& eventInfo) { if (eventInfo.GetActionTarget()->GetAura(SPELL_PALADIN_BEACON_OF_LIGHT_MARKER, GetCasterGUID())) return false; return true; }
bool CheckProc(ProcEventInfo& eventInfo) { return eventInfo.GetActor() == eventInfo.GetActionTarget(); }
bool CheckProc(ProcEventInfo& eventInfo) { Unit* actionTarget = eventInfo.GetActionTarget(); return actionTarget && actionTarget->GetCreatureType() == CREATURE_TYPE_UNDEAD && actionTarget->GetOwner(); }