From 55082a0925490d6db65acc3dac3fe061ff6bd521 Mon Sep 17 00:00:00 2001 From: Kelsi Date: Mon, 9 Mar 2026 16:09:44 -0700 Subject: [PATCH] Remove unused baseZ/hasHeights variables in WaterRenderer::loadFromWMO MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit These were declared to handle per-vertex WMO liquid height variation but never actually used below — the surface is built with a flat adjustedZ height throughout. Remove to eliminate -Wunused-variable warnings. --- src/rendering/water_renderer.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/rendering/water_renderer.cpp b/src/rendering/water_renderer.cpp index a01cfedb..d79e53f7 100644 --- a/src/rendering/water_renderer.cpp +++ b/src/rendering/water_renderer.cpp @@ -942,13 +942,10 @@ void WaterRenderer::loadFromWMO([[maybe_unused]] const pipeline::WMOLiquid& liqu if (surface.origin.z > 2000.0f || surface.origin.z < -500.0f) return; - // Build tile mask from MLIQ flags and per-vertex heights + // Build tile mask from MLIQ flags size_t tileCount = static_cast(surface.width) * static_cast(surface.height); size_t maskBytes = (tileCount + 7) / 8; surface.mask.assign(maskBytes, 0x00); - const float baseZ = liquid.basePosition.z; - const bool hasHeights = !liquid.heights.empty() && - liquid.heights.size() >= static_cast(vertexCount); for (size_t t = 0; t < tileCount; t++) { bool hasLiquid = true; int tx = static_cast(t) % surface.width;