aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormaximius <none@none>2009-09-15 13:43:09 -0700
committermaximius <none@none>2009-09-15 13:43:09 -0700
commit0174dd5aff75b688a566d63af5cd3a4032764965 (patch)
tree86dd41a45e56c15935ff57fc4ec34164583bdf20
parentd926d567b5862953d444e8dc6b97c704a444e6e8 (diff)
*Fix pets not selecting next target bug, by MrSmite
--HG-- branch : trunk
-rw-r--r--src/game/PetAI.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/game/PetAI.cpp b/src/game/PetAI.cpp
index bf368001cc1..18bde7dde2e 100644
--- a/src/game/PetAI.cpp
+++ b/src/game/PetAI.cpp
@@ -272,8 +272,11 @@ void PetAI::KilledUnit(Unit *victim)
return;
// Clear target just in case. May help problem where health / focus / mana
- // regen gets stuck. Also resets attack command.
- _stopAttack();
+ // regen gets stuck. Also resets attack command.
+ // Can't use _stopAttack() because that activates movement handlers and ignores
+ // next target selection
+ me->AttackStop();
+ me->GetCharmInfo()->SetIsCommandAttack(false);
Unit *nextTarget = SelectNextTarget();