Clean up grid system. Get rid of GridLoader. This patch should not change any logic, except the incorrect calculation of the number of loaded corpse (which only affects log).
This commit is contained in:
@@ -35,8 +35,9 @@ ActiveState::Update(Map &m, NGridType &grid, GridInfo & info, const uint32 x, co
|
||||
{
|
||||
if (grid.ActiveObjectsInGrid() == 0 && !m.ActiveObjectsNearGrid(x, y))
|
||||
{
|
||||
ObjectGridStoper stoper(grid);
|
||||
stoper.StopN();
|
||||
ObjectGridStoper worker;
|
||||
TypeContainerVisitor<ObjectGridStoper, GridTypeMapContainer> visitor(worker);
|
||||
grid.VisitAllGrids(visitor);
|
||||
grid.SetGridState(GRID_STATE_IDLE);
|
||||
sLog->outDebug(LOG_FILTER_MAPS, "Grid[%u, %u] on map %u moved to IDLE state", x, y, m.GetId());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user