Squall Posted April 23, 2016 Share Posted April 23, 2016 Hello! I am working with Phaser and having some problem to collide sprite with tiles, the sprite can walk through everything. on create: map = game.add.tilemap('ninomap'); map.addTilesetImage('tilesheet', 'tilesheet'); ground = map.createLayer('background'); ground.resizeWorld(); wcollide = map.createLayer('walls'); map.setCollision(1624, true, wcollide); Where 1624 is the index of tile to collide. I've been looking the posts on this forums, but couldn't get it to work yet, so i'm asking for help to understand the collide system on Phaser and how can i get my sprite to collide with certain tile indexes or layers. Link to comment Share on other sites More sharing options...
Kseiver Posted May 1, 2017 Share Posted May 1, 2017 Did put this.game.physics.arcade.collide in update function? Link to comment Share on other sites More sharing options...
Recommended Posts