MCPcopy Create free account
hub / github.com/Vishal-raj-1/Awesome-JavaScript-Projects / drawEndSprite

Function drawEndSprite

assets/js/maze.js:292–307  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

290 }
291
292 function drawEndSprite() {
293 var offsetLeft = cellSize / 50;
294 var offsetRight = cellSize / 25;
295 var coord = Maze.endCoord();
296 ctx.drawImage(
297 endSprite,
298 2,
299 2,
300 endSprite.width,
301 endSprite.height,
302 coord.x * cellSize + offsetLeft,
303 coord.y * cellSize + offsetLeft,
304 cellSize - offsetRight,
305 cellSize - offsetRight
306 );
307 }
308
309 function clear() {
310 var canvasSize = cellSize * map.length;

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected