summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorTreeki <treeki@gmail.com>2012-09-19 03:15:41 +0200
committerTreeki <treeki@gmail.com>2012-09-19 03:15:41 +0200
commit1c8b69ac3606dccfe94cab943c925877a5683535 (patch)
tree43808abe8a54b349d2a419c8e69184e395961d50 /src
parent70fd03b724fb66981af89efc86064700b1ea1511 (diff)
downloadkamek-1c8b69ac3606dccfe94cab943c925877a5683535.tar.gz
kamek-1c8b69ac3606dccfe94cab943c925877a5683535.zip
okay this one REALLY does fix the overlaps
Diffstat (limited to '')
-rw-r--r--src/koopatlas/map.cpp16
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();