How does move_and_slide() use move_and_collide() under the hood?

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By lakshaya


I’m trying to make my 2DKinematic Character as controllable as possible.

In order to do this, I want to use move_and_collide(), and write my own logic for handling collisions.

I’m running into quite a few issues, as everything doesn’t just work with a magic wand via this method. It would be very helpful to see how move_and_slide() uses move_and_collide().

Can anybody help me with this? Are there any C#/C++ docs?

:bust_in_silhouette: Reply From: kidscancode

The “C++ docs” are the source code. You can see how move_and_slide() is implemented by looking at the source: