Take the 2-minute tour ×
Game Development Stack Exchange is a question and answer site for professional and independent game developers. It's 100% free, no registration required.

I have a body that I am using as a paddle, it is expected to move in a vertical fashion and other objects should "bounce off it". The paddle itself should never move horizontally.

According to the docs this sounds like what I want...

A kinematic body moves under simulation according to its velocity. Kinematic bodies do not respond to forces.

but reading further....

Static bodies do not collide with other static or kinematic bodies.

So I create two Static Body lines and a box in between. How do I handle the box's movement? I don't think I want a dynamic object because I am only interested in linear moves (I.E. don't want wabbling).

What is the best way to handle this scenario?

share|improve this question
add comment

1 Answer

Unless I'm misunderstanding the second half of your question, it sounds like you still want a kinematic body. Other dynamic objects will react to the kinematic body you have created, but the paddle will remain unaffected by colliding with whatever is supposed to bounce off of it. Check out the example found here.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.