From aae73c3cb881ffcc084e2a6ad9ad8d5f4a1948f5 Mon Sep 17 00:00:00 2001 From: Svipal Date: Mon, 13 Apr 2020 18:40:58 +0200 Subject: [PATCH] fixed independent ttw calls in physics/arcade/World.js --- src/physics/arcade/World.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/physics/arcade/World.js b/src/physics/arcade/World.js index 72766aa6f..a2bdf29c5 100644 --- a/src/physics/arcade/World.js +++ b/src/physics/arcade/World.js @@ -2210,8 +2210,10 @@ var World = new Class({ tilemapLayer = tile.tilemapLayer; - tileWorldRect.left = tilemapLayer.tileToWorldX(tile.x); - tileWorldRect.top = tilemapLayer.tileToWorldY(tile.y); + var point = tilemapLayer.tileToWorldXY(tile.x,tile.y); + + tileWorldRect.left = point.x; + tileWorldRect.top = point.y; // If the map's base tile size differs from the layer's tile size, only the top of the rect // needs to be adjusted since its origin is (0, 1).