• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!

Weird Physics Collision Clip

So I was trying to make a physics platformer and I haven't worked with physics that much, but I ran into a problem where the player object would clip on the ground. So in order to recreate the problem I had created a new project with three objects, two of them being static walls and one of them being a player object. As you can see in the video below the player won't move to the right when it hits the other wall object on the ground. Does anyone know how to solve this? The code I used was to make the player move left and right by changing phy_speed_x. I also set all the objects restitution to 0. Finally, I had set the players phy_fixed_rotation to true.

Video:
 

Nocturne

Friendly Tyrant
Forum Staff
Admin
This is a very common and known issue when using Box2D physics (which is what the GM physics engine is based on). The only workaround is to ensure that there are no flat areas where fixtures meet - use a chain fixture, for example - or do what the linked Stack Overflow thread suggests and make your player character fixture a bevelled polygon (again, this can be done using either the polygon or chain fixtures).
 
This is a very common and known issue when using Box2D physics (which is what the GM physics engine is based on). The only workaround is to ensure that there are no flat areas where fixtures meet - use a chain fixture, for example - or do what the linked Stack Overflow thread suggests and make your player character fixture a bevelled polygon (again, this can be done using either the polygon or chain fixtures).
Ah I see. Well thanks for your help.
 
Top