*Remove some code which may cause crash.

--HG--
branch : trunk
This commit is contained in:
megamage
2009-03-31 14:08:38 -06:00
parent 1fe8050b09
commit b51cea6ce4
5 changed files with 9 additions and 12 deletions
+4 -4
View File
@@ -311,8 +311,8 @@ bool OutdoorPvPObjective::DelCreature(uint32 type)
// explicit removal from map
// beats me why this is needed, but with the recent removal "cleanup" some creatures stay in the map if "properly" deleted
// so this is a big fat workaround, if AddObjectToRemoveList and DoDelayedMovesAndRemoves worked correctly, this wouldn't be needed
if(Map * map = MapManager::Instance().FindMap(cr->GetMapId()))
map->Remove(cr,false);
//if(Map * map = MapManager::Instance().FindMap(cr->GetMapId()))
// map->Remove(cr,false);
// delete respawn time for this creature
WorldDatabase.PExecute("DELETE FROM creature_respawn WHERE guid = '%u'", guid);
cr->AddObjectToRemoveList();
@@ -369,8 +369,8 @@ bool OutdoorPvPObjective::DelCapturePoint()
// explicit removal from map
// beats me why this is needed, but with the recent removal "cleanup" some creatures stay in the map if "properly" deleted
// so this is a big fat workaround, if AddObjectToRemoveList and DoDelayedMovesAndRemoves worked correctly, this wouldn't be needed
if(Map * map = MapManager::Instance().FindMap(cr->GetMapId()))
map->Remove(cr,false);
//if(Map * map = MapManager::Instance().FindMap(cr->GetMapId()))
// map->Remove(cr,false);
// delete respawn time for this creature
WorldDatabase.PExecute("DELETE FROM creature_respawn WHERE guid = '%u'", guid);
cr->AddObjectToRemoveList();