From a8b2c39101a9f6070215d8598e9cfa08968e9770 Mon Sep 17 00:00:00 2001 From: gered Date: Sun, 4 Aug 2013 16:30:11 -0400 Subject: [PATCH] fix incorrect calculations when setting output map dimensions --- src/com/blarg/gdx/tilemap3d/serialization/TileMapLoader.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/com/blarg/gdx/tilemap3d/serialization/TileMapLoader.java b/src/com/blarg/gdx/tilemap3d/serialization/TileMapLoader.java index b35f2d7..5b16554 100644 --- a/src/com/blarg/gdx/tilemap3d/serialization/TileMapLoader.java +++ b/src/com/blarg/gdx/tilemap3d/serialization/TileMapLoader.java @@ -74,8 +74,8 @@ public class TileMapLoader { jsonMap.chunkHeight = tileMap.getChunks()[0].getHeight(); jsonMap.chunkDepth = tileMap.getChunks()[0].getDepth(); jsonMap.widthInChunks = tileMap.getWidth() / jsonMap.chunkWidth; - jsonMap.heightInChunks = tileMap.getWidth() / jsonMap.chunkHeight; - jsonMap.depthInChunks = tileMap.getWidth() / jsonMap.chunkDepth; + jsonMap.heightInChunks = tileMap.getHeight() / jsonMap.chunkHeight; + jsonMap.depthInChunks = tileMap.getDepth() / jsonMap.chunkDepth; // TODO: figure out real lighting mode from the types of vertex generator / lighter objects set jsonMap.lightingMode = null;