I have two kinematic bodies, By pressing the D key I move one to the right. Collision happens as you'd expect. But if I keep pressing D while colliding the body slowly starts moving either upwards or downwards until it's able to slide past the colliding object. Because in my game the two kinematic bodies are both human characters this looks really odd.
I tried to sort of circumvent this by adding an area2d and signal it so that velocity and speed becomes 0 if the area2d's collide. And this works for the first time. But the thing is that Area2d doesn't continuously detect collision. It just sends the signal once when collision happens for the first time. If the two bodies are continuously colliding it doesn't keep sending the signal.
I tried with rigid body instead of area2d and that didn't detect collision at all.
I'm going to try static body now. If there are any suggestions that can help me please let me know.