*Fix some bugs of map/grid. Hope this can fix some crashes (without introducing new crash)

--HG--
branch : trunk
This commit is contained in:
megamage
2009-02-17 21:50:18 -06:00
parent d11c80ec54
commit be53cfe104
8 changed files with 31 additions and 202 deletions
+1 -7
View File
@@ -168,7 +168,6 @@ class TRINITY_DLL_SPEC Map : public GridRefManager<NGridType>, public Trinity::O
bool GetUnloadFlag(const GridPair &p) const { return getNGrid(p.x_coord, p.y_coord)->getUnloadFlag(); }
void SetUnloadFlag(const GridPair &p, bool unload) { getNGrid(p.x_coord, p.y_coord)->setUnloadFlag(unload); }
void LoadGrid(const Cell& cell, bool no_unload = false);
void LoadGrid(float x, float y);
bool UnloadGrid(const uint32 &x, const uint32 &y, bool pForce);
virtual void UnloadAll(bool pForce);
@@ -240,8 +239,6 @@ class TRINITY_DLL_SPEC Map : public GridRefManager<NGridType>, public Trinity::O
virtual bool RemoveBones(uint64 guid, float x, float y);
void UpdateObjectVisibility(WorldObject* obj, Cell cell, CellPair cellpair);
//void UpdatePlayerVisibility(Player* player, Cell cell, CellPair cellpair);
void UpdateObjectsVisibilityFor(Player* player, Cell cell, CellPair cellpair);
void resetMarkedCells() { marked_cells.reset(); }
bool isCellMarked(uint32 pCellId) { return marked_cells.test(pCellId); }
@@ -279,9 +276,6 @@ class TRINITY_DLL_SPEC Map : public GridRefManager<NGridType>, public Trinity::O
void SendInitTransports( Player * player );
void SendRemoveTransports( Player * player );
void PlayerRelocationNotify(Player* player, Cell cell, CellPair cellpair);
void CreatureRelocationNotify(Creature *creature, Cell newcell, CellPair newval);
bool CreatureCellRelocation(Creature *creature, Cell new_cell);
void AddCreatureToMoveList(Creature *c, float x, float y, float z, float ang);
@@ -338,7 +332,7 @@ class TRINITY_DLL_SPEC Map : public GridRefManager<NGridType>, public Trinity::O
void AddToGrid(T*, NGridType *, Cell const&);
template<class T>
void AddNotifier(T*, Cell const&, CellPair const&);
void AddNotifier(T*);
template<class T>
void RemoveFromGrid(T*, NGridType *, Cell const&);