move_and_slide function

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

hello sir can you help me, i don’t understand move_and_slide
function, i’ve read it in gdscript and haven’t found the answer, thanks

:bust_in_silhouette: Reply From: the_maven

When using KinematicBody2D the, move_and_slide method, works by calculating the velocity of delta and in case of collision during movement of the KinematicBody, if it will charge direction and keep moving.