refactor(Core/Maps): Change map file version from FourCC to uint32 (#7866)

Co-Authored-By: Giacomo Pozzoni <giacomopoz@gmail.com>
This commit is contained in:
Kitzunu
2021-09-20 00:45:42 +02:00
committed by GitHub
parent b70083599b
commit 6df7303b24
3 changed files with 12 additions and 8 deletions

View File

@@ -298,7 +298,7 @@ void ReadLiquidTypeTableDBC()
// Map file format data
static char const* MAP_MAGIC = "MAPS";
static char const* MAP_VERSION_MAGIC = "v1.8";
static uint32 const MAP_VERSION_MAGIC = 8;
static char const* MAP_AREA_MAGIC = "AREA";
static char const* MAP_HEIGHT_MAGIC = "MHGT";
static char const* MAP_LIQUID_MAGIC = "MLIQ";
@@ -415,7 +415,7 @@ bool ConvertADT(std::string const& inputPath, std::string const& outputPath, int
// Prepare map header
map_fileheader map;
map.mapMagic = *reinterpret_cast<uint32 const*>(MAP_MAGIC);
map.versionMagic = *reinterpret_cast<uint32 const*>(MAP_VERSION_MAGIC);
map.versionMagic = MAP_VERSION_MAGIC;
map.buildMagic = build;
// Get area flags data