*Fix usage of grid removal state, thanks Sisif

--HG--
branch : trunk
This commit is contained in:
maximius
2009-10-31 17:34:35 -07:00
parent a9d4bda2cc
commit 85d7084e85
5 changed files with 20 additions and 30 deletions
+6
View File
@@ -304,6 +304,12 @@ class MANGOS_DLL_SPEC Map : public GridRefManager<NGridType>, public MaNGOS::Obj
return !getNGrid(p.x_coord, p.y_coord) || getNGrid(p.x_coord, p.y_coord)->GetGridState() == GRID_STATE_REMOVAL;
}
bool IsLoaded(float x, float y) const
{
GridPair p = Trinity::ComputeGridPair(x, y);
return loaded(p);
}
bool GetUnloadLock(const GridPair &p) const { return getNGrid(p.x_coord, p.y_coord)->getUnloadLock(); }
void SetUnloadLock(const GridPair &p, bool on) { getNGrid(p.x_coord, p.y_coord)->setUnloadExplicitLock(on); }
void LoadGrid(float x, float y);