aboutsummaryrefslogtreecommitdiff
path: root/src/server/game/Maps/MapInstanced.h
diff options
context:
space:
mode:
authorShocker <shocker@freakz.ro>2014-09-19 18:03:49 +0300
committerShocker <shocker@freakz.ro>2014-09-19 18:03:49 +0300
commit80f77977f14c8f879fea8451f370c5590c5f04f7 (patch)
treef75f8efe6eb237b02fcc8b1d92ff980209e49340 /src/server/game/Maps/MapInstanced.h
parentc678eaa71e6ad57866ba061af948b157d3232e6b (diff)
Core/Grids: Replace some magic numbers with constants
(P.S.: That's why! @cs_misc.cpp)
Diffstat (limited to 'src/server/game/Maps/MapInstanced.h')
-rw-r--r--src/server/game/Maps/MapInstanced.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/server/game/Maps/MapInstanced.h b/src/server/game/Maps/MapInstanced.h
index 614764dbba3..ecf7c0a28fc 100644
--- a/src/server/game/Maps/MapInstanced.h
+++ b/src/server/game/Maps/MapInstanced.h
@@ -50,14 +50,14 @@ class MapInstanced : public Map
void AddGridMapReference(const GridCoord &p)
{
++GridMapReference[p.x_coord][p.y_coord];
- SetUnloadReferenceLock(GridCoord(63-p.x_coord, 63-p.y_coord), true);
+ SetUnloadReferenceLock(GridCoord((MAX_NUMBER_OF_GRIDS - 1) - p.x_coord, (MAX_NUMBER_OF_GRIDS - 1) - p.y_coord), true);
}
void RemoveGridMapReference(GridCoord const& p)
{
--GridMapReference[p.x_coord][p.y_coord];
if (!GridMapReference[p.x_coord][p.y_coord])
- SetUnloadReferenceLock(GridCoord(63-p.x_coord, 63-p.y_coord), false);
+ SetUnloadReferenceLock(GridCoord((MAX_NUMBER_OF_GRIDS - 1) - p.x_coord, (MAX_NUMBER_OF_GRIDS - 1) - p.y_coord), false);
}
InstancedMaps &GetInstancedMaps() { return m_InstancedMaps; }