Skip to content

Collisions between static and kinematic bodies, integrating logic and physics in a game #71

Answered by stockhuman
Franckapik asked this question in General
Discussion options

You must be logged in to vote

Unfortunately, I'm going to point you to the FAQ:

A kinematic body moves under simulation according to its velocity. They do not respond to forces. They can be moved manually, but normally a kinematic body is moved by setting its velocity. A kinematic body behaves as if it has infinite mass. Kinematic bodies do not collide with other static or kinematic bodies.

Since your player, walls and floor are all Kinematic or static, you will not see collisions between them.

Are you looking to perhaps applyLocalImpulse or force with every player movement? The player box would not move as you've defined it to so far, however. Or to rephrase that, are you looking for physics-based movement of the p…

Replies: 6 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by codynova
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #71 on June 17, 2020 20:09.