From: RealBadAngel Date: Sun, 20 Jul 2014 14:22:48 +0000 (+0200) Subject: Bugfix in makeCuboid - apply rotations to all faces when 1 tile is given. X-Git-Url: http://81.2.79.47:8989/gitweb/?a=commitdiff_plain;h=70074800a207974a0c1383275186cefe6955f297;p=zefram%2Fminetest%2Fminetest_engine.git Bugfix in makeCuboid - apply rotations to all faces when 1 tile is given. --- diff --git a/src/content_mapblock.cpp b/src/content_mapblock.cpp index 32e80c29..a00d9f30 100644 --- a/src/content_mapblock.cpp +++ b/src/content_mapblock.cpp @@ -99,9 +99,9 @@ void makeCuboid(MeshCollector *collector, const aabb3f &box, video::S3DVertex(min.X,min.Y,min.Z, 0,0,-1, c, txc[20],txc[23]), }; - for(int i = 0; i < tilecount; i++) + for(int i = 0; i < 6; i++) { - switch (tiles[i].rotation) + switch (tiles[MYMIN(i, tilecount-1)].rotation) { case 0: break;