Skip to content

Commit 7a1667f

Browse files
committed
Fixed typo on collision for TileMapLayers (lesson to triple check your code...)
1 parent 5492ed0 commit 7a1667f

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/physics/arcade/TilemapCollision.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -254,7 +254,7 @@ Phaser.Physics.Arcade.TilemapCollision.prototype = {
254254
else if (body.deltaX() > 0 && !body.blocked.right && tile.collideLeft && body.checkCollision.right)
255255
{
256256
// Body is moving RIGHT
257-
if (tile.faceLeft && (body.right - tilemapLayer.position.y) > tile.left)
257+
if (tile.faceLeft && (body.right - tilemapLayer.position.x) > tile.left)
258258
{
259259
ox = (body.right - tilemapLayer.position.x) - tile.left;
260260

0 commit comments

Comments
 (0)