fix(Core/Spells): Fix Lock and Load procs (#24795)

Co-authored-by: blinkysc <blinkysc@users.noreply.github.com>
This commit is contained in:
blinkysc
2026-02-22 12:32:41 -06:00
committed by GitHub
parent 98cf3cb007
commit 96df2b3678
4 changed files with 22 additions and 1 deletions

View File

@@ -719,6 +719,7 @@ Spell::~Spell()
void Spell::InitExplicitTargets(SpellCastTargets const& targets)
{
m_targets = targets;
m_originalTargetGUID = targets.GetObjectTargetGUID();
// this function tries to correct spell explicit targets for spell
// client doesn't send explicit targets correctly sometimes - we need to fix such spells serverside
// this also makes sure that we correctly send explicit targets to client (removes redundant data)
@@ -7855,6 +7856,11 @@ void Spell::DelayedChannel()
SendChannelUpdate(m_timer);
}
Unit* Spell::GetOriginalTarget() const
{
return ObjectAccessor::GetUnit(*m_caster, m_originalTargetGUID);
}
bool Spell::UpdatePointers()
{
if (m_originalCasterGUID == m_caster->GetGUID())