Topic was automatically imported from the old Question2Answer platform.
Asked By
mshka
I have 2 kinematic bodies one is the player and is controlled by a move_and_slide function the other is a moving platform which is controlled an animation player - when the platform is moving and the player is not moving there is not collision but when the player moves the 2 bodies collide until the player stops
I have tried making the platform move by a move_and_slide, move_and_collide, along a path while attached to PathFollow and setting the animation player process mode to Physics but nothing worked
what I want to do is make the platform push the player body when moving or idle any idea how to achieve this?
A kinematic body will move or be pushed outside other colliders only at the time you are calling move_and_slide or move_and_collide. One possibility would be to make sure you are using the move method every frame, even if you are moving 0 distance. Then your kinematic body should be pushed out of the other objects every frame.
This is great answer. i was struggling to understand why my collisions are ignored and moving even by smallest amount in proper direction ensures that they are working.