phaser/v3/src/gameobjects/tilemap/components/HasTileAtWorldXY.js

14 lines
388 B
JavaScript
Raw Normal View History

var HasTileAt = require('./HasTileAt');
var WorldToTileX = require('./WorldToTileX');
var WorldToTileY = require('./WorldToTileY');
var HasTileAtWorldXY = function (worldX, worldY, camera, layer)
{
var tileX = WorldToTileX(worldX, camera, layer);
var tileY = WorldToTileY(worldY, camera, layer);
return HasTileAt(tileX, tileY, layer);
};
module.exports = HasTileAtWorldXY;