*Do not assert !map for non-corpse worldobjects.

--HG--
branch : trunk
This commit is contained in:
megamage committed 2009-08-13 17:02:17 -05:00
1 parent deca044373
commit c9ddf9258d
2 files changed
+10 -6

No files matched your search

+6 -2
View File
@@ -82,10 +82,14 @@ Object::Object( ) : m_PackGUID(sizeof(uint64)+1)
WorldObject::~WorldObject()
{
// this may happen because there are many !create/delete
if(m_isWorldObject && m_currMap)
{
sLog.outCrash("Object::~Object - guid="UI64FMTD", typeid=%d, entry=%u deleted but still in map!!", GetGUID(), GetTypeId(), GetEntry());
assert(false);
if(GetTypeId() == TYPEID_CORPSE)
{
sLog.outCrash("Object::~Object Corpse guid="UI64FMTD", type=%d, entry=%u deleted but still in map!!", GetGUID(), ((Corpse*)this)->GetType(), GetEntry());
assert(false);
}
ResetMap();
}
}