Fix Issue #6301 causing tilemap collisions to fail.

This commit is contained in:
Christen Lofland 2022-11-30 15:28:59 -06:00
parent 1747cb67be
commit e52f1738ef

View file

@ -25,7 +25,7 @@ var Vector2 = require('../../math/Vector2');
*/
var WorldToTileXY = function (worldX, worldY, snapToFloor, point, camera, layer)
{
if (!snapToFloor) { snapToFloor = true; }
if (snapToFloor === undefined) { snapToFloor = true; }
if (!point) { point = new Vector2(); }
var tileWidth = layer.baseTileWidth;