I am having an issue with adding a pushable block when the character walks up to the block it works fine but when the character jumps onto the block it goes down and gets stuck in the ground.
Is there a way I can make the pushable block only work when the character is on the ground and walking.
I tried doing character falling inverted to stop it happening but it didn’t work
My code so far
thanks
Hi, I’m not sure about my solution cause I’m not familiar with plarformers, but here what I’d try:
- add a condition to your collision event that compare the block and the character Y coordinate. For exemple, only push the block if character.Y <= block.Y
- the block itslef could have the platform behavior so that when you jump on it you don’t fall through.
Hope it could work, and someone else might have a more efficient solution.