Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
this.tileLayer = this.tileMap.create('demoLayer', WIDTH_TILES, HEIGHT_TILES, TILE_SIZE, TILE_SIZE);
this.tileLayer.resizeWorld();
this.drawAllGround();
this.drawInitGrid();
this.updateNavMesh();
game.input.addMoveCallback(this.updateMarker, this);
game.input.onUp.add(this.onUp, this);
game.canvas.oncontextmenu = this.onRightClick;
this.cursors = game.input.keyboard.createCursorKeys();
this.isSpriteStamp = false;
this.spriteUUIDs = [];
game.input.keyboard.addKey(Keyboard.P).onDown.add(() => game.paused = !game.paused, this);
game.input.keyboard.addKey(Keyboard.SPACEBAR).onDown.add(() => game.paused = !game.paused, this);
game.input.keyboard.addKey(Keyboard.S).onDown.add(() => this.isSpriteStamp = !this.isSpriteStamp);
game.input.keyboard.addKey(Keyboard.K).onDown.add(() => this.removeSprite());
this.spriteGroup = new Phaser.Group(game);
new DemoSprite(game, 200, 500, this.spriteGroup, this.tileLayer);
}