Platform that can be passed from below?

Questions about the LÖVE API, installing LÖVE and other support related questions go here.
Forum rules
Before you make a thread asking for help, read this.
Post Reply
User avatar
kalium
Prole
Posts: 9
Joined: Fri Jul 06, 2012 6:36 pm
Location: Rio de Janeiro

Platform that can be passed from below?

Post by kalium »

I've been doing a 2D tile-based platformer game, and I've stumbled across a doubt.

Is there any way of creating a platform (with love.physics) that can be jumped from below, but collides normally from the top?
User avatar
Boolsheet
Inner party member
Posts: 780
Joined: Wed Dec 29, 2010 4:57 am
Location: Switzerland

Re: Platform that can be passed from below?

Post by Boolsheet »

There should be various ways to implement this. The Box2D manual says it could be done in the pre-solve event where you disable the contact if it's coming from below. I guess a custom collision filter would do it too.
Shallow indentations.
Post Reply

Who is online

Users browsing this forum: Bing [Bot] and 6 guests