aboutsummaryrefslogtreecommitdiff
path: root/src/game/PetHandler.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/game/PetHandler.cpp')
-rw-r--r--src/game/PetHandler.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/game/PetHandler.cpp b/src/game/PetHandler.cpp
index 45fcbbb3219..0a506c2fbcc 100644
--- a/src/game/PetHandler.cpp
+++ b/src/game/PetHandler.cpp
@@ -124,11 +124,9 @@ void WorldSession::HandlePetAction( WorldPacket & recv_data )
if (pet->getVictim())
pet->AttackStop();
- if(pet->GetTypeId() != TYPEID_PLAYER)
+ if(pet->GetTypeId() != TYPEID_PLAYER && ((Creature*)pet)->IsAIEnabled)
{
- pet->GetMotionMaster()->Clear();
- if (((Creature*)pet)->IsAIEnabled)
- ((Creature*)pet)->AI()->AttackStart(TargetUnit);
+ ((Creature*)pet)->AI()->AttackStart(TargetUnit);
//10% chance to play special pet attack talk, else growl
if(((Creature*)pet)->isPet() && ((Pet*)pet)->getPetType() == SUMMON_PET && pet != TargetUnit && urand(0, 100) < 10)