mirror of
https://github.com/photonstorm/phaser
synced 2024-11-29 16:10:56 +00:00
Merge pull request #5533 from veleek/veleek/isometricfix
Fix IsometricWorldToTileXY result
This commit is contained in:
commit
641a7c5d99
1 changed files with 0 additions and 2 deletions
|
@ -50,8 +50,6 @@ var IsometricWorldToTileXY = function (worldX, worldY, snapToFloor, point, camer
|
|||
tileWidth *= tilemapLayer.scaleX;
|
||||
}
|
||||
|
||||
worldX -= tileWidth / 2;
|
||||
|
||||
var x = (snapToFloor) ? Math.floor((worldX / (tileWidth / 2) + worldY / (tileHeight / 2)) / 2) : ((worldX / (tileWidth / 2) + worldY / (tileHeight / 2)) / 2);
|
||||
var y = (snapToFloor) ? Math.floor((worldY / (tileHeight / 2) - worldX / (tileWidth / 2)) / 2) : ((worldY / (tileHeight / 2) - worldX / (tileWidth / 2)) / 2);
|
||||
|
||||
|
|
Loading…
Reference in a new issue