Jump to content

What´s the best way to let your character to jump through platforms?

Recommended Posts


I have this basic platform game and I would like the hero to jump through the platforms, from underneath to the top of the platform, but I´m not being able to do that and the head of the hero collides with the bottom of the platform even when I set the collideDown of that tile (actually, to all the tiles of that layer) to false.

What am I missing?


this.platformsLayer = this.map.createLayer("platforms")
this.map.setCollisionBetween(1,50, true, "platforms")

var tilesArray = this.platformsLayer.getTiles(0,0,this.game.world.width, this.game.world.height)
for(var i=0;i<tilesArray.length;i++){
	tilesArray[i].setCollision(true, true, true, false)
	console.log("All set to false")


Link to post
Share on other sites
41 minutes ago, totallybueno said:

I still don´t get why


is not working as I was expecting.

Had a quick look at the source (collideSpriteVsTilemapLayer), it (collideDown etc) doesn't look implemented?
I guess you could just set the collide processCallback, and return false...


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Create New...