aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorTreeston <treeston.mmoc@gmail.com>2019-08-11 13:31:46 +0200
committerTreeston <treeston.mmoc@gmail.com>2019-08-11 13:31:46 +0200
commitfcce90508d899641494d7c281a0e08e411a0d5ab (patch)
treee6dae67bd5736485933b7abc6b6273f2f79a761f /src
parent0f7e070ed4cd01ffb4c5384b74d7b7b01d758c0d (diff)
Core/Creature: Fix an issue that sometimes prevented spellcast focus targets from being reacquired.
Diffstat (limited to 'src')
-rw-r--r--src/server/game/Entities/Creature/Creature.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/server/game/Entities/Creature/Creature.cpp b/src/server/game/Entities/Creature/Creature.cpp
index 0573c087ff6..b399af92b12 100644
--- a/src/server/game/Entities/Creature/Creature.cpp
+++ b/src/server/game/Entities/Creature/Creature.cpp
@@ -3157,10 +3157,9 @@ void Creature::ReleaseSpellFocus(Spell const* focusSpell, bool withDelay)
void Creature::ReacquireSpellFocusTarget()
{
- if (!HasSpellFocus())
- return;
+ ASSERT(HasSpellFocus());
- SetTarget(_spellFocusInfo.Target);
+ SetGuidValue(UNIT_FIELD_TARGET, _spellFocusInfo.Target);
if (!HasFlag(UNIT_FIELD_FLAGS_2, UNIT_FLAG2_DISABLE_TURN))
{