mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-28 04:42:10 +01:00
[8149] Use formula instead hardcoded value for CENTER_GRID_CELL_ID calculation. Author: XTZGZoReX
--HG-- branch : trunk
This commit is contained in:
@@ -35,10 +35,8 @@ class Player;
|
||||
|
||||
#ifdef LARGE_CELL
|
||||
#define MAX_NUMBER_OF_CELLS 4
|
||||
#define CENTER_GRID_CELL_ID 128
|
||||
#else
|
||||
#define MAX_NUMBER_OF_CELLS 8
|
||||
#define CENTER_GRID_CELL_ID 256
|
||||
#endif
|
||||
|
||||
#define MAX_NUMBER_OF_GRIDS 64
|
||||
@@ -53,6 +51,7 @@ class Player;
|
||||
|
||||
#define SIZE_OF_GRID_CELL (SIZE_OF_GRIDS/MAX_NUMBER_OF_CELLS)
|
||||
|
||||
#define CENTER_GRID_CELL_ID (MAX_NUMBER_OF_CELLS*MAX_NUMBER_OF_GRIDS/2)
|
||||
#define CENTER_GRID_CELL_OFFSET (SIZE_OF_GRID_CELL/2)
|
||||
|
||||
#define TOTAL_NUMBER_OF_CELLS_PER_MAP (MAX_NUMBER_OF_GRIDS*MAX_NUMBER_OF_CELLS)
|
||||
|
||||
Reference in New Issue
Block a user