aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authormegamage <none@none>2009-04-04 15:04:24 -0600
committermegamage <none@none>2009-04-04 15:04:24 -0600
commit86bd3bfb422a299d6e0aac0f196ba4fea9affbc4 (patch)
tree5bd916d0cf893417bf9dbf25d851d34a6af18a20 /src
parenteede65e115ebbbcf322054e5e11e2675a188dcfd (diff)
*Do not check formation for pet and summoned creatures.
--HG-- branch : trunk
Diffstat (limited to 'src')
-rw-r--r--src/game/Creature.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/game/Creature.cpp b/src/game/Creature.cpp
index 19d23162873..471934f4f80 100644
--- a/src/game/Creature.cpp
+++ b/src/game/Creature.cpp
@@ -199,9 +199,12 @@ void Creature::RemoveFromWorld()
void Creature::SearchFormation()
{
+ if(isPet())
+ return;
+
uint32 lowguid = GetDBTableGUIDLow();
- if(CreatureGroupMap.find(lowguid) != CreatureGroupMap.end())
+ if(lowguid && CreatureGroupMap.find(lowguid) != CreatureGroupMap.end())
{
m_formationID = CreatureGroupMap[lowguid]->leaderGUID;
formation_mgr.UpdateCreatureGroup(m_formationID, this);