It is probably obvious(but not to me).
if new_velocity.y += gravity * get_physics_process_delta_time() why doesn't gravity continue to increase velocity.y ??
PS Thanks for your excellent tutorials.
This is not obvious, and that's a good question.
The reason gravity doesn't accumulate is because we store the value returned by move_and_slide:
velocity = move_and_slide(...)
When your kinematic body collides with the floor, this function resets the Y velocity to 0.
And we apply the gravity every frame:
Thanks Nathan, Makes sense..... I never would have worked that out by myself.