From bc431059f4f1efc83a4e8bd221eccd99ce302bf8 Mon Sep 17 00:00:00 2001 From: ratkosrb <35845488+ratkosrb@users.noreply.github.com> Date: Fri, 21 Feb 2025 08:37:20 +0200 Subject: [PATCH] Avoid lookup of charmer or owner in CalculateHeartBeat. --- src/game/Spells/SpellAuras.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/game/Spells/SpellAuras.cpp b/src/game/Spells/SpellAuras.cpp index 2e600e1e6..863b4aaf0 100644 --- a/src/game/Spells/SpellAuras.cpp +++ b/src/game/Spells/SpellAuras.cpp @@ -8368,7 +8368,7 @@ void SpellAuraHolder::CalculateHeartBeat(Unit* caster, Unit* target) || m_spellProto->Id == 13327) // Reckless Charge { // Only update the random value if a player is involved - if (target->GetCharmerOrOwnerPlayerOrPlayerItself()) + if (target->IsCharmerOrOwnerPlayerOrPlayerItself()) _heartBeatRandValue = rand_norm_f() * 100.0f; } // For PvE/effects on NPCs. Doesn't affect certain spells with DR (For example: Fear being dispelled by damage).