Skip to content

Commit fe7d012

Browse files
author
Github Actions
committed
Merge 3.3.5 to 3.3.5-base_patch
2 parents 023b5dd + 93ab97a commit fe7d012

2 files changed

Lines changed: 7 additions & 1 deletion

File tree

src/server/game/Spells/Spell.cpp

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5426,7 +5426,9 @@ SpellCastResult Spell::CheckCast(bool strict, uint32* param1 /*= nullptr*/, uint
54265426
if (m_spellInfo->RequiresSpellFocus)
54275427
{
54285428
focusObject = SearchSpellFocus();
5429-
if (!focusObject)
5429+
if (focusObject)
5430+
m_focusObjectGUID = focusObject->GetGUID();
5431+
else
54305432
return SPELL_FAILED_REQUIRES_SPELL_FOCUS;
54315433
}
54325434

@@ -7284,6 +7286,9 @@ bool Spell::UpdatePointers()
72847286
m_originalCaster = nullptr;
72857287
}
72867288

7289+
if (m_focusObjectGUID)
7290+
focusObject = ObjectAccessor::GetGameObject(*m_caster, m_focusObjectGUID);
7291+
72877292
if (m_castItemGUID && m_caster->GetTypeId() == TYPEID_PLAYER)
72887293
{
72897294
m_CastItem = m_caster->ToPlayer()->GetItemByGuid(m_castItemGUID);

src/server/game/Spells/Spell.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -530,6 +530,7 @@ class TC_GAME_API Spell
530530
DynObjAura* _dynObjAura;
531531

532532
// -------------------------------------------
533+
ObjectGuid m_focusObjectGUID;
533534
GameObject* focusObject;
534535

535536
// Damage and healing in effects need just calculate

0 commit comments

Comments
 (0)