Tools/vmap assembler: Move TileAssembler from common to vmap4_assembler where it belongs

This commit is contained in:
Shauren
2020-05-10 15:24:43 +02:00
parent fe7a0c9ad8
commit 16761e1d7c
5 changed files with 11 additions and 8 deletions

View File

@@ -32,6 +32,12 @@ using G3D::Vector3;
namespace VMAP
{
bool readChunk(FILE* rf, char* dest, const char* compare, uint32 len)
{
if (fread(dest, sizeof(char), len, rf) != len) return false;
return memcmp(dest, compare, len) == 0;
}
VMapManager2::VMapManager2()
{
GetLiquidFlagsPtr = &GetLiquidFlagsDummy;

View File

@@ -28,7 +28,7 @@ namespace VMAP
const char RAW_VMAP_MAGIC[] = "VMAP048"; // used in extracted vmap files with raw data
const char GAMEOBJECT_MODELS[] = "GameObjectModels.dtree";
// defined in TileAssembler.cpp currently...
// defined in VMapManager2.cpp currently...
bool readChunk(FILE* rf, char *dest, const char *compare, uint32 len);
}

View File

@@ -8,7 +8,10 @@
# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
set(PRIVATE_SOURCES VMapAssembler.cpp)
set(PRIVATE_SOURCES
TileAssembler.cpp
TileAssembler.h
VMapAssembler.cpp)
if (WIN32)
list(APPEND PRIVATE_SOURCES ${sources_windows})

View File

@@ -37,12 +37,6 @@ template<> struct BoundsTrait<VMAP::ModelSpawn*>
namespace VMAP
{
bool readChunk(FILE* rf, char *dest, const char *compare, uint32 len)
{
if (fread(dest, sizeof(char), len, rf) != len) return false;
return memcmp(dest, compare, len) == 0;
}
Vector3 ModelPosition::transform(const Vector3& pIn) const
{
Vector3 out = pIn * iScale;