*ResetMap for worldobjects when map is deleted.
--HG-- branch : trunk
This commit is contained in:
1 parent
9403ff03e7
commit
962b88a381
4 files changed
+29
-5
No files matched your search
+5
-1
@@ -60,6 +60,9 @@ Map::~Map()
|
||||
{
|
||||
UnloadAll();
|
||||
|
||||
while(!i_worldObjects.empty())
|
||||
(*(i_worldObjects.begin()))->ResetMap();
|
||||
|
||||
if(!m_scriptSchedule.empty())
|
||||
sWorld.DecreaseScheduledScriptCount(m_scriptSchedule.size());
|
||||
}
|
||||
@@ -581,8 +584,9 @@ void Map::AddUnitToNotify(Unit* u)
|
||||
}
|
||||
}
|
||||
|
||||
void Map::RemoveUnitFromNotify(Unit *unit, int32 slot)
|
||||
void Map::RemoveUnitFromNotify(Unit *unit)
|
||||
{
|
||||
int32 slot = unit->m_NotifyListPos;
|
||||
if(i_lock)
|
||||
{
|
||||
if(slot < i_unitsToNotifyBacklog.size() && i_unitsToNotifyBacklog[slot] == unit)
|
||||
|
||||
Reference in new issue
Block a user