diff options
Diffstat (limited to '')
-rw-r--r-- | src/koopatlas/map.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/koopatlas/map.cpp b/src/koopatlas/map.cpp index 7869fde..316c001 100644 --- a/src/koopatlas/map.cpp +++ b/src/koopatlas/map.cpp @@ -115,6 +115,14 @@ void dWMMap_c::renderer_c::drawLayers() { dKPLayer_s *layer = data->layers[iLayer]; renderMtx[2][3] += 2.0f; + if (layer->type == dKPLayer_s::PATHS) { + // rebase the camera matrix + baseZ = 3500.0f; + nw4r::g3d::Camera cam3d(GetCameraByID(0)); + cam3d.GetCameraMtx(&renderMtx); + MTXTransApply(renderMtx, renderMtx, 0, 0, baseZ); + } + if (layer->alpha == 0) continue; // invisible @@ -126,14 +134,6 @@ void dWMMap_c::renderer_c::drawLayers() { renderTileLayer(layer, data->sectors); else if (layer->type == dKPLayer_s::DOODADS) renderDoodadLayer(layer); - - if (layer->type == dKPLayer_s::PATHS) { - // rebase the camera matrix - baseZ = 3500.0f; - nw4r::g3d::Camera cam3d(GetCameraByID(0)); - cam3d.GetCameraMtx(&renderMtx); - MTXTransApply(renderMtx, renderMtx, 0, 0, baseZ); - } } endRendering(); |