function mountPrerenderCanvas(map) {
        // calculate how big the prerender map must be
        var prerender = {};
        prerender.tilesPerRow = Math.ceil(Sylx.Canvas.width / map.tileSize.x) + 1;
        prerender.tilesPerCol = Math.ceil(Sylx.Canvas.height / map.tileSize.y) + 1;
        prerender.tileSize = map.tileSize;
        // get smallest canvas size that can contain enough tiles to fit the screen, and then add one row and one column on each edge
        // create prerender canvas
        var prerenderCanvasWidth = prerender.tilesPerRow * map.tileSize.x;
        var prerenderCanvasHeight = prerender.tilesPerCol * map.tileSize.y;
        prerender.canvas = Sylx.Canvas.create(prerenderCanvasWidth, prerenderCanvasHeight);
        prerender.topLeft = new Sylx.Point(0, 0);
        map.prerender = prerender;
    }
/**
     * Creates a new canvas used to prerender maps
     * @param {object} map The map object
     */
Creates a new canvas used to prerender maps
@param {object} map The map object
Creates a new canvas used to prerender maps @param { object } map The map object
function mountPrerenderCanvas(map) {
        var prerender = {};
        prerender.tilesPerRow = Math.ceil(Sylx.Canvas.width / map.tileSize.x) + 1;
        prerender.tilesPerCol = Math.ceil(Sylx.Canvas.height / map.tileSize.y) + 1;
        prerender.tileSize = map.tileSize;
        var prerenderCanvasWidth = prerender.tilesPerRow * map.tileSize.x;
        var prerenderCanvasHeight = prerender.tilesPerCol * map.tileSize.y;
        prerender.canvas = Sylx.Canvas.create(prerenderCanvasWidth, prerenderCanvasHeight);
        prerender.topLeft = new Sylx.Point(0, 0);
        map.prerender = prerender;
    }
function mountPrerenderCanvas ( map ) { var prerender = { } ; prerender . tilesPerRow = Math . ceil ( Sylx . Canvas . width / map . tileSize . x ) + 1 ; prerender . tilesPerCol = Math . ceil ( Sylx . Canvas . height / map . tileSize . y ) + 1 ; prerender . tileSize = map . tileSize ; var prerenderCanvasWidth = prerender . tilesPerRow * map . tileSize . x ; var prerenderCanvasHeight = prerender . tilesPerCol * map . tileSize . y ; prerender . canvas = Sylx . Canvas . create ( prerenderCanvasWidth , prerenderCanvasHeight ) ; prerender . topLeft = new Sylx . Point ( 0 , 0 ) ; map . prerender = prerender ; }
Creates a new canvas used to prerender maps
 @param {object} map The map object
Creates a new canvas used to prerender maps @param { object } map The map object
// calculate how big the prerender map must be // get smallest canvas size that can contain enough tiles to fit the screen, and then add one row and one column on each edge // create prerender canvas