aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/tools/mesh_extractor/ContinentBuilder.cpp1
-rw-r--r--src/tools/mesh_extractor/LiquidHandler.cpp3
-rw-r--r--src/tools/mesh_extractor/MapChunk.cpp2
3 files changed, 5 insertions, 1 deletions
diff --git a/src/tools/mesh_extractor/ContinentBuilder.cpp b/src/tools/mesh_extractor/ContinentBuilder.cpp
index 29541da508c..9d3b18491f1 100644
--- a/src/tools/mesh_extractor/ContinentBuilder.cpp
+++ b/src/tools/mesh_extractor/ContinentBuilder.cpp
@@ -17,6 +17,7 @@ public:
int svc()
{
Free = false;
+ printf("[%02i,%02i] Building tile", X, Y);
TileBuilder builder(Continent, X, Y, MapId);
char buff[100];
sprintf(buff, "%03u%02u%02u.mmtile", MapId, X, Y);
diff --git a/src/tools/mesh_extractor/LiquidHandler.cpp b/src/tools/mesh_extractor/LiquidHandler.cpp
index 3d0876aeb74..f6f8e5678c6 100644
--- a/src/tools/mesh_extractor/LiquidHandler.cpp
+++ b/src/tools/mesh_extractor/LiquidHandler.cpp
@@ -31,7 +31,10 @@ void LiquidHandler::HandleNewLiquid()
float** heights = new float*[9];
for (int i = 0; i < 9; ++i)
+ {
heights[i] = new float[9];
+ memset(heights[i], 0, sizeof(float) * 9);
+ }
H2ORenderMask renderMask;
if (information.LiquidType != 2)
diff --git a/src/tools/mesh_extractor/MapChunk.cpp b/src/tools/mesh_extractor/MapChunk.cpp
index debde08cda8..67f4061035e 100644
--- a/src/tools/mesh_extractor/MapChunk.cpp
+++ b/src/tools/mesh_extractor/MapChunk.cpp
@@ -31,7 +31,7 @@ void MapChunk::GenerateTriangles()
if (Adt->_LiquidHandler && !Adt->_LiquidHandler->MCNKData.empty())
{
MCNKLiquidData& data = Adt->_LiquidHandler->MCNKData[Index];
- uint32 maxHeight = std::max(
+ float maxHeight = std::max(
std::max(
std::max(std::max(Vertices[topLeft].z, Vertices[topRight].z), Vertices[bottomLeft].z),
Vertices[bottomRight].z), Vertices[center].z);