--HG--
branch : trunk
This commit is contained in:
megamage committed 2009-05-25 12:51:14 -05:00
commit 00f50798d3
11 files changed
+114 -30

No files matched your search

+8 -2
View File
@@ -30,6 +30,7 @@
#include "CreatureAI.h"
#include "Util.h"
#include "Pet.h"
#include "World.h"
void WorldSession::HandlePetAction( WorldPacket & recv_data )
{
@@ -122,9 +123,14 @@ void WorldSession::HandlePetActionHelper(Unit *pet, uint64 guid1, uint16 spellid
return;
// Not let attack through obstructions
//if(!pet->IsWithinLOSInMap(TargetUnit))
// return;
if(sWorld.getConfig(CONFIG_PET_LOS))
{
if(!pet->IsWithinLOSInMap(TargetUnit))
return;
}
pet->clearUnitState(UNIT_STAT_FOLLOW);
// This is true if pet has no target or has target but targets differs.
if(pet->getVictim() != TargetUnit)