phaser/src/gameobjects/tilesprite/TileSpriteWebGLRenderer.js
2018-01-09 21:43:56 +00:00

15 lines
403 B
JavaScript

var GameObject = require('../GameObject');
var TileSpriteWebGLRenderer = function (renderer, src, interpolationPercentage, camera)
{
if (GameObject.RENDER_MASK !== src.renderFlags || (src.cameraFilter > 0 && (src.cameraFilter & camera._id)))
{
return;
}
src.updateTileTexture();
renderer.tileBatch.addTileSprite(src, camera);
};
module.exports = TileSpriteWebGLRenderer;