mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-29 00:23:48 +00:00
feat(Tools/MMaps): Allow to specify different Recast settings for different maps (#10922)
This commit is contained in:
committed by
GitHub
parent
62f6513c9a
commit
5b0af98097
@@ -72,6 +72,27 @@ namespace MMAP
|
||||
rcPolyMeshDetail* dmesh{nullptr};
|
||||
};
|
||||
|
||||
struct TileConfig
|
||||
{
|
||||
TileConfig(bool bigBaseUnit)
|
||||
{
|
||||
// these are WORLD UNIT based metrics
|
||||
// this are basic unit dimentions
|
||||
// value have to divide GRID_SIZE(533.3333f) ( aka: 0.5333, 0.2666, 0.3333, 0.1333, etc )
|
||||
BASE_UNIT_DIM = bigBaseUnit ? 0.5333333f : 0.2666666f;
|
||||
|
||||
// All are in UNIT metrics!
|
||||
VERTEX_PER_MAP = int(GRID_SIZE / BASE_UNIT_DIM + 0.5f);
|
||||
VERTEX_PER_TILE = bigBaseUnit ? 40 : 80; // must divide VERTEX_PER_MAP
|
||||
TILES_PER_MAP = VERTEX_PER_MAP / VERTEX_PER_TILE;
|
||||
}
|
||||
|
||||
float BASE_UNIT_DIM;
|
||||
int VERTEX_PER_MAP;
|
||||
int VERTEX_PER_TILE;
|
||||
int TILES_PER_MAP;
|
||||
};
|
||||
|
||||
class MapBuilder
|
||||
{
|
||||
public:
|
||||
@@ -126,6 +147,8 @@ namespace MMAP
|
||||
bool isTransportMap(uint32 mapID);
|
||||
bool shouldSkipTile(uint32 mapID, uint32 tileX, uint32 tileY);
|
||||
|
||||
rcConfig GetMapSpecificConfig(uint32 mapID, float bmin[3], float bmax[3], const TileConfig &tileConfig);
|
||||
|
||||
uint32 percentageDone(uint32 totalTiles, uint32 totalTilesDone);
|
||||
|
||||
TerrainBuilder* m_terrainBuilder{nullptr};
|
||||
|
||||
Reference in New Issue
Block a user