aboutsummaryrefslogtreecommitdiff
path: root/src/game/PetHandler.cpp
diff options
context:
space:
mode:
authorgvcoman <none@none>2008-11-07 18:46:25 -0600
committergvcoman <none@none>2008-11-07 18:46:25 -0600
commit9d6d9efa65d3d57ec7d61198c12d8282810bb4b6 (patch)
treeb0f87c981290095a6cb8e889e0193f8220100f67 /src/game/PetHandler.cpp
parent3c7ae2b226250ded933cdefac9458756fa468c40 (diff)
[svn] Fixed pets stopping attack after pressing the attack button multiple times.
--HG-- branch : trunk
Diffstat (limited to 'src/game/PetHandler.cpp')
-rw-r--r--src/game/PetHandler.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/game/PetHandler.cpp b/src/game/PetHandler.cpp
index 60a4bec0891..ac198c0be67 100644
--- a/src/game/PetHandler.cpp
+++ b/src/game/PetHandler.cpp
@@ -104,9 +104,6 @@ void WorldSession::HandlePetAction( WorldPacket & recv_data )
if( GetPlayer()->IsFriendlyTo(TargetUnit))
return;
- if(pet->getVictim())
- pet->AttackStop();
-
if(pet->GetTypeId() != TYPEID_PLAYER)
{
if (((Creature*)pet)->AI())
@@ -123,6 +120,9 @@ void WorldSession::HandlePetAction( WorldPacket & recv_data )
}
else // charmed player
{
+ if(pet->getVictim() && pet->getVictim() != TargetUnit)
+ pet->AttackStop();
+
pet->Attack(TargetUnit,true);
pet->SendPetAIReaction(guid1);
}