From fe6799d00bae75c6d2ef9f9a6911f49acd983e0b Mon Sep 17 00:00:00 2001 From: Jonas Kulla Date: Fri, 10 Jul 2015 04:58:28 +0200 Subject: [PATCH] TilemapVX: Fix map viewport calculation --- src/tilemapvx.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/tilemapvx.cpp b/src/tilemapvx.cpp index 039bd2c..57abe26 100644 --- a/src/tilemapvx.cpp +++ b/src/tilemapvx.cpp @@ -188,7 +188,7 @@ struct TilemapVXPrivate : public ViewportElement, TileAtlasVX::Reader { int tileOX, tileOY; - Vec2i offs(offset.x-sceneOffset.x, offset.y-sceneOffset.y); + Vec2i offs = offset + sceneGeo.orig; if (offs.x >= 0) tileOX = offs.x / 32;